compute_GC: Calculate GC content

Description Usage Arguments Details Value Author(s) See Also Examples

View source: R/LncFinder.R

Description

This function can GC content of the input sequences.

Usage

1
2
3
4
5
6
7
compute_GC(
  Sequences,
  label = NULL,
  on.ORF = FALSE,
  auto.full = FALSE,
  parallel.cores = 2
)

Arguments

Sequences

A FASTA file loaded by function read.fasta of seqinr-package.

label

Optional. String. Indicate the label of the sequences such as "NonCoding", "Coding".

on.ORF

Logical. If TRUE, GC content will be calculated on the longest ORF region.

auto.full

Logical. When on.ORF = TRUE but no ORF can be found, if auto.full = TRUE, GC content will be calculated on full sequences automatically; if auto.full is FALSE, the sequences that have no ORF will be discarded. Ignored when on.ORF = FALSE. (Default: FALSE)

parallel.cores

Integer. The number of cores for parallel computation. By default the number of cores is 2. Users can set as -1 to run this function with all cores.

Details

This function can basically compute GC content of DNA sequences: GC content = (nc + ng) / (na + nc + ng + nt). The function will ignored the ambiguous bases.

Value

A dataframe.

Author(s)

HAN Siyu

See Also

GC (package "seqinr-package")

Examples

1
2
3
4
5
6
7
8
## Not run: 
data(demo_DNA.seq)
Seqs <- demo_DNA.seq

gcContent <- compute_GC(Seqs, label = "NonCoding",on.ORF = TRUE,
                        auto.full = TRUE, parallel.cores = 2)

## End(Not run)

LncFinder documentation built on Dec. 11, 2021, 9:39 a.m.