KING kinship inference error
2
0
Entering edit mode
3.4 years ago
ritafonsa • 0

Hello,

I'm trying to use KING for estimating kinship between individuals. I have a vcf file that resulted from a de novo assembly of ddrad seq data.

First, I tried to convert my vcf file to .bed file using Plink2.0, but it failed saying that human genome didnĀ“t have that much chromosomes. I search a bit online and since my CHR column represents loci and not chromosomes I would have to include a letter on CHR ID. So I did add a "C" in the begging of every CHR ID and also used the flag -allow-extra-chr on plink.

I runned the following command:

./plink2 --vcf myfile.vcf --allow-extra-chr --make-bed --out one_snp

When I run KING:

./king -b one_snp.bed --related

I get the following error:

Read in PLINK bim file one_snp.bim...                                                              Genotype data consist of 0 autosome SNPs                                                         12469 other SNPs are removed.                                                                    PLINK maps loaded: 0 SNPs                                                                                                                                                                       FATAL ERROR -                                                                                    No autosome SNPs are available. Please check your map file.

I think the problem may be with the .fam file, but I'm not sure how to correct it since I don't have information on pedigree data. Is it necessary to run KING? Does anyone have any idea what is the problem?

Thanks in advance

king plink fam • 2.7k views
ADD COMMENT
0
Entering edit mode

I came here two years later. Did you find a solution? I have the same issue now with post impute dataset. Thanks

ADD REPLY
2
Entering edit mode
18 months ago
DBScan ▴ 450

I've also tried that once, but wasn't successful as well. I ended up using SNPRelate R package, it provides relatedness inference (snpgdsIBDKING) as well (with KING algorithm). Conversion from VCF to GDS is very easy (snpgdsVCF2GDS).

ADD COMMENT
2
Entering edit mode
18 months ago

KING does not include SNPs on scaffolds in its analysis. You have to lie to it and provide a .bim file that appears to only have regular chromosomes.

However, plink2 --make-king-table (https://www.cog-genomics.org/plink/2.0/distance#make_king ) does not have that limitation.

ADD COMMENT

Login before adding your answer.

Traffic: 1787 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6