GRangesMatrixSeq: Definition of GRangesMatrixSeq-class

View source: R/allClasses.R

GRangesMatrixSeq-classR Documentation

Definition of GRangesMatrixSeq-class

Description

This is a very simple flexible class to store DNA and aminoacid aligned sequences together with their physicochemical properties. That is, a place where each aminoacid or codon from the sequence is represented by numerical value from a physicochemical index.

Constructor for 'GRangesMatrixSeq-class' object.

Usage

GRangesMatrixSeq(
  object = NULL,
  seqnames = Rle(factor()),
  start = integer(0),
  end = integer(0),
  ranges = IRanges(),
  strands = Rle(strand()),
  elementMetadata = DataFrame(),
  seqinfo = NULL,
  seqs = character(),
  names = character(),
  aaindex = character(),
  phychem = character(),
  accession = character()
)

Arguments

object

If provided, it must be a GRangesMatrixSeq-class object and in this case

seqnames, start, end, ranges, strand, elementMetadata, seqinfo

The same as in GRanges

seqs, names, aaindex, phychem, accession

The same as in MatrixSeq.

Details

This is a convenient function to transform a MatrixSeq-class object returned by function aa_phychem_index into a 'GRangesMatrixSeq-class' object. Since a 'GRangesMatrixSeq-class' inherits from GRanges-class, this transformation permits the application of several methods from GenomicRanges package in the downstream analysis.

Value

Given the slot values, it defines a MatrixList-class.

Only used to specify signature in the S4 setMethod.

Examples

aln <- c(S1 = "ATGCGGATTAGA", S2 = "ATGACGATCACA", 
        S3 = "ATGAGATCACAG")
cd <- DNAMultipleAlignment(aln)
r1 <- peptide_phychem_index(unmasked(cd), acc = "EISD840101")

r2 <- GRangesMatrixSeq(r1)
r2

slot(r2, "phychem")


genomaths/GenomAutomorphism documentation built on May 10, 2024, 12:11 a.m.