A note on this, to get relevant data from a genind or a genpop object, you mostly need only to use tab(...). Examples using nancycats:
## load toy data
data(nancycats)
x <- nancycats
## get individual allele counts:
ind.counts <- tab(x)
## get individual allele frequencies
ind.freq <- tab(x, freq=TRUE)
## get allele counts per groups, with a group factor 'grp'
pop(x) <- grp
grp.counts <- tab(genind2genpop(x))
## get allele frequencies per groups, with a group factor 'grp'
pop(x) <- grp
grp.freq <- tab(genind2genpop(x), freq=TRUE)
So basically using natively genind objects should be relatively straightforward?
A note on this, to get relevant data from a genind or a genpop object, you mostly need only to use
tab(...)
. Examples using nancycats:So basically using natively genind objects should be relatively straightforward?