hi, proper PCA is run on centered data (axis=0) otherwise it's a truncated SVD. I seams you want a PCA on X.T (X transposed).
HTH Alex On Tue, Jul 22, 2014 at 3:14 AM, Adam Hughes <hughesada...@gmail.com> wrote: > Hi, > > I'm really enjoying scikit learn and looking to add a lite version of PCA to > some programs I'm working on, derived mostly from the decomposition.PCA > class. I have a few quick questions, and really would appreciate some help > from the experts. > > First, the PCA class is designed to operate on data of dimensions: > n_samples, n_features > > And transforms to: > n_samples, n_components > > Our data is of the form: > n_features, n_samples > > However we are doing correlation spectroscopy, so we actually want to treat > the samples as the pertubation axis. Therefore, our components should end > up with dimensions: > > n_features, n_components > > The dimensions sklearn PCA is returning looks fine, but I'm worried about > the mean_centering operaiton. I want our data to be centered around axis=1. > I'm wondering if I change just the mean centering axis, if you think > anything else in the analysis will break or go awry? Or if you think that's > safe, given the dimensions of my data? > > And finally, I'm curious wjat it means to run PCA on data that is not > mean-centered. Does it lose all interpretation, or is it sill a > valid/sometimes performed operation? > > Thanks guys! > > ------------------------------------------------------------------------------ > Want fast and easy access to all the code in your enterprise? Index and > search up to 200,000 lines of code with a free copy of Black Duck > Code Sight - the same software that powers the world's largest code > search on Ohloh, the Black Duck Open Hub! Try it now. > http://p.sf.net/sfu/bds > _______________________________________________ > Scikit-learn-general mailing list > Scikit-learn-general@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/scikit-learn-general > ------------------------------------------------------------------------------ Want fast and easy access to all the code in your enterprise? Index and search up to 200,000 lines of code with a free copy of Black Duck Code Sight - the same software that powers the world's largest code search on Ohloh, the Black Duck Open Hub! Try it now. http://p.sf.net/sfu/bds _______________________________________________ Scikit-learn-general mailing list Scikit-learn-general@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/scikit-learn-general