[adegenet-forum] assigning pop in genind object

takele taye takele_taye at yahoo.com
Fri Feb 8 13:49:02 CET 2013

I converted my hj.str data into genind object using the read.structure function. hj<- read.structure(file="hj.str", n.ind=747, n.loc=168344,  onerowperind=TRUE, col.lab=1, col.pop=2, NA.char=-9, ask=FALSE)
My data contains two populations (represented by 1 & 2 in pop column of the hj.str data), the data was not sorted by population. How can I define the population of each individual in the genind object hj at pop.
I tried this onepop_1 <- hj at pop==1pop_2 <- hj at pop==2
However, this has clumped the entire population just into two dots instead of representing each individual in the PCA plot.
Any help is appreciated
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.r-forge.r-project.org/pipermail/adegenet-forum/attachments/20130208/b8084765/attachment.html>

More information about the adegenet-forum mailing list