searchPairBSgenome-methods: searchPairBSgenome method

Description Usage Arguments Value Author(s) See Also Examples

Description

Given a chain file for liftover from one genome to another, it searches two BSgenome with a PWMatrix, and only reports the hits that are presents in two genomes with equivalent positions.

Usage

1
2
  searchPairBSgenome(pwm, BSgenome1, BSgenome2, chr1, chr2,
                     min.score="80%", strand="*", chain)

Arguments

pwm

A PWMatrix object or a PWMatrixList object.

BSgenome1, BSgenome2

A BSgenome class.

chr1, chr2

A character object, specifying the chromosomes you want to search.

min.score

The minimum score for the hit. Can be given an character string in th format of "80%" or as a single absolute value.

strand

When searching the alignment, we can search the positive "+" strand or negative "-" strand. While strand is "*", it will search both strands and return the results based on the positvie strand coordinate.

chain

A Chain object. It can be generated by import.chain from package rtracklayer. Please provide the chain from BSgenome1 to BSgenome2.

Value

A SitePairSet object is returned when pwm is a PWMatrix, while a SitePairSetList is returned when pwm is a PWMatrixList.

Author(s)

Ge Tan

See Also

searchAln

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
  ## Not run: 
    library(rtracklayer)
    library(JASPAR2014)
    library(BSgenome.Hsapiens.UCSC.hg19)
    library(BSgenome.Mmusculus.UCSC.mm10)
    data("MA0004.1")
    pfm <- MA0004.1
    pwm <- toPWM(pfm)
    chain <- import.chain("Downloads/hg19ToMm10.over.chain")
    sitepairset <- searchPairBSgenome(pwm, BSgenome.Hsapiens.UCSC.hg19,
                                      BSgenome.Mmusculus.UCSC.mm10,
                                      chr1="chr1", chr2="chr1",
                                      min.score="90%", strand="+", 
                                      chain=chain)
  
## End(Not run)

TFBSTools documentation built on Nov. 8, 2020, 8:14 p.m.