markrobinsonuzh / CrispRVariants

23 stars 4 forks source link

VCF output #6

Open zeus19900814 opened 6 years ago

zeus19900814 commented 6 years ago

Hello,

Is there a way to get a vcf format output that has all variants? If there isn't such a function, is there a workaround to get vcf output?

Thank you so much, John

HLindsay commented 6 years ago

Hi John,

I don't think there's a way to get VCF output. You can get the regions of the alignments that overlap the target region as a GAlignments object, but I don't know of a way to transform that into VCF format.

A workaround might be possible, depending on what you want to do with the VCF file and whether this is still in R. The main issue I see is that VCF files contain information about the quality of the variants, e.g. from coverage, strand bias, genotypes. It's not clear to me how to get a meaningful quality score from amplicon data with mutations concentrated in one spot. However, if you only need the variant locations for further analysis in R, that's possible. For example, there are functions in CrispRVariants to work with the VariantAnnotation package and the Ensembl Variant Effect Predictor.

Best, Helen

zeus19900814 commented 6 years ago

Thank you, Helen, for such a quick reply! That helps a lot!

John