guess_alphabet: Guess an alphabet type in a dataframe sequences.

View source: R/pwm_utils.R

guess_alphabetR Documentation

Guess an alphabet type in a dataframe sequences.

Description

It can can recognise sequences that are DNA/RNA; upper, lower, or both UPPER&lower case; gapped or non-gapped.

Usage

guess_alphabet(
  data,
  ID_col,
  include_gaps = TRUE,
  name = FALSE,
  verbose = FALSE
)

Arguments

data

A data.frame with a minimum of 2 columns. One named Sequence, the other named as you prefer that will be specified with ID_col.

ID_col

The name of the column in data to be used as the identifier of the Sequence column.

include_gaps

Logical, include also the gap character '-' (dash) in the guess alphabet regex. Default TRUE.

name

Logical, return only the guessed alphabet name instead of the letters in that alphabet. Default FALSE.

verbose

Logical, print some info messages. Default FALSE.

Value

A character vector with the letters of that alphabet


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