cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Check out the JMP® Marketplace featured Capability Explorer add-in
Choose Language Hide Translation Bar
PValueEnemy
Level II

How to predict a fitted model in new data?

Hello!

I fitted a model using a dataset, namely X1, and now I have a new dataset with same columns, namely X2. I want to predict my response in X2 by using the predicted formula, but don't know the best practices in JMP.

 

Currently, I've fitted the model in a dataset pilling X1 and X2 (see figure below), so I would use only X1 data to fit, but when I click Save Columns > Predicted Formula, it would predict to X2 as well.

PValueEnemy_0-1700059333409.png

Is there a better practice to do it? Suppose I have a third dataset X3, should I also pile it up with X1 and repeat the process?

Thanks

1 ACCEPTED SOLUTION

Accepted Solutions
Victor_G
Super User

Re: How to predict a fitted model in new data?

Hi @PValueEnemy,

 

There may be several options available, depending if you use JMP or JMP Pro. Here are two possible options :

  • With JMP : You can select the rows from sets X2 and X3, and exclude them. You then fit your model (only on dataset X1), and save the Prediction Formula to get predictions for X2 and X3.
    You can also add a column to name the groups like you did, and only do the modeling using a data filter (for example, select only "Data = Current"), and then saving the Prediction formula to get the predictions for all the datasets.
  • With JMP Pro : In the menu "Analyze", "Predictive Modeling", you have the option to "Make a Validation Column". Using a column to name the source of the data (X1, X2, X3, ...) you can then do a Grouped Validation Column, so that all experiments from set X1 are in training, and experiments from sets X2 and X3 are in Test.
    Fitting a model and using this validation column enable to fit a model using only data from X1, and then assess the prediction accuracy on test sets (X2 and X3), as well as saving a Prediction formula like before.

 

I hope this answer will help you,

Victor GUILLER
L'Oréal Data & Analytics

"It is not unusual for a well-designed experiment to analyze itself" (Box, Hunter and Hunter)

View solution in original post

2 REPLIES 2
Victor_G
Super User

Re: How to predict a fitted model in new data?

Hi @PValueEnemy,

 

There may be several options available, depending if you use JMP or JMP Pro. Here are two possible options :

  • With JMP : You can select the rows from sets X2 and X3, and exclude them. You then fit your model (only on dataset X1), and save the Prediction Formula to get predictions for X2 and X3.
    You can also add a column to name the groups like you did, and only do the modeling using a data filter (for example, select only "Data = Current"), and then saving the Prediction formula to get the predictions for all the datasets.
  • With JMP Pro : In the menu "Analyze", "Predictive Modeling", you have the option to "Make a Validation Column". Using a column to name the source of the data (X1, X2, X3, ...) you can then do a Grouped Validation Column, so that all experiments from set X1 are in training, and experiments from sets X2 and X3 are in Test.
    Fitting a model and using this validation column enable to fit a model using only data from X1, and then assess the prediction accuracy on test sets (X2 and X3), as well as saving a Prediction formula like before.

 

I hope this answer will help you,

Victor GUILLER
L'Oréal Data & Analytics

"It is not unusual for a well-designed experiment to analyze itself" (Box, Hunter and Hunter)

Re: How to predict a fitted model in new data?

JMP Pro also provides the ability to publish a model (formula) in the Formula Depot and then use it in many different ways, including adding to other columns or new columns.