Question: Seq Array converting VCF to GDS using seqVCF2GDS, unable to find file problems with vcf.fn
0
gravatar for cav3gh
10 months ago by
cav3gh0
cav3gh0 wrote:

So, I can read the vcf file into R using read.vcf, but I cannot seem to get seqVCF2GDS to work.  I have tried the following code:

> vcf_test1 <- read.vcf("/Users/Desktop/batch_1.vcf")
Reading 10000 / 10000 loci.
Done.

> vcf.fn <- "C:/Users/Desktop/batch_1.vcf"
> seqarray_test1 <- seqVCF2GDS(vcf.fn)
Error in stopifnot(is.character(out.fn), length(out.fn) == 1L) : 
  argument "out.fn" is missing, with no default
> vcf.fn = "C:/Users/Desktop/batch_1.vcf"
> seqarray_test1 <- seqVCF2GDS(vcf.fn, "mangrove.gds")
Error in file(vcf.fn[1L], open = "rt") : cannot open the connection
In addition: Warning message:
In file(vcf.fn[1L], open = "rt") :
  cannot open file 'C:/Users/Desktop/batch_1.vcf': No such file or directory
 

I am not sure what I am doing wrong

seqarray • 190 views
ADD COMMENTlink modified 10 months ago by Stephanie M. Gogarten640 • written 10 months ago by cav3gh0
Answer: Seq Array converting VCF to GDS using seqVCF2GDS, unable to find file problems w
0
gravatar for zhengx
10 months ago by
zhengx30
United States
zhengx30 wrote:

Please make sure your file exists.

You might try

file.size(vcf.fn)

to see whether it returns the correct size of that VCF file.

 

ADD COMMENTlink written 10 months ago by zhengx30
Answer: Seq Array converting VCF to GDS using seqVCF2GDS, unable to find file problems w
0
gravatar for Stephanie M. Gogarten
10 months ago by
University of Washington
Stephanie M. Gogarten640 wrote:

Note that you are using two different paths in the example that worked (with read.vcf) and the example that did not work, so please try using the original file path.

vcf.fn <- "/Users/Desktop/batch_1.vcf"
seqarray_test1 <- seqVCF2GDS(vcf.fn, "mangrove.gds")
ADD COMMENTlink written 10 months ago by Stephanie M. Gogarten640
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 16.09
Traffic: 431 users visited in the last hour