similar to: Principal Components Analysis

Displaying 20 results from an estimated 4000 matches similar to: "Principal Components Analysis"

2008 Feb 14
1
Principal component analysis PCA
Hi, I am trying to run PCA on a set of data with dimension 115*300,000. The columns represnt the snps and the row represent the individuals. so this is what i did. #load the data code<-read.table("code.txt", sep='\t', header=F, nrows=300000) # do PCA # pr<-prcomp(code, retx=T, center=T) I am getting the following error message "Error: cannot allocate vector of
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
2009 Nov 20
1
how to link C code with gsl from R CMD and dyn.load
Hi, I am writing a function in C that is meant to be called by R. In the C function, I used a gsl function gsl_stats_mean. The code is as simple as below void gsl(double *m, int *dim){ int r, c; r = dim[0]; c = dim[1]; double mean = gsl_stats_mean(&m[0], 1, r); Rprintf("mean = %f\n", mean); } The C code is succesfully compiled and the output is as follows. $ R CMD SHLIB
2006 Nov 16
1
Problems with principal components analysis PCA with prcomp
Dear friends, I am beginning to use R software in my academic research and I'm having some problems regarding the use of PCA. I have a table with 24445 rows and 9 columns, and I used the function prcomp() to do the analysis. Working with an example?: x<-read.table("test.txt", header=T) row.names(x)<-x[,1] x<-x[,-1] require(stats) pca<-prcomp(x, scale=T) names(pca) ##
2011 Jul 29
1
Limited number of principal components in PCA
Hi all, I am attempting to run PCA on a matrix (nrow=66, ncol=84) using 'prcomp' (stats package). My data (referred to as 'Q' in the code below) are separate river streamflow gaging stations (columns) and peak instantaneous discharge (rows). I am attempting to use PCA to identify regions of that vary together. I am entering the following command:
2016 Apr 18
1
project test data into principal components of training dataset
Hi there, I've a training dataset and a test dataset. My aim is to visually allocate the test data within the calibrated space reassembled by the PC's of the training data set, furthermore to keep the training data set coordinates fixed, so they can serve as ruler for measurement for additional test datasets coming up. Please find a minimum working example using the wine dataset below.
2012 Feb 27
3
Principal Components for matrices with NA
Hello, I have a matrix with 267 columns, all rows of which have at least one column missing (NA). All three methods i've tried (pcs, princomp, and prcomp) fail with either "Error in svd(zsmall) : infinite or missing values in 'x'" (latter two) or "Error in cov.wt(z) : 'x' must contain finite values only" The last one happens because of the check if
2008 Dec 11
2
Principal Component Analysis - Selecting components? + right choice?
Dear R gurus, I have some climatic data for a region of the world. They are monthly averages 1950 -2000 of precipitation (12 months), minimum temperature (12 months), maximum temperature (12 months). I have scaled them to 2 km x 2km cells, and I have around 75,000 cells. I need to feed them into a statistical model as co-variates, to use them to predict a response variable. The climatic
2010 Aug 14
2
[LLVMdev] clang: compile c code from char array?
Hi, how do I compile c code from a char array in clang? Im using code from the interpreter example. Thanks. char *cCode; // the char array // fill array with code goes here... // Initialize a compiler invocation object from the clang (-cc1) arguments. const driver::ArgStringList &CCArgs = Cmd->getArguments(); llvm::OwningPtr<CompilerInvocation> CI(new CompilerInvocation);
2009 Apr 03
1
Weighted principal components analysis?
Hello R-ers, I'm trying to do a weighted principal components analysis. I couldn't find any such option with princomp or prcomp. Does anyone know of a package or way to do this? More specifically, the observations I'm working with are averages from populations of varying sizes. I thus need to weight the observations by sample size. Ideally I could apply these weights at the cell
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,
2011 Apr 01
1
principal components
HI all, I am trying to compute the EOF of a matrix using prcomp but unable to get the expansion co-efficients. is it possible using prcomp or are there any other methods thanks nuncio -- Nuncio.M Research Scientist National Center for Antarctic and Ocean research Head land Sada Vasco da Gamma Goa-403804 [[alternative HTML version deleted]]
2005 Mar 31
1
loadings or summary in Principal components
May be a simple question, but not understanding why in princomp I get different results for loadings and summary for my eigenvectors and eigenvalues. When I use pc.cr$loadings using the USArrests dataset the proportion of variance is equal for each of the components, but when summary(pc.cr) is used the proportion of variance is showing different proportions. My question is why do they differ? I
2009 Feb 06
1
Joint test
Dear All, I am estimating a Cox proportional hazard model, with several interactions of the type a*z + a*y + a*x + b*z + b*y + b*x. I need to know if the first three (the "a"s) are jointly significantly different from the last three (the "b"s). I have tried several approaches, but have been unsuccessful. Here's the model, and the code I came up with, with the obvious
2009 Aug 11
3
Problem with modifying a data frame
Hi All, this could be a simple question but I am looking into modifying a data frame using a "condition" without the need to loop over that data, would that be possible? I have tried the following > x<-c(4,5,6,6,8) > y<-c("a","b","b","b","c") > data<-data.frame(x,y) > data x y 1 4 a 2 5 b 3 6 b 4 6 b 5 8 c if
2010 Aug 15
2
[LLVMdev] clang: compile c code from char array?
no, does not help, ive already looked at it. none none-17 wrote: > > This thread may help: > http://lists.cs.uiuc.edu/pipermail/cfe-dev/2010-June/009507.html > > On Sun, Aug 15, 2010 at 2:50 AM, gafferuk <gafferuk at gmail.com> wrote: > >> >> Hi, how do I compile c code from a char array in clang? >> >> Im using code from the interpreter
2006 Feb 27
1
question about Principal Component Analysis in R?
Hi all, I am wondering in R, suppose I did the principal component analysis on training data set and obtain the rotation matrix, via: > pca=prcomp(training_data, center=TRUE, scale=FALSE, retx=TRUE); Then I want to rotate the test data set using the > d1=scale(test_data, center=TRUE, scale=FALSE) %*% pca$rotation; > d2=predict(pca, test_data, center=TRUE, scale=FALSE); these two
2005 Jul 21
1
principal component analysis in affy
Hi, I have been using the prcomp function to perform PCA on my example microarray data, (stored in metric text files) which looks like this: 1a 1b 1c 1d 1e 1f ...................................................4r 4s 4t g1 1.2705 1.2766 ...........................................................2.0298 g2 0.1631
2002 Dec 09
2
Principal component analysis
Dear R users, I'm trying to cluster 30 gene chips using principal component analysis in package mva.prcomp. Each chip is a point with 1,000 dimensions. PCA is probably just one of several methods to cluster the 30 chips. However, I don't know how to run prcomp, and I don't know how to interpret it's output. If there are 30 data points in 1,000 dimensions each, do I have to
2010 Aug 15
0
[LLVMdev] clang: compile c code from char array?
This thread may help: http://lists.cs.uiuc.edu/pipermail/cfe-dev/2010-June/009507.html On Sun, Aug 15, 2010 at 2:50 AM, gafferuk <gafferuk at gmail.com> wrote: > > Hi, how do I compile c code from a char array in clang? > > Im using code from the interpreter example. > Thanks. > > char *cCode; // the char array > // fill array with code goes here... > > >