bwringe / hybriddetective

13 stars 7 forks source link

Error in getTopLoc #9

Open millerjm86 opened 5 years ago

millerjm86 commented 5 years ago

Hi There,

I'm very interested to apply hybriddetective to my SNP data. But when I try and use getTopLoc I get the error below

_Error in getTopLoc(GPD = "EG_AB_Diagnostic_Loci_MAF01GenePop.txt", panel.size = 30) : File must contain two populations. The package genepopedit offers editing functions

This error is really strange to me since I have used the same file in freqbasedsim_GTFreq and it worked just fine. Any idea what might be going on?

Thanks

simoneae commented 2 years ago

@millerjm86 Hello. Were you able to find the source of this error? When I grep my genepop file, there are two lines with "Pop" and I am uncertain why getTopLoc's call of Genepopedit's genepop_detective() function does not recognize two populations. Thank you.

millerjm86 commented 2 years ago

Hi @Simone-Evans. Unfortunately no I was not able to get this command to work. It wasn't critical for my project so I didn't pursue it very hard.

simoneae commented 2 years ago

@millerjm86 I got it to work for my data by changing the individual sample names to start with "pop1" or "pop2" in addition to the line designating the two population groups. I believe Hybriddetective was determining the number of samples based on there SiteName (n=18) because this was the number of populations genepop_detective() identified.

Pop pop1_SiteName_SampleID pop1_SiteName_SampleID Pop pop2_SiteName_SampleID pop2_SiteName_SampleID