How to modify hyperparameters in Model Screening platformHi JMP experts,
I find the Model Screening platform is very useful. I've figured out the hyperparameters through the Tuning Design Table, so I'm wondering if there's a way to modify hyperparameters in Model Screening platform, such as JSL.
If the platform can't modify the hyperparameters, can I use the default parameters in the article.
Looking forward to your reply
Advanced Statistical ModelingRe: How to modify hyperparameters in Model Screening platformHi @Wang123,
Welcome in the Community !
Have you read the documentation about Model Screening ? To answer your question directly, here is the answer in the JMP Help : "The modeling platforms use default options and tuning parameters in model fitting. You can try to improve the fit past what the default yields by calling platforms directly and choosing different options."
So by default, you can't tune hyperparameters in Model Screening platform (perhaps by JSL), and it's not the use of this platform. Model Screening is AutoML, where the aim is to fit quickly a high number of very different types of Machine Learning models, to better understand which type(s) of models does seem to correctly fit the data. Once this exploration phase is done, you can use the corresponding model's platforms to tune the hyperparameters with tuning design tables and possibly improve further your model's performances.
Note that Machine Learning algorithms have various sensitivity/robustness regarding hyperparameters configurations : for example, Random Forests are one of the most robust ML algorithm, where hyperparameters have little influence on its performances. See [1802.09596] Tunability: Importance of Hyperparameters of Machine Learning Algorithms (arxiv.org)
You may technically be able to do what you intend to do, but several warnings to take care :
- You may have to use nested cross-validation (if already using cross-validation) or cross-validation on your training set (and using the validation set to compare the models' performances) if you want to fit several models and tune them. The added data splitting is here to make sure that you're not overfitting with the hyperparameters optimization, and that a part of your data can still be used to do algorithms comparison and selection in a fair and "as unbiased as possible" way.
- A possible problem with this Model Screening platform is that the crossvalidation option is by default random. Depending on your dataset and the distributions of your features/inputs, this may not be a sensible choice and would not provide a fair assessment and representativity of your dataset. A workaround could be to create a stratified formula (K-folds) validation column and use it in the validation panel of the model screening : Launch the Make Validation Column Platform (jmp.com)
- If you really want to try and tune several models with this platform or any AutoML platform, think about the number of models that need to be fitted and the time and computations needed : you'll need to fit each selected type of model KxK' times (nested cross-validation with K = number of outer folds for model validation, K' = number of inner folds for hyperparameters tuning). Depending on your dataset, its dimensionality and complexity, this "brute-force" approach may not be reasonable and achievable.

More ressources about nested cross-validation :
https://inria.github.io/scikit-learn-mooc/python_scripts/cross_validation_nested.html
https://scikit-learn.org/stable/auto_examples/model_selection/plot_nested_cross_validation_iris.html
https://medium.com/@cd_24/a-guide-to-nested-cross-validation-with-code-step-by-step-6a8ad06d5af2#:~:text=Nested%20cross%2Dvalidation%20is%20a,inner%20loop%20for%20hyperparameter%20tuning.
My advice would be to proceed sequentially and use the platform for what it is best at, comparing very diverse algorithms and select the most promising ones. Then, you can optimize the hyperparameters on the (few) models that seem to be best performing in order to improve a little bit the performances. Be careful in this process to avoid data leakage, so never use your test set until a final model is chosen and optimized for example (or you can expect optimistic results on your test set and bad surprises when the algorithm will be used on new data).
This process makes more sense to me than using a brute-force approach, as the hyperparameters optimization won't "magically" make an algorithm learn much better than a more suitable algorithm/method.
I hope this answer (even if not directly what you would expect) will help you,
Re: How to modify hyperparameters in Model Screening platformHi Victor_G,
Thank you for your reply that is very inspiring to me. I can also try this approach, first with the Model Screening platform and then the appropriate algorithm.
In order to avoid the overfitting, K-fold crossvalidation is a good way for small data. However, some algorithm platforms (not Model Screening) do not support K-fold cross-validation, such as Bootstrap Forest, Boosted Tree, and Baive Bayes. Of course, stratified formula (K-folds) validation column doesn't fit in. Thus, after selecting the most promising algorithm in Model Screening platform and hyperparameters optimization, can you share some experience about how to train a model better when it comes to small data?
Lastly, after clicking the button "Run Selected", I found that every algorithm in Model Screening platform with K-fold crossvalidation can automatically generate a Validation Fold. So that, can I use this Validation Fold in the same algorithm with the best hyperparameter to avoid the overfitting?
Looking forward to hearing from you.
Re: How to modify hyperparameters in Model Screening platformHi @Wang123,
Glad to hear that my response was helpful.
To successfully use Machine Learning, you need to set up a strategy and framework for your Machine Learning project before starting any analysis. Most of the time, Machine Learning projects may fail because the starting point (data collection considerations) or the end phase (testing conditions and monitoring) are not well considered and defined:
- Starting point: Think about how you collected your data : How representative is your dataset for the task you want to do ? In which context the data has been collected: in observational studies, or in controlled experimentations like DoE ? Is the data sampling and features/variables distributions similar to what will happen in the model's environment (for example variables ranges/levels, imbalance or balance between classes or values, response(s) distributions, similar measurement equipment performances, uncertainty in the measurements, ...) ?
These questions are just some examples of what you need to consider and define when using data for Machine Learning and can help manage your expectations.
- End phase: You need to know how you will test your final model. Can you already split your dataset and keep a small part for testing purposes, or are you planning to acquire new data to test and monitor your model's performances ?
Here are some other recommendations and guidance related to your questions, as well as additional comments :
- To avoid any misunderstanding, it's important to know what are the use and needs between each sets :
- Training set : Used for the actual training of the model(s),
- Validation set : Used for model optimization (hyperparameter fine-tuning, features/threshold selection, ... for example) and model selection,
- Test set : Used for generalization and predictive performance assessment of the selected model on new/unseen data. At this stage you should not have several models in competition.
- In the case of small dataset, there are several option to realize models' validation (models comparison and selection):
- If you're dealing with small datasets, choose simple algorithms. Generally, the higher the number of (hyper)parameters in the model, the bigger your training dataset need to be, as you'll need more data to estimate precisely each of the (hyper)parameters in the model. I would rather choose robust algorithms when dealing with small datasets, such as Random Forests, Support Vector Machines, and Generalized Regression/Classification.
Some LinkedIn articles I created about it for more explanations :
- Random Forests
- SVM
Both of these algorithms have either few hyperparameters to tune, performances robust to hyperparameters tuning (see: https://arxiv.org/abs/1802.09596 mentioned above) or have training specificities that help them avoid overfitting and reduce prediction variance (the bootstrap samples part in Random Forest for example).
I would not use boosted tree or boosted algorithms, as their focus is on reducing bias (systematic error) as much as possible by sequentially correcting previous errors. This make them very effective prediction algorithms, but they are highly sensitive and influenced by the training set, with possible poor generalization performances and high variance.
More generally, there are two ways to deal with ML algorithms :
- Either your dataset size, constraints and many other selection criteria reduce the number of models and possibilities, and you just try few models to select the most promising one. Here is a recording of a presentation I gave this year, with a Space-Filling mixture DoE and the use of Machine Learning : Synergy Between Design of Experiments and Machine Learning for Enhanced Domain E... - JMP User Community If you watch the model choice, you may have some ideas about selection criteria for your own project.
- You have no idea about which model may perform better, and you would like to have a first exploratory modelling test/competition between algorithms. In this case, you can try to use a subset of your data (60-80%) to train the models and compare them or if your dataset is very small, use it entirely with cross-validation to do this first exploratory part. Once you identify promising algorithms, try to use individual models platforms with a clear validation strategy (Stratified K-folds crossvalidation with fixed seed for reproducibility for example).
As a final remark on cross-validation and the way the results are displayed, there may be several warnings :
- The results will be displayed for each folds. Don't run a model trained and validated on specific fold, that would be considered "cheating", as you're selecting the best data splitting to improve model performance, which is biasing the overall performance you expect to have on new data/test set.
- K-folds crossvalidation has a misleading name, as it's not properly a validation method, but more a "robustness test" to see how a model behave with different data partitionings. See : MFML 065 - Understanding k-fold cross-validation (youtube.com)
So the important information in this step is not the individual performances of the model on each folds, but how regular and similar are the performances (average performance and standard deviation performance on all folds). If you see discrepancy/high variance in the result, that may indicate the model may not be suitable for your task and/or that your data has singular individual points (to be checked) confusing the model and preventing it to generalize/find patterns.
- Finally, once cross-validation done, there is no consensus on what to do with the results. Some retrain the selected model on the whole dataset, some are ensembling the individual models trained on each folds, or stacking the predictions ... Here is a link about this deployment phase How to get from evaluation to final model (substack.com)
Choose the option that makes more sense to you.
You may find also complementary discussions and answers on this post :CROSS VALIDATION - VALIDATION COLUMN METHOD
Sorry for the length, I hope there will be something for you in this big answer ! 
Betreff: So ändern Sie Hyperparameter in der Model Screening-PlattformHallo Victor_G,
Danke für Ihre Hilfe. Entweder eine Model Screening-Plattform mit Hyperparameter-Tuning-Funktion oder alle einzelnen Modellplattformen mit K-Fold-Funktion können mein Problem problemlos lösen. Schade, dass den beiden Plattformen einige Funktionen fehlen.
Nach einiger Überlegung möchte ich außerdem fragen, ob folgende Schritte sinnvoll sind:
(1) Geschichtete Stichprobennahme mit 80% Trainingsdaten und 20% Testdaten.
(2) Im Trainingsset (80%) habe ich mehrere Machine-Learning-Algorithmen mit K-facher Kreuzvalidierung trainiertin der Model Screening-Plattform. Natürlich verwendet dieser Schritt die Standard-Hyperparameter. Nach dem Vergleich stellte ich fest, dass ein Teil des Algorithmus optimal war, wie z. B. Bootstrap Forest.
(3) Anschließend habe ich die optimalen Hyperparameter des Bootstrap Forest mithilfe der Tuning Design Table ermittelt.
(4) Im Trainingsset (80%) habe ich den Bootstrap Forest Algorithmus mit optimalen Hyperparametern neu angepasst. Natürlich kann ich auch andere Algorithmen anpassen.
(5) Im Test-Set (20%) habe ich außerdem die Modellleistung von Bootstrap Forest und anderen Algorithmen bewertet.
Sind die obigen Schritte in JMP angemessen?
Kann ich in Schritt 2 einfach die Ergebnisse der Modellvergleiche (Ergebnisse der K-fachen Kreuzvalidierung) mit Standard-Hyperparametern im Artikel berichten? Natürlich wissen wir, dass viele Artikel mit Schritt 3 und dann mit Schritt 2 beginnen, alsoBerichten Sie über die Ergebnisse von Modellvergleichen mit optimalen Hyperparametern.
In Schritt 4 habe ich keine Methode zur Kreuzvalidierung eingerichtet. Ist das richtig? Oder gibt es eine andere Möglichkeit?
Ich freue mich darauf, von Ihnen zu hören.
Betreff: So ändern Sie Hyperparameter in der Model Screening-PlattformHallo Victor_G,
Ihre Antwort ist so bedeutsam. Ich weiß, wie man eine K-Folds-Validierungsspalte erstellt. Soweit ich weiß, unterstützen einige Algorithmusplattformen keine K-Fold-Kreuzvalidierung, wie z. B. Bootstrap Forest, Boosted Tree und Baive Bayes. Dies ist in der JMP-Hilfe unter https://www.jmp.com/support/help/en/18.0/index.shtml#page/jmp/kfold-and-holdback-validation.shtml verfügbar. In diesem Fall muss ich unsere kleinen Daten in einen Trainings-, Validierungs- und Testsatz aufteilen. Gibt es eine Möglichkeit, die K-Folds-Kreuzvalidierung in diesen Algorithmusplattformen (Bootstrap Forest, Boosted Tree und Baive Bayes) zu verwenden?
Sie sagten: „Die Ergebnisse werden für jede Falte angezeigt. Führen Sie kein Modell aus, das auf einer bestimmten Falte trainiert und validiert wurde, das käme als Betrug in Frage …“, und ein anderer sagte: „Nach Abschluss der Kreuzvalidierung gibt es schließlich keinen Konsens darüber, was mit den Ergebnissen geschehen soll. Einige trainieren das ausgewählte Modell erneut auf dem gesamten Datensatz, andere stellen die auf jeder Falte trainierten Einzelmodelle zusammen.“ Ich weiß nicht, welche Methode geeigneter ist: Training auf einer bestimmten Falte oder auf dem gesamten Trainingssatz?
Ich freue mich darauf, von Ihnen zu hören.
Betreff: So ändern Sie Hyperparameter in der Model Screening-PlattformHallo @Wang123 ,
Tut mir leid, Sie haben Recht, was die eingeschränkte Verwendung der K-Falten-Kreuzvalidierungsspalte in einigen Modellierungsplattformen betrifft.
Eine mögliche Problemumgehung besteht darin, eine gemeinsame Validierungsspaltenformel zu erstellen (geschichtete Stichproben mit 80 % Training und 20 % Validierung), diese in der Modellplattform zu verwenden und die Funktion „Simulieren“ zu verwenden, um viele Kreuzvalidierungsproben und -ergebnisse zur Bewertung der Robustheit zu generieren. Ich habe die Methodik in einem anderen Beitrag beschrieben: Gelöst: Betreff: Wie kann ich viele wiederholte Validierungen automatisieren und in einer Ausgaberegisterkarte zusammenfassen... – JMP-Benutzergemeinschaft
Zu Ihrer zweiten Frage wäre meine persönliche Meinung, Vorhersagen aus einzelnen Modellen zu stapeln, sodass jedes einzelne Modell den gleichen Beitrag zur endgültigen Vorhersage leistet. Dies scheint der neutralste Ansatz zu sein und würde eine Reduzierung der Verzerrung und (meistens) der Varianz ermöglichen (Ansatz „ Weisheit der Masse “) sowie eine Vermeidung von Überanpassung. Es könnte auch eine gute Gelegenheit sein, Unsicherheitsvorhersageintervalle dank der Beiträge einzelner Modelle abzuschätzen.
Für kleine Datensätze wäre das Ensembling zu komplex, da die Kombination der einzelnen Modelle eine zusätzliche Validierung erfordern würde, um sicherzustellen, dass Ihr endgültiges Ensemblemodell nicht überangepasst ist und generalisierbar ist.
Abhängig von Ihren umfassenden Kenntnissen über ML-Algorithmen könnte auch die Option genutzt werden, den gesamten Datensatz zu verwenden und das endgültige Modell darauf zu trainieren. Außerdem könnten die Ergebnisse des kreuzvalidierten Modells mit dem „nicht validierten“ Modell verglichen werden, um etwaige Anzeichen einer Überanpassung zu erkennen.
Auch hier trägt die Verwendung einfacher Modelle und Regularisierungs-/Einschränkungstechniken erheblich dazu bei, ein Überanpassen zu verhindern.
Hoffe, diese Antwort wird Ihnen helfen,
Betreff: So ändern Sie Hyperparameter in der Model Screening-PlattformHallo @Wang123 ,
Die Schritte 1) und 2) halte ich für angemessen.
Die Schritte 3) und 4) können kombiniert werden, um optimale Hyperparameter mehrerer Modelle zu finden, sie zu bewerten, zu vergleichen und ein endgültiges Modell auszuwählen. Für diesen Schritt benötigen Sie auch eine Validierungsstrategie, da die Optimierung von Hyperparametern ohne Validierung zu Überanpassung führen würde. Abhängig von den Ergebnissen dieser Hyperparameteroptimierung auf den (K-fachen?) Validierungssätzen wählen Sie einen Algorithmus aus, der am geeignetsten erscheint.
Abhängig von Ihrer Validierungsstrategie belassen Sie den trainierten Algorithmus entweder so wie er ist (wenn Sie einen Validierungssatz zum Vergleichen und Auswählen eines Modells verwendet haben) oder Sie können eine Modellstapelung durchführen, wenn Sie eine K-fach-Kreuzvalidierung verwendet haben (um die durchschnittliche Vorhersage aus den einzelnen Modellen zu erhalten).
In Schritt 5 bewerten Sie die Leistung Ihres endgültigen Modells anhand neuer und unbekannter Daten. In dieser Phase sollte es nur einen Algorithmus/ein Modell geben. Die Validierung dient zum Vergleichen und Auswählen eines Modells, nicht zur Testphase.
Zu Ihren Fragen:
„Kann ich in Schritt 2 nur die Ergebnisse der Modellvergleiche (Ergebnisse der K-fachen Kreuzvalidierung) mit Standard-Hyperparametern im Artikel angeben?“: Es hängt davon ab, was Sie zeigen/demonstrieren möchten. Wenn Sie erklären möchten, warum Sie bestimmte Modelle ausgewählt haben, können Sie die Ergebnisse aus Schritt 2 verwenden. Es ist sinnvoller, die Ergebnisse aus Schritt 2 und 3 für die ausgewählten Algorithmen zu vergleichen, wenn Sie die Bedeutung und den Nutzen der Hyperparameter-Optimierung hervorheben möchten (was für einige robuste Modelle wie Random Forests nicht immer wichtig ist).
„In Schritt 4 habe ich keine Methode zur Kreuzvalidierung eingerichtet. Ist das richtig? Oder gibt es eine andere Möglichkeit?“ Ich würde nicht empfehlen, das gesamte Trainingsset neu anzupassen, es sei denn, Sie verwenden robuste Algorithmen und verfügen über Metriken, um sicherzustellen, dass Sie nicht überanpassen. Random Forests sind in der Regel gute Beispiele für robuste Algorithmen und verfügen über eine interne Validierung (für kontinuierliche Reaktion) durch Out-Of-Bag-Beispiele: https://www.jmp.com/support/help/en/17.2/#page/jmp/overview-of-the-bootstrap-forest-platform.shtml#
Durch Vergleichen der Metriken der In-Bag- und Out-Of-Bag-Beispiele können Sie beurteilen, ob es bei Ihrem Random Forest zu einer Überanpassung kommen kann.
Wenn Sie einen anderen Algorithmus verwenden und/oder sich über dessen Robustheit nicht sicher sind, behalten Sie einfach Ihr optimiertes (und validiertes!) Modell aus dem vorherigen Schritt (oder die gestapelten Modelle, wenn Sie die K-Falten-Kreuzvalidierung verwendet haben).
Hoffe, diese letzte Antwort wird Ihnen helfen,
PS: Vergessen Sie nicht, die Antwort(en) als „Lösung akzeptieren“ zu markieren, wenn sie für Sie hilfreich waren. So können andere JMP-Benutzer schnell zur Lösung gelangen, ohne alles lesen zu müssen.
Betreff: So ändern Sie Hyperparameter in der Model Screening-PlattformHallo Victor_G,
Vielen Dank für Ihre wertvolle Sichtweise! Diese sind für mich sehr hilfreich.