Question: Problem in converting vcf to maf using vcf2maf tools
0
gravatar for Raheleh
12 months ago by
Raheleh130
Raheleh130 wrote:

Hi,

I want to convert my vcf file (VarScan output) to maf file to generate some publication-quality images using maftools (R package). Based on the instruction of vcf2maf tools here, I installed VEP. But when I ran this command:

perl vcf2maf.pl --ref-fasta /home/raheleh/.vep/homo_sapiens/86_GRCh38/Homo_sapiens.GRCh38.dna.primary_assembly.fa.gz --input-vcf HROC.vcf --output-maf tests/test_varscan.vep.maf --tumor-id WD1309 --normal-id NB1308 --vcf-tumor-id TUMOR --vcf-normal-id NORMAL

I get this error:

ERROR: Provided --filter-vcf is missing or empty: /home/raheleh/.vep/ExAC_nonTCGA.r0.3.1.sites.vep.vcf.gz

Then I ran this command:

curl -L ftp://ftp.broadinstitute.org:/pub/ExAC_release/release0.3.1/subsets/ExAC_nonTCGA.r0.3.1.sites.vep.vcf.gz > $VEP_DATA/ExAC_nonTCGA.r0.3.1.sites.vep.vcf.gz

But I got this:

bash: /ExAC_nonTCGA.r0.3.1.sites.vep.vcf.gz: Permission denied

Can anyone help me how to fix it? Thank you!

vcf2maf grch38 varscan • 811 views
ADD COMMENTlink modified 12 months ago • written 12 months ago by Raheleh130
1

For the second error, it seems the variable $VEP_DATA is empty or non-defined, so you are trying to write a file to the root of the filesystem, which you, as a regular user, doesn't have permission to do. Define it with:

export VEP_DATA=/path/to/vep/data
ADD REPLYlink written 12 months ago by h.mon29k

@h.mon Thank you. I defined it with export VEP_DATA=/path/to/vep/data but now the error changed to this:

bash: /path/to/vep/data/ExAC_nonTCGA.r0.3.1.sites.vep.vcf.gz: No such file or directory

can you please help me?

ADD REPLYlink modified 12 months ago • written 12 months ago by Raheleh130

You have to use the actual path to VEP data - the one you used when installing VEP - not "/path/to/vep/data/".

ADD REPLYlink written 12 months ago by h.mon29k

What h.mon means is that, if you have VEP installed at /Raheleh/programs/vep/, then you should use, for example:

export VEP_DATA=/Raheleh/programs/vep/data/

So, where have you installed VEP?

ADD REPLYlink modified 12 months ago • written 12 months ago by Kevin Blighe55k

Oh, yeah. I did exactly as it is said here , so I think the path must be this export VEP_DATA=$HOME/.vep, right?

when I open terminal in the folder that I installed VEP, it shows this path: ~/vep

ADD REPLYlink written 12 months ago by Raheleh130

Is there any other ways to convert vcf to maf?

ADD REPLYlink written 12 months ago by Raheleh130
1

I honestly would not bother to use MAF - the format never became popular. If you have a VCF, use bcftools query to nicely output the data that you then later want to use in R.

ADD REPLYlink written 12 months ago by Kevin Blighe55k

@Kevin Blighe I ran this command

bcftools cnv -c normal_rmdup.bam -s tumor_rmdup.bam -o outdir/ -p 0 Somatic.hc.fpfilterPassed.vcf

to produce a plot of my CNV file but I got this error: The sample "tumor_rmdup.bam" not found

The sample exist in the same directory as others. What's the problem? please help me out. Thank you!

Could you please also provide me with the command that you used to get a good output to be used in R? which R package can be used to visualize VCFs and CNVs? I really appreciate any help.

ADD REPLYlink written 12 months ago by Raheleh130
1

I have not used bcftools cnv, however, I believe -s parameter is looking for a sample name from within your VCF file.

ADD REPLYlink written 12 months ago by Kevin Blighe55k
Please log in to add an answer.

Help
Access

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