Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue with glf file - too many sites #47

Open
dgallery opened this issue Feb 16, 2023 · 17 comments
Open

Issue with glf file - too many sites #47

dgallery opened this issue Feb 16, 2023 · 17 comments

Comments

@dgallery
Copy link

Hi,
I am trying to make a kinship matrix from 47 individuals. I am running the following code:

angsd -b bams_qst_adults -gl 2 -domajorminor 1 -snp_pval 1e-6 -domaf 1 -minmaf 0.05 -doGlf 3 -out kinMAT
zcat kinMAT.mafs.gz | cut -f5 |sed 1d > freq
./ngsRelate -g kinMAT.glf.gz -n 47 -f freq -O kinMAT

Which produces the following error file:

./ngsRelate -g kinMAT.glf.gz -n 47 -f freq -O kinMAT
-> Seed is: 1211251308
-> Frequency file: 'freq' contain 139458 number of sites
-> Too many sites in glf file. Looks out of sync, or make sure you supplied correct number of individuals (-n)
-> Or that the number of sites provided (-L) it is correct

I double checked that my file list contains 47 individuals. Any assistance you can provide would be greatly appreciated.
Thanks!

@ANGSD
Copy link
Owner

ANGSD commented May 16, 2023

Sorry for late reply. If this is still relevant. Please supply files.

Thanks!

@dgallery
Copy link
Author

dgallery commented Jun 3, 2023

Here you go: The files are too large to fit so I've attached a link to them in Dropbox: https://www.dropbox.com/sh/sle2vmlvc8jr6sb/AAD4vYwjyYn7Mo6xxDrYDtwia?dl=0

This is my input code:
#make glf and mafs files
echo "/work/07707/dgallery/ls6/software/angsd/angsd -b bams_kinship -gl 2 -domajorminor 1 -snp_pval 1e-6 -domaf 1 -minmaf 0.05 -doGlf 3 -out kinMAT" > kins
ls6_launcher_creator.py -j kins -n kins -t 2:00:00 -e $email -w 1 -a $allo
sbatch kins.slurm

#remove header from mafs
zcat kinMAT.mafs.gz | cut -f5 |sed 1d >freq

#make kinship matrix
echo "/work/07707/dgallery/ls6/software/ngsRelate/ngsRelate -g kinMAT.glf.gz -n 65 -f freq -O kinMAT" > kins2
ls6_launcher_creator.py -j kins2 -n kins2 -t 2:00:00 -e $email -w 1 -a $allo
sbatch kins2.slurm

Thank you for your help!

@RRSingleton
Copy link

Hi, was this issue ever resolved? I'm running into the same problem. When I check my glf file, it has the the same number of site as my freq file (69671) and I have the right number of individuals in my glf file (152). Here's the code I used, and links to my files:

#for NGSrelate
nohup angsd -GL 1 -out genolike -nThreads 20 -doGlf 4 -doMajorMinor 1 -SNP_pval 1e-6 -doMaf 1 -bam all.list &

#NGSrelate
zcat genolike.mafs.gz | cut -f5 |sed 1d >freq
nohup ./../NGSrelate/ngsRelate/ngsRelate -g genolike.glf.gz -n 152 -L 69671 -O ngsRelate.out &

mafs: https://drive.google.com/file/d/1s9JM-n2tQ7Pih9zav-_4PQ1LOT95ZNn-/view?usp=sharing
glf: https://drive.google.com/file/d/1GjexTxYJMi3CV8yJk1SpOqC68534Xebn/view?usp=sharing
freq: https://drive.google.com/file/d/1vnoIeJVmfmI3kBdFcOZYfam3ps7yZ6Di/view?usp=sharing

Thank you!

@dgallery
Copy link
Author

I never got it to work. Still get the error when I try to run my code.

@RRSingleton
Copy link

Did you find an alternate program to use? I've used READ, but want a second method to verify.

@ANGSD
Copy link
Owner

ANGSD commented Nov 16, 2023 via email

@RRSingleton
Copy link

Whoops, sorry, that was me just changing flags around to see if i could get a different error. Here's what I used: ./../NGSrelate/ngsRelate/ngsRelate -g genolike.glf.gz -n 152 -f freq -O ngsRelate.out

@ANGSD
Copy link
Owner

ANGSD commented Nov 16, 2023 via email

@RRSingleton
Copy link

I've tried that, but it returns the same error.

@RRSingleton
Copy link

and here's the wc returns:

152 152 6212 all.list
69671 69671 627039 freq

@KHanghoj
Copy link
Collaborator

KHanghoj commented Nov 19, 2023 via email

@RRSingleton
Copy link

The end of the angsd run log has the runtime and everything looks good. I also re-ran angsd with an abridged sample set and get the same error.

@KHanghoj
Copy link
Collaborator

KHanghoj commented Nov 19, 2023 via email

@RRSingleton
Copy link

It ran without errors, here's the output
outfile.zip

@ozgurtoprak08
Copy link

hello I am having the same problem have you figured it out?

@dgallery
Copy link
Author

dgallery commented Apr 2, 2024 via email

@ozgurtoprak08
Copy link

ozgurtoprak08 commented Apr 2, 2024 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants