I have VCF file format with SNPs predicted. I would like to plot these SNPs/contig wise through sliding window. Is there any script or R package available already?
You can use the ZOO package in [R]. I also have an R script to do it (It is C under the hood).
Here is the github link:
genomicwindowmean.R <- the [r] script
mean_window.c <- the accompanying C program
For your purpose you would need to edit line 29 to make it a count rather than an average.
Thanks. I will look into ZOO package. If possible can you share your script?
Login before adding your answer.
Use of this site constitutes acceptance of our User Agreement and Privacy