IsomirDataSeqFromFiles: Loads miRNA annotation from seqbuster tool or pre-processed...

View source: R/AllClasses.R

IsomirDataSeqFromFilesR Documentation

Loads miRNA annotation from seqbuster tool or pre-processed data.

Description

This function parses output of seqbuster tool to allow isomiRs/miRNAs analysis of samples in different groups such as characterization, differential expression and clustering. It creates an IsomirDataSeq object.

Usage

IsomirDataSeqFromFiles(
  files,
  coldata,
  rate = 0.2,
  canonicalAdd = TRUE,
  uniqueMism = TRUE,
  uniqueHits = FALSE,
  design = ~1L,
  minHits = 1L,
  header = TRUE,
  skip = 0,
  quiet = TRUE,
  ...
)

Arguments

files

files with the output of seqbuster tool

coldata

data frame containing groups for each sample

rate

minimum counts fraction to consider a mismatch a real mutation

canonicalAdd

boolean only keep A/T non-template addition. All non-template nucleotides at the 3' end will be removed if they contain C/G nts.

uniqueMism

boolean only keep mutations that have a unique hit to one miRNA molecule. For instance, if the sequence map to two different miRNAs, then it would be removed.

uniqueHits

boolean whether filtering ambigous sequences or not.

design

a formula to pass to DESeq2::DESeqDataSet

minHits

Minimum number of reads in the sample to consider it in the final matrix.

header

boolean to indicate files contain headers

skip

skip first line when reading files

quiet

boolean indicating to print messages while reading files. Default FALSE.

...

arguments provided to SummarizedExperiment and IsomirDataSeqFromRawData. including rowData.

Details

This function parses the output of http://seqcluster.readthedocs.org/mirna_annotation.html for each sample to create a count matrix for isomiRs, miRNAs or isomiRs grouped in types (i.e all sequences with variations at 5' but ignoring any other type). It creates IsomirDataSeq object (see link to example usage of this class) to allow visualization, queries, differential expression analysis and clustering. To create the IsomirDataSeq, it parses the isomiRs files, and generates an initial matrix having all isomiRs detected among samples. As well, it creates a summary for each isomiR type (trimming, addition and substitution) to visualize general isomiRs distribution.

Value

IsomirDataSeq class object.

Examples

path <- system.file("extra", package="isomiRs")
fn_list <- list.files(path, pattern="mirna", full.names = TRUE)
de <- data.frame(row.names=c("f1" , "f2"),
                 condition = c("newborn", "newborn"))
ids <- IsomirDataSeqFromFiles(fn_list, coldata=de)

head(counts(ids))
IsomirDataSeqFromRawData(metadata(ids)[["rawData"]], de)

lpantano/isomiRs documentation built on Aug. 26, 2024, 3:34 a.m.