Paulo Ricardo Gherardi Hein
2009-Mar-03 15:49 UTC
[R] PLS regression on near infrared (NIR) spectra data
Dear collegues, I´ ve worked with near infrared (NIR) spectroscopy to assess chemical, physical, mechanical and anatomical properties of wood. I use "The Unscrambler" software to correlate the matrix of dependent variables (Y) with the matrix of spectral data (X) and I would like to migrate to R. The matrix of spectral variables is very large (2345 columns and n lines, where n = samples), so we used Partial Least Squares Regression to predict a variable y (content of cellulose, for instance) based on the spectral variables, which are the NIR wavelengths. I am new here (since jan2009) and up to now, I not seen anyone commenting about principal component analysis and regression PLS to analyze spectral information in R system. Sorry, I am a R starter... Anybody have any package, or trick to suggest me? Grateful for yours information! -- Paulo Ricardo Gherardi Hein PhD candidate at University of Montpellier 2 CIRAD - PERSYST Department Research unit: Production and Processing of Tropical Woods - TA B-40/16 73 rue Jean-François Breton 34398 Montpellier Cedex 5, France phone: +33 4 67 61 44 51 skype: paulo_hein email: paulo.hein@cirad.fr [[alternative HTML version deleted]]
Andris Jankevics
2009-Mar-04 10:59 UTC
[R] PLS regression on near infrared (NIR) spectra data
Hi, take a look on pls package and it's documentation, there are examples also for NIR data. http://mevik.net/work/software/pls.html Article form "Journal of Statistical Software" http://www.jstatsoft.org/v18/i02 Also "Caret" package can be used to evaluate pls and other regreesion models: http://caret.r-forge.r-project.org/Classification_and_Regression_Training.html Best regards, Andris On Tue, Mar 3, 2009 at 4:49 PM, Paulo Ricardo Gherardi Hein <phein1980 at gmail.com> wrote:> Dear collegues, > > I? ve worked with near infrared (NIR) spectroscopy to assess chemical, > physical, mechanical and anatomical properties of wood. > > I use "The Unscrambler" software to correlate the matrix of dependent > variables (Y) with the matrix of spectral data (X) and I would like to > migrate to R. The matrix of spectral variables is very large (2345 columns > and n lines, where n = samples), so we used Partial Least Squares Regression > to predict a variable y (content of cellulose, for instance) based on the > spectral variables, which are the NIR wavelengths. > > I am new here (since jan2009) and up to now, I not seen anyone commenting > about principal component analysis and regression PLS to analyze spectral > information in R system. Sorry, I am a R starter... > > Anybody have any package, or trick to suggest me? > > Grateful for yours information! > ?-- > Paulo Ricardo Gherardi Hein > PhD candidate at University of Montpellier 2 > CIRAD - PERSYST Department > Research unit: Production and Processing of Tropical Woods - TA B-40/16 > 73 rue Jean-Fran?ois Breton 34398 Montpellier Cedex 5, France > phone: +33 4 67 61 44 51 > skype: paulo_hein > email: paulo.hein at cirad.fr > > ? ? ? ?[[alternative HTML version deleted]] > > > ______________________________________________ > R-help at r-project.org mailing list > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide http://www.R-project.org/posting-guide.html > and provide commented, minimal, self-contained, reproducible code. > >
Bjørn-Helge Mevik
2009-Mar-04 11:42 UTC
[R] PLS regression on near infrared (NIR) spectra data
Paulo Ricardo Gherardi Hein <phein1980 at gmail.com> writes:> I am new here (since jan2009) and up to now, I not seen anyone commenting > about principal component analysis and regression PLS to analyze spectral > information in R system. Sorry, I am a R starter... > > Anybody have any package, or trick to suggest me?There is the package 'pls', with Principal Component Regression (PCR) and Partial Least Squares Regression (PLSR). It also contains a couple of plots that are useful for princomp() or prcomp() analyses (PCA). -- Bj?rn-Helge Mevik
Hi Paulo, You might also want to look at something like the glmnet package (Friedman, Hastie, and Tibshirani). This carries out penalized regression, is designed to work with high numbers of predictors/inputs/columns and relatively few samples/obervations/rows, and is very fast. See: http://www-stat.stanford.edu/~hastie/Papers/glmnet.pdf HTH, Mark. Paulo Ricardo Gherardi Hein wrote:> > Dear collegues, > > I? ve worked with near infrared (NIR) spectroscopy to assess chemical, > physical, mechanical and anatomical properties of wood. > > I use "The Unscrambler" software to correlate the matrix of dependent > variables (Y) with the matrix of spectral data (X) and I would like to > migrate to R. The matrix of spectral variables is very large (2345 columns > and n lines, where n = samples), so we used Partial Least Squares > Regression > to predict a variable y (content of cellulose, for instance) based on the > spectral variables, which are the NIR wavelengths. > > I am new here (since jan2009) and up to now, I not seen anyone commenting > about principal component analysis and regression PLS to analyze spectral > information in R system. Sorry, I am a R starter... > > Anybody have any package, or trick to suggest me? > > Grateful for yours information! > -- > Paulo Ricardo Gherardi Hein > PhD candidate at University of Montpellier 2 > CIRAD - PERSYST Department > Research unit: Production and Processing of Tropical Woods - TA B-40/16 > 73 rue Jean-Fran?ois Breton 34398 Montpellier Cedex 5, France > phone: +33 4 67 61 44 51 > skype: paulo_hein > email: paulo.hein at cirad.fr > > [[alternative HTML version deleted]] > > > ______________________________________________ > R-help at r-project.org mailing list > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide > http://www.R-project.org/posting-guide.html > and provide commented, minimal, self-contained, reproducible code. > >-- View this message in context: http://www.nabble.com/PLS-regression-on-near-infrared-%28NIR%29-spectra-data-tp22311467p22328510.html Sent from the R help mailing list archive at Nabble.com.