mT1: Motifs in Tandem with One Another

Description Usage Arguments Value Author(s) Examples

Description

Motifs in Tandem with One Another

Generates a mT1 object from DNAStringSet and a vector of motifs. A mT1 object can be used for the investigation of preferred motif positions and identifying composite motifs. There must be at least 3 motifs being compared. For the comparison of two motifs look at motifDiff. The purpose of a mT1 object is to identify novel preferred distances from a large set of motifs.

Usage

1
mT1(fasta, motifs, verbose = FALSE, cl = NULL)

Arguments

fasta

The set of genomic locations as a DNAStringSet

motifs

The list of three or more motifs being compared, IUPAC chars only.

verbose

A flag to print motifs as completed.

cl

A cluster from makeForkCluster

Value

A mT1 object

Author(s)

"Alexander Griffith <griffitaj@gmail.com>"

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
library(Biostrings) # needed to get fasta data from genomic co-ords
library(BSgenome.Hsapiens.UCSC.hg19) # genome
## load a set of Jaspar motifs as strings
## load(system.file("extdata","jaspar.RData",package="mT1"))
jaspar<-mT1_jaspar
## Example set of peaks
## load(system.file("extdata","peaks.RData",package="mT1"))
peaks<-mT1_peaks
## Transform genomic co-ords into neucleotides
genome<-BSgenome.Hsapiens.UCSC.hg19
fasta<-getSeq(genome,peaks$chr,start=peaks$start,end=peaks$end)

## Motifs to compare
motifs<-c("CANNTG","GATAA",jaspar$jsublM[1:2])

## Find the preferred distances between `motifs` under the peaks
my_sampleMT1<-mT1(fasta,motifs)

## plot based on string
plot(my_sampleMT1,"CANNTG","GATAA")

## Plot based on printed order
print(my_sampleMT1)
plot(my_sampleMT1,i=1)

alexjgriffith/mT1 documentation built on May 10, 2019, 8:53 a.m.