Hi All,

I have a file list consisting of Chromosome, Start , End & Methylation
Difference in the following format in excel:

Chrom     Start          End          Meth. Diff

chr1     38565900 38566000 -0.20276818

chr1     38870400 38870500 -0.342342342

chr1     39469400 39469500 -0.250260552

chr1     52013600 52013700 -0.37797619

chr1     52751700 52751800  0.257575758

chr1     75505100 75505200 -0.262847308

I need help in plotting the DMRs using Gviz package in R. I tried a code
below but it doesn't turn out correct.

library(GenomicRanges)
library(grid)
library(Gviz)
library(rtracklayer)
library(BSgenome)
library(readxl)
library(BSgenome.Rnorvegicus.UCSC.rn6)
genome <- getBSgenome("BSgenome.Rnorvegicus.UCSC.rn6")
genome
data1 <- read_excel("DMRs_plots.xlsx")
head(data1)
data1$Chrom = Chrom$chr1

track1 <- DataTrack(data = data1, from = "38565900" , to = "282250000",
chromosome = Chrom$chr1, name = "DMRs")

itrack <- IdeogramTrack(genome = genome, chromosome = chr)

plotTracks(track1, itrack)


If anyone know how to plot and correct my code including how to add
methylation difference values, then that will be of great help.


Thanks,

Puja

        [[alternative HTML version deleted]]

______________________________________________
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to