Skip to contents

Plot construction

Build, convert and inspect ggchord plots.

ggchord()
ggchord: layered multi-sequence alignment chord diagrams for ggplot2
coord_chord()
Chord diagram coordinate system
get_chord_layout()
Get the chord layout from the package environment
`+`(<ggchord>)
Combine a ggchord plot with ggplot2 objects
ggplotly(<ggchord>)
Convert a ggchord plot to a plotly object

Methods and datasets

S3 methods and example data shipped with ggchord.

as.data.frame(<ggchord_validation>)
Coerce a validation result to a flat data.frame
print(<ggchord_clean>)
Print a cleaned ggchord data result
seq_data_example
Example sequence data
ribbon_data_example
Example alignment data
gene_data_example
Example gene annotation data

Layers

Stack geometry, annotation, axis and label layers.

geom_seq()
Add a sequence arc layer
geom_ribbon()
Add an alignment ribbon layer
geom_gene()
Add a gene arrow layer
geom_gene_label()
Add a gene label layer
geom_gene_label_repel()
Add a repelled gene label layer (ggrepel-style)
geom_axis()
Add an axis layer
geom_seq_label()
Add a sequence label layer
geom_seq_region()
Highlight regions along sequence arcs
geom_ribbon_highlight()
Highlight selected alignment ribbons
geom_feature()
Draw generic genomic features

Data import

Read FASTA, BLAST and GFF3 files in R.

read_fasta_lengths()
Read one or more FASTA files into seq_data format
read_blast()
Read one or more BLAST tabular output files into ribbon_data format
read_gff3()
Read one or more GFF3 files into gene_data format

Validation and cleaning

Check and repair ggchord input tables before plotting.

validate_ggchord_data()
Validate ggchord input data before plotting
clean_ggchord_data()
Clean ggchord input data with explicit, report-driven policies

Ribbon preparation

Filter, deduplicate and merge alignment blocks.

filter_ggchord_ribbons()
Filter alignment ribbons before plotting
deduplicate_ggchord_ribbons()
Deduplicate alignment ribbons
merge_ggchord_ribbons()
Merge adjacent or overlapping alignment blocks of the same sequence pair