Error with opening and deleting temporary files

70 views
Skip to first unread message

Eliza Kirsch

unread,
Feb 22, 2024, 3:56:38 PM2/22/24
to plink2-users
Hello, 

I am trying to run this command 
plink2 --vcf 41-Passerculus_final.vcf.gz --export ped --out 41-Passerculus --allow-extra-chr
to create ped/map files from my vcf file. 

However, I get these errors: 
--vcf: 187141123 variants scanned. --vcf: 41-Passerculus-temporary.pgen + 41-Passerculus-temporary.pvar.zst + 41-Passerculus-temporary.psam written. Error: Failed to open 41-Passerculus-temporary.psam : No such file or directory. Error: Failed to delete 41-Passerculus-temporary.psam . Error: Failed to delete 41-Passerculus-temporary.pvar.zst . Error: Failed to delete 41-Passerculus-temporary.pgen .

Do you have any suggestions for how to proceed? I thought it might have to do with available disk space but I checked and ensured that I do have enough in the directory where I am working. I am attaching my .log file below. Thank you!
41-Passerculus.log

Christopher Chang

unread,
Feb 22, 2024, 4:53:08 PM2/22/24
to plink2-users
1. Why are you creating ped/map files?  The ped/map format has been more poorly supported than VCF by plink since 2014.
2. Hmm, something weird seems to be going on with your filesystem that is preventing plink2 from reopening files that it writes.  What is the output of "ls -al" after running that failing command?

Chris Chang

unread,
Feb 22, 2024, 6:37:23 PM2/22/24
to Eliza Kirsch, plink2-users
1. Yes, plink 1.9 --vcf is more efficient than --file.  In both cases, plink 1.9 will first convert to its native format of .bed+.bim+.fam (which is written with --make-bed and read with --bfile), but VCF is easier to convert.

There have been almost no good reasons to use the .ped+.map format for years.

2. Can you try rerunning with a newer plink2 build?  If you get a similar failure, post the subsequent "ls -al" output again.

On Thu, Feb 22, 2024 at 3:14 PM Eliza Kirsch <eki...@usc.edu> wrote:
I was creating ped/map files because I wanted to use plink to calculate runs of homozygosity for my dataset. Am I able to use plink to do these calculations directly with my vcf file rather than creating ped/map files? 

Here is the output of ls -al: 
<redacted>
Thank you so much for the help!
-Eliza

--
You received this message because you are subscribed to a topic in the Google Groups "plink2-users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/plink2-users/gM1NBHXZdnw/unsubscribe.
To unsubscribe from this group and all its topics, send an email to plink2-users...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/plink2-users/8fac3d1a-7617-4b7e-92d0-dc24a401f037n%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages