ggseqlogo2.Rdggseqlogo is a shortcut for generating sequence logos.
It adds the ggseqlogo theme theme_logo by default, and facets when multiple input data are provided.
It serves as a convenient wrapper, so to customise logos beyond the defaults here, please use geom_logo.
ggseqlogo2( data, facet = "wrap", scales = "free_x", ncol = NULL, nrow = NULL, idor = NULL, ... ) geom_logo2( data = NULL, method = "bits", seq_type = "auto", namespace = NULL, font = "roboto_medium", stack_width = 0.95, rev_stack_order = F, col_scheme = "auto", low_col = "black", high_col = "yellow", na_col = "grey20", plot = TRUE, idor = NULL, ... )
| data | Character vector of sequences or named list of sequences. All sequences must have same width |
|---|---|
| facet | Facet type, can be 'wrap' or 'grid' |
| scales | Facet scales, see |
| ncol | Number of columns, works only when |
| nrow | Number of rows, same as |
| idor | a named vector (like a dictory) to change letters one to one in the plot. |
| ... | Additional arguments passed to |
| method | Height method, can be one of "bits" or "probability" (default: "bits") |
| seq_type | Sequence type, can be one of "auto", "aa", "dna", "rna" or "other" (default: "auto", sequence type is automatically guessed) |
| namespace | Character vector of single letters to be used for custom namespaces. Can be alphanumeric, including Greek characters. |
| font | Name of font. See |
| stack_width | Width of letter stack between 0 and 1 (default: 0.95) |
| rev_stack_order | If |
| col_scheme | Color scheme applied to the sequence logo. See |
| low_col | Colors for low and high ends of the gradient if a quantitative color scheme is used (default: "black" and "yellow"). |
| high_col | Colors for low and high ends of the gradient if a quantitative color scheme is used (default: "black" and "yellow"). |
| na_col | Color for letters missing in color scheme (default: "grey20") |
| plot | If |
library(ggseqlogo) data(ggseqlogo_sample) ## Same as ggseqlogo() p1 <- ggseqlogo2(seqs_dna[[1]]) p1 ## Extra feature idor <- as.character(1:4) names(idor) <- c("A", "C", "G", "T") p2 <- ggseqlogo2(seqs_dna[[1]], idor = idor) p2