Martin Maechler
2000-Jan-31 15:21 UTC
[Rd] Feature requests for princomp(.) : Allow cor() specifications
(all in subject). If I want to do a PC analysis in a situation with missing data, I may want to have same flexibility as with "cor(.)", e.g., I may want princomp(x, ..., use.obs = "pairwise.complete") Actually, I may want even more flexibility. Currently, princomp(.) has if (cor) cv <- get("cor", envir = .GlobalEnv)(z) else cv <- cov(z) edc <- eigen(cv) and If may want it to use a robust covariance or correlation matrix instead, e.g., princomp(x, cv = cov.mve(x), .....) Note that for prcomp() which works on the SVD rather than the correlation/cov. matrix, similar flexibility may be required. Opinions? Volunteers? (either one is sufficient to answer!) Martin -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-devel mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-devel-request@stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
Prof Brian Ripley
2000-Feb-02 14:37 UTC
[Rd] Feature requests for princomp(.) : Allow cor() specifications
> From: Martin Maechler <maechler@stat.math.ethz.ch> > Date: Mon, 31 Jan 2000 16:21:10 +0100 (MET) > > (all in subject). >Having you been looking at your S-PLUS recently?> If I want to do a PC analysis in a situation with missing data, > I may want to have same flexibility as with "cor(.)", > e.g., I may want > > princomp(x, ..., use.obs = "pairwise.complete")Um. That's a way not to get a valid covariance matrix and hence no valid PCA.> Actually, I may want even more flexibility. > Currently, > princomp(.) > has > > if (cor) > cv <- get("cor", envir = .GlobalEnv)(z) > else cv <- cov(z) > edc <- eigen(cv) > > and If may want it to use a robust covariance or correlation matrix instead, > e.g., > > princomp(x, cv = cov.mve(x), .....)as in princomp(x, data = NULL, covlist = NULL, weights = NULL, scores = T, cor = F, na.action, subset) ?> Note that for prcomp() which works on the SVD rather than the > correlation/cov. matrix, similar flexibility may be required. > > Opinions? > Volunteers? > > (either one is sufficient to answer!) >It really is easy. If there were not a feature freeze on I would do it right now. -- Brian D. Ripley, ripley@stats.ox.ac.uk Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/ University of Oxford, Tel: +44 1865 272861 (self) 1 South Parks Road, +44 1865 272860 (secr) Oxford OX1 3TG, UK Fax: +44 1865 272595 -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-devel mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-devel-request@stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._