Question: Gviz package : highlight one particular point on the datatrack
gravatar for cedric.vmdl
8 months ago by
cedric.vmdl0 wrote:


I am quite new to R programming and could really appreciate your help to resolve this issue. I'm stuck with it, even after having carefully read the Gviz user's guide.

I have a datatrack for one sample : on the X axis the genomic positions on a particular chromosome, on the Y axis the coverage of SNPs. Besides the vectors containing the position and the coverage, I have a vector for the color of each point (color_point : eg all are "grey" and 1 in particular is "red"), and a vector for the size of each point (size_point : eg all are "1" and 1 in particular is "5").

When I create the datatrack to show the value at each genomic position, how come the point related to my SNP of interest is not highlighted? Every point is grey and of a size of 1. And there's no error reporting. I also changed all the "grey" in "blue", and this works, so the issue is not changing the color of my dots, but highlighting one.

Here is my code :


dtrack <- DataTrack(data = coverage, 
                    start = coords[-length(coords)],
                    end = coords[-1], 
                    chromosome = chrom, 
                    genome = "hg19",

           type = c("p"),
           from = lim[1], to = lim[2])


And here is the plot :


Thank you very much if you can show me my mistake.



ADD COMMENTlink written 8 months ago by cedric.vmdl0
Please log in to add an answer.


Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.2.0
Traffic: 328 users visited in the last hour