similar to: Warning: ignored non function "scale"

Displaying 20 results from an estimated 10000 matches similar to: "Warning: ignored non function "scale""

1998 Aug 26
0
prcomp & princomp - revised
My previous post about prcomp and princomp was done in some haste as I had long ago indicated to Kurt that I would try to have this ready for the June release, and it appeared that I would miss yet another release. I also need to get it out before it becomes hopelessly buried by other work. Brian Ripley kindly pointed out some errors, and also pointed out that I was suggesting replacing some
2010 Nov 10
2
prcomp function
Hello, I have a short question about the prcomp function. First I cite the associated help page (help(prcomp)): "Value: ... SDEV the standard deviations of the principal components (i.e., the square roots of the eigenvalues of the covariance/correlation matrix, though the calculation is actually done with the singular values of the data matrix). ROTATION the matrix of variable loadings
2002 Oct 29
0
patch to mva:prcomp to use La.svd instead of svd (PR#2227)
Per the discussion about the problems with prcomp() when n << p, which boils down to a problem with svd() when n << p, here is a patch to prcomp() which substitutes La.svd() instead of svd(). -Greg (This is really a feature enhancement, but submitted to R-bugs to make sure it doesn't get lost. ) *** R-1.6.0/src/library/mva/R/prcomp.R Mon Aug 13 17:41:50 2001 ---
2000 Apr 26
1
Factor Rotation
How does one rotate the loadings from a principal component analysis? Help on function prcomp() from package mva mentions rotation: Arguments retx a logical value indicating whether the rotated variables should be returned. Values rotation the matrix of variable loadings (i.e., a matrix whose olumns contain the eigenvectors). The function princomp returns this in the element
2016 Mar 30
1
reg-tests-1a fails with r70391
Hi, This may be a `transitional' bug but I am reporting a make check fail with R-devel r70391 in reg-tests-1a.Rout. The tail of reg-tests-1a.Rout.fail is > ## prcomp(tol=1e-6) > x <- matrix(runif(30),ncol=10) > s <- prcomp(x, tol=1e-6) > stopifnot(length(s$sdev) == ncol(s$rotation)) Error: length(s$sdev) == ncol(s$rotation) is not TRUE Execution halted Looking at
2012 Jun 20
1
prcomp: where do sdev values come from?
In the manual page for prcomp(), it says that sdev is "the standard deviations of the principal components (i.e., the square roots of the eigenvalues of the covariance/correlation matrix, though the calculation is actually done with the singular values of the data matrix)." ?However, this is not what I'm finding. ?The values appear to be the standard deviations of a reprojection of
2005 Aug 03
3
prcomp eigenvalues
Hello, Can you get eigenvalues in addition to eigevectors using prcomp? If so how? I am unable to use princomp due to small sample sizes. Thank you in advance for your help! Rebecca Young -- Rebecca Young Graduate Student Ecology & Evolutionary Biology, Badyaev Lab University of Arizona 1041 E Lowell Tucson, AZ 85721-0088 Office: 425BSW rlyoung at email.arizona.edu (520) 621-4005
2008 Jan 04
1
PCA error: svd(x, nu=0) infinite or missing values
Hi, I am trying to do a PCA on my data but I keep getting the error message svd(x, nu=0) infinite or missing values >From the messages posted on the subject, I understand that the NAs in my data might be the problem, but I thought na.omit would take care of that. Less than 5% of my cells are missing data. However, the NAs are not regularly distributed across my matrix: certain cases and
2010 May 15
2
Attempt to customise the "plotpc()" function
Dear R-list, Among the (R-)tools, I've seen on the net, for (bivariate) Principal Component scatter plots (+histograms), "plotpc" [1] is the one I like most. By default it performs PCA on a bivariate dataset based on R's "princomp()" (which is the eigenvector-based algebraic solution to PCA). I would like to modify "plotpc()" in order be able, as an
2009 Nov 25
1
which to trust...princomp() or prcomp() or neither?
According to R help: princomp() uses eigenvalues of covariance data. prcomp() uses the SVD method. yet when I run the (eg., USArrests) data example and compare with my own "hand-written" versions of PCA I get what looks like the opposite. Example: comparing the variances I see: Using prcomp(USArrests) ------------------------------------- Standard deviations: [1] 83.732400 14.212402
2009 Mar 10
1
Using napredict in prcomp
Hello all, I wish to compute site scores using PCA (prcomp) on a matrix with missing values, for example: Drain Slope OrgL a 4 1 NA b 2.5 39 6 c 6 8 45 d 3 9 12 e 3 16 4 ... Where a,b... are sites. The command > pca<-prcomp(~ Drain + Slope + OrgL, data = t, center = TRUE, scale = TRUE, na.action=na.exclude) works great, and from
2008 Jun 11
3
Finding Coordinate of Max/Min Value in a Data Frame
Hi, Suppose I have the following data frame. __BEGIN__ > library(MASS) > data(crabs) > crab.pca <- prcomp(crabs[,4:8],retx=TRUE) > crab.pca$rotation PC1 PC2 PC3 PC4 PC5 FL 0.2889810 0.3232500 -0.5071698 0.7342907 0.1248816 RW 0.1972824 0.8647159 0.4141356 -0.1483092 -0.1408623 CL 0.5993986 -0.1982263 -0.1753299 -0.1435941 -0.7416656 CW
2004 Nov 14
2
Exporting to file: passing source name to file name in loop
Hi, I'm having a mental block as to how I can automatically assign filenames to the output of the following code. I am wishing to create a separate .png file for every image created, each of them having a sequential filename ie "sourcefile_index.png" so that I can create a movie from them. Please could someone tell me where I am going wrong? the following code works fine and
2000 Dec 01
1
simple (NEWBIE) question re: prcomp or princomp
Hi, I am a new user of R, and apologize beforehand for the simplistic nature of this question: I ran prcomp on a data set with 4 variables, and am able to see the summary information (variance contribution, rotation matrix, plots, etc.). However, I'd also like to extract the actual values of the principal components (PC) corresponding to each sample. I've looked in the help, on-line
2006 Jun 16
2
bug in prcomp (PR#8994)
The following seems to be an bug in prcomp(): > test <- ts( matrix( c(NA, 2:5, NA, 7:10), 5, 2)) > test Time Series: Start = 1 End = 5 Frequency = 1 Series 1 Series 2 1 NA NA 2 2 7 3 3 8 4 4 9 5 5 10 > prcomp(test, scale.=TRUE, na.action=na.omit) Erro en svd(x, nu = 0) : infinite or missing values in 'x'
2010 Jun 15
1
Getting the eigenvectors for the dependent variables from principal components analysis
Dear listserv, I am trying to perform a principal components analysis and create an output table of the eigenvalues for the dependent variables. What I want is to see which variables are driving each principal components axis, so I can make statements like, "PC1 mostly refers to seed size" or something like that. For instance, if I try the example from ?prcomp > prcomp(USArrests,
2004 Feb 17
1
Comparison of % variance explained by each PC before AND after rotation
Hello again- Thanks to Prof. Ripley for responding to my previous question. I would like to clarify my question using sample code. I will use some sample code taken from ?prcomp Again, I would like to compare the % variance explained by each PC before and after rotation. < code follows > data(USArrests) pca = prcomp(USArrests, scale = TRUE) # proportion variance explained by each
2000 Jun 15
1
prcomp help: is this a typo?
Dear All, The help for prcomp, under "Value" says: sdev: the standard deviation of the principal components (i.e., the eigenvalues of the cov matrix, though the calculation is actually done with the singular values of the data matrix). The way I read it, it implies that the sdev are the eigenvalues, but I think that sdev is actually the square root of the
2008 Sep 17
1
rgl: plot3d and ellipse3d
Hi I'm trying to make a 3d plot showing a point cloud, the corresponding data ellipse and the principal axes of the ellipse as vectors. library(rgl) data(trees) cov <- cov(trees) mu <- mean(trees) plot3d(trees, type="s", size=0.5, col="blue", cex=2) In this step, an extra box is added. I've tried using box=FALSE, but it has no effect. # how to avoid the
2009 Nov 09
4
prcomp - principal components in R
Hello, not understanding the output of prcomp, I reduce the number of components and the output continues to show cumulative 100% of the variance explained, which can't be the case dropping from 8 components to 3. How do i get the output in terms of the cumulative % of the total variance, so when i go from total solution of 8 (8 variables in the data set), to a reduced number of