make_col_scheme: Create new sequence logo color scheme

View source: R/col_schemes.r

make_col_schemeR Documentation

Create new sequence logo color scheme

Description

Create new sequence logo color scheme

Usage

make_col_scheme(chars = NULL, groups = NULL, cols = NULL, values = NULL,
  name = "")

Arguments

chars

Vector of one letter characters

groups

Vector of groups for letters with same length as chars (optional if cols parameter is provided)

cols

Vector of colors with same length as chars (optional if values parameter is provided)

values

Vector of numerical values with same length as chars

name

Name of color scheme

Examples


# Discrete color scheme examples
cs1 = make_col_scheme(chars=c('A', 'T', 'G', 'C'), groups=c('g1', 'g1', 'g2', 'g2'), 
                      cols=c('red', 'red', 'blue', 'blue'), name='custom1')

cs2 = make_col_scheme(chars=c('A', 'T', 'G', 'C'), cols=c('red', 'red', 'blue', 'blue'), 
                      name='custom2')

# Quantitative color scheme
cs3 = make_col_scheme(chars=c('A', 'T', 'G', 'C'), values=1:4, name='custom3')

ggseqlogo documentation built on May 29, 2024, 5:18 a.m.