This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Saving file as .vcf

Hello,

I really need help to save my file as .vcf.

I have modified my vcf file as I want using VCFR package in R. Now I want to save my new in .vcf format using code write.vcf.

But the saved file is some kind of weird data file. Can someone help me where I am making mistake?

Thank youenter image description here

ngs variant vcf

from manual:

The function write.vcf takes an object of either class vcfR or chromR and writes the vcf data to a
vcf.gz file (gzipped text)

1 answer

This gibberish means that it is probably gzip-compressed and should be vcf.gz. Please don't get used to open OMICS files in plain text editors. Use Unix tools such as less, head or something like that.

Rename your file to .vcf.gz and then try and see whether something like zless can properly open it. Frankly, and I really mean no offense, if you are stuck with these kinds of basics you must spend time with Unix fundamentals before diving into analysis.

Thank you so much. I just uncompressed my files.

Why did you delete the post?

Log in to answer this question.