Open rcavalcante opened 4 years ago
All plots will have some constant components:
GenomeAxisTrack()
IdeogramTrack(genome=gen, chromosome=chr)
GenomeInfoDb::Seqinfo()
, or make sure to grab the seqinfo
from the object we're plotting.GeneRegionTrack(geneModels, genome=gen, chromosome=chr, name="Gene Model")
plotTracks(dTrack, groups=rep(c("control", "treated"), each=3), type=c("a", "p"), legend=TRUE)
does grouping and has many plotting type choices here. For group methylation data, it feels like a boxplot grouped by case
and control
is most appropriate.
Issues to resolve before implementation
A couple of questions come to mind:
BSseq
object without differential methylation tests?diff_
functions to include a flag likeinclude_sample_meth
which would be TRUE/FALSE and would append columns for sample-wise methylation to thediff_
function results?include_sample_meth
flag, we would also need to require theBSseq
object to append that data anyway.png() ... dev.off()
?Function call
plot_methylation(bs, diff_result, ...)
Description
A function to plot the result of
diff_binomial()
,diff_methylsig()
, ordiff_dss_test()
on a genome track. Users may pass options through this function toGViz::plotTracks()
to visualize other tracks alongside the methylation data.Arguments
bs
aBSseq
object.diff_result
aGRanges
object obtained fromdiff_binomial()
,diff_methylsig()
, ordiff_dss_test()
....
parameters passed toGViz::plotTracks()
.Values
An image (?) or an object (?).
Tests
If a file of the plot is returned, not sure. If an object, check correct class.