Closed DaniEstevezBarcia closed 2 years ago
Hi @DaniEstevezBarcia, I've pushed a new version of the write.ped
function. if pop!=NULL
, the first column of the hierfstat_object should contains genotypes at the first locus; otherwise it should be the population identifier. Let me know if this fixes your problem
Thanks, will do
It does not. In fact now the map result is completely different:
0 Lloc.fac 0 0 0 Lloc.n.all 0 0 0 Lall.names 0 0 0 Lploidy 0 0 0 Ltype 0 0 0 Lother 0 0 0 Lcall 0 0 0 Lpop 0 0 0 Lstrata 0 0 0 Lhierarchy 0 0
Could you share your code pls? (DM if you prefer). I suspect you are using a genind
object as argument to write.ped
rather than a hierfstat
object, could it be so?
Ok, I feel stupid. Indeed, the issue was a typo on which I was running it with a genind. It works well now.
Many thanks
To whom it may concern. Whenever using something of the sort:
write.ped(hierfstat_object, fname = "path/to/file", pop = pop, ilab = inds)
The first locus is removed from both the map and ped objects.