Subscribe Bookmark RSS Feed

apply my PLS model to new data

anakar

New Contributor

Joined:

Feb 21, 2017

Hey all, 

I am using Partial Least Squares (PLS) analysis to find a model to predict concentration of sustance from spectral data - which means I have 6800 variables.

After tweaking the data, resampling, tweaking some more and other things I seem to have found a predictive model that I can trust.

 

My question is

How can I apply this model to new data? even one sample at a time.

 

Thanks!

Amir

 

PS - Using JMP Pro 13

2 REPLIES
ian_jmp

Staff

Joined:

Jun 23, 2011

If you are working interactively, just go to the red triangle and save the prediction formula to make a new (formula) column in your data table (in the case of PLS, you want 'Save Columns > Save Prediction Formula'). Then add a new row to the data table, and so long as you enter values for all the predictors you will get predicted values in the same row (via the formula you saved).

 

This can also be done through JSL if you want to automate things if needed.

 

Peter_Bartell

Joined:

Jun 5, 2014

And to supplement my colleague Ian's reply, since you are running JMP Pro version 13, you might find value in publishing the formula to the Formula Depot platform? This platform allows you to write the model into production/database oriented languages such as Python, C, and SQL. So if the 'new' data is starting out in a database let's say, you could perhaps cleverly use the scoring code to characterize your materials on the production database side. Many of my customers use the Formula Depot scoring code application for just this purpose.

 

And I'll just say...great application for PLS as well!