[adegenet-forum] How are NA values handled by glPca ?

Jombart, Thibaut t.jombart at imperial.ac.uk
Tue Mar 18 13:32:57 CET 2014


Hello, 

missing values are replaced by the means of available observations (i.e. mean allele frequency).

Cheers
Thibaut
________________________________________
From: adegenet-forum-bounces at lists.r-forge.r-project.org [adegenet-forum-bounces at lists.r-forge.r-project.org] on behalf of Guillaume Louvel [yom7 at hotmail.fr]
Sent: 18 March 2014 11:33
To: adegenet-forum at lists.r-forge.r-project.org
Subject: [adegenet-forum] How are NA values handled by glPca ?

Hi all,

I am doing a glPca on a genlight object of 627719 SNPs and 934 individuals (so I don't want to use genind and dudi.pca which are too slow and too heavy for this size).

With genind objects, it's easy to replace NA by the mean for example, using na.replace or creating it with df2genind( dataframe , missing="mean").

However, it's not possible to replace missing values in genlight objects, because it is binary encoded, and the function glPca does not complaint about missing values (not like dudi.pca).

So, the question is, what does glPca with missing values ? Because this function is part of the adegenet package whereas dudi.pca comes from ade4, is the replacement of NA by the mean implemented in glPca ? or do I need to do a specific trick ?

Thank you !

Guillaume
_______________________________________________
adegenet-forum mailing list
adegenet-forum at lists.r-forge.r-project.org
https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/adegenet-forum


More information about the adegenet-forum mailing list