Description Usage Arguments Details Value Author(s) Examples
Finds all CpGs in a reference genome.
1 2 | getCpGsetCG(genome)
getCpGsetALL(genome)
|
genome |
A |
The getCpGsetCG
function searches for all
CG
pairs in the genome.
The getCpGsetALL
function also works for genomes with injected SNPs.
Returns a list with CpG coordinates for each genome sequence.
Andrey A Shabalin andrey.shabalin@gmail.com
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 | ### Using a BSGenome input
library(BSgenome.Ecoli.NCBI.20080805)
cpgset = getCpGsetCG(BSgenome.Ecoli.NCBI.20080805)
print("First 10 CpGs in NC_008253:")
print(cpgset$NC_008253[1:10])
### Using a character vector input
genome = list(
chr1 = "AGCGTTTTCATTCTGACTGCAACGGGCYR",
chr2 = "AAAAAACGCCTTAGTAAGTGATTTTCGYR")
cpgset1 = getCpGsetCG(genome)
cpgset2 = getCpGsetALL(genome)
print("Pure CG coordinates in the toy genome:")
print(cpgset1)
print("CG coordinates in the toy genome possible with SNPs:")
print(cpgset2)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.