The documentation mentions checking for file format errors, but I would like to suggest adding additional error checking. I have pedigree IDs that don't atch between the id coefficient file and the pedigree file. This happened because I used SOLAR to generate a pedigree file, and it remapped my preferred pedigree ID numbers to a different range. I accidentally ran IBDLD (my first attempt, once I got the coefficient file made) without correctly mapping the IDs, and it produced a Segfault:
gdb --args ~/install/ibdld/IBDLDv3.00/IBDLD -p ../merlin_snp_pre-solar/chr21/singlefam_wiped.ped -m ../merlin_snp_pre-solar/wiped_indep_lowerror_NI.with_inferred_chr21.map -method LD-RR -dist 5
GNU gdb (GDB) 7.4.1-debian
Copyright (C) 2012 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from /home/gringer/install/ibdld/IBDLDv3.00/IBDLD...done.
(gdb) r
Starting program: /home/gringer/install/ibdld/IBDLDv3.00/IBDLD -p ../merlin_snp_pre-solar/chr21/singlefam_wiped.ped -m ../merlin_snp_pre-solar/wiped_indep_lowerror_NI.with_inferred_chr21.map -method LD-RR -dist 5
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
IBDLD version 3.00.
Parameters setting are checked!
Process step: 0 3 1
All input files:
Pedigree file: ../merlin_snp_pre-solar/chr21/singlefam_wiped.ped
Map File: ../merlin_snp_pre-solar/wiped_indep_lowerror_NI.with_inferred_chr21.map
Identity coefficient file: ./prefix.idcoeff
The SNP in the map file is to be sorted!
Transition rate files prefix: ./prefix
Background LD parameter files prefix: ./prefix
Kinship,IBD etc files prefix: ./prefix
Using Method: LD-RR PreviousLociNum=50
Simulation times: 100000
Available RAM in megabytes: 1000M
Seed number: 1359345079
Trait column number: 0
Genotype error rate: 0.01
Individual's genotype missing rate threshold: 0.8
Minor allele freqency: 0.01
Analyzed chromosome: all
Don't output any IBD information for each locus, only output empirical kinship coefficient of pair individuals.
Don't Output empirical inbreeding coefficient for the individuals.
Don't Output HBD probability at some loci for the individuals.
Don't output segment.
Run step1 (Transition Rate Estimation)!
Reading the file: ./prefix.idcoeff
./prefix.idcoeff File consist of 963966 Lines.
Program received signal SIGSEGV, Segmentation fault.
0x00007ffff74f473c in std::string::compare(char const*) const () from /usr/lib/x86_64-linux-gnu/libstdc++.so.6
I'll do the mapping correctly, and re-check to see if this fixes the error. In any case, there's something IBDLD is seeing that it doesn't like.
Please contact me if you want the input pedigree files sent by email.
I had at least one other input error with my files. MERLIN decided to put a single line containing only the word 'end' at the end of each file (I was doing genotype removal by mendelian expectation). I have since removed this line, and done the conversion from our study ID to the MERLIN IDs. Now it doesn't crash straight away, but produces the following error(s):
...
Cann't[sic] find pair: 1 1005 240
Cann't find pair: 1 1005 851
Cann't find pair: 1 1005 868
Cann't find pair: 1 1005 176
... etc.
As such, it's likely that the pedigree mismatch *is* checked for, and it was the 'end' line that caused the segfault.
The Segfault is most likely due to 'end' line in file, given that the pairs check is done in IBDFold/FileCheck.cpp. Presumably a check for the number of columns in the current line prior to any array subsetting or similar will fix this.
Yes, You can send your pedigree file to me, Let me Check.