renumber_logo_seq_breaks: Given a sequence of upper and lower cases creates the best...

View source: R/pwm_utils.R

renumber_logo_seq_breaksR Documentation

Given a sequence of upper and lower cases creates the best breaks and labels for a ggplot sequence logo

Description

This is a helper function used in plot_bits_logo() and plot_JSD_logo().

Usage

renumber_logo_seq_breaks(
  seq,
  lowercase_spacer = 5,
  uppercase_spacer = 10,
  uppercase_adjustment
)

Arguments

seq

A character vector with UPPER and lower cases

lowercase_spacer

An integer indicating the distance between the label numbers in the lowercase sequence.

uppercase_spacer

An integer indicating the distance between the label numbers in the uppercase sequence.

uppercase_adjustment

An integer defining the actual length of the region in the coord2seq.sh script. If the upper-case region has been trimmed upstream (e.g. -u -39) this parameter corrects the X-axis numbering to match the real length before trimming. Can be omitted.

Value

A list the best breaks and labels

Note

If proving a non-integer number for ⁠*case_spacer⁠ parameters it will be rounded up to the closer integer.


Ni-Ar/niar documentation built on Feb. 3, 2025, 9:25 a.m.