stschiff / msmc2

GNU General Public License v3.0
53 stars 9 forks source link

Running MSMC2 on multiple unphased genomes gives Unexpected '-' when converting from type string to type ulong #36

Closed athenalql closed 3 years ago

athenalql commented 3 years ago

Hi Stephen,

Thanks for the great software. I am working on a non-model organism and have two samples from each population. I have no experience with phasing the genomes, so I thought I could start with unphased genomes for testing.

I was trying to run msmc2 on multiple unphased genomes for population size estimation as mentioned in the protocol using this code:

msmc2 -t 25 -o $OUTDIR/MY1.2_4hap_INDO-MY_1.msmc2 -I 2-3,4-5 $INPUTDIR/INDO-MY_1.scaf*.multihetsep.txt

I kept receiving the error below (the first seven lines of the error messages)

There was no problem when I changed the -I configuration to what is used for phased genomes -I 2,3,4,5.

I attach an example of hetsep file

INDO-MY_1.scaf1.multihetsep.txt

error in parsing command line: std.conv.ConvException@/lustre7/home/athenalql/_install/dmd2/linux/bin64/../../src/phobos/std/conv.d(1967): Unexpected '-' when converting from type string to type ulong
----------------
??:? pure @safe ulong std.conv.toImpl!(ulong, immutable(char)[]).toImpl(immutable(char)[]) [0x57e2be]
??:? pure @safe ulong std.conv.to!(ulong).to!(immutable(char)[]).to(immutable(char)[]) [0x57df23]
??:? pure @safe ulong std.functional.unaryFun!("a.to!size_t()", "a").unaryFun!(immutable(char)[]).unaryFun(ref immutable(char)[]) [0x57fcb6]

Thanks in advance!

Lim

athenalql commented 3 years ago

I realised then that I was using an earlier version of MSMC2 (2.0.0)

I updated to the latest version (2.1.1) and it could run perfectly now.

Sorry for the opening this issue!