Mercurial > repos > goeckslab > pycaret_compare
diff base_model_trainer.py @ 3:02f7746e7772 draft default tip
planemo upload for repository https://github.com/goeckslab/Galaxy-Pycaret commit ff6d674ecc83db933153b797ef4dbde17f07b10e
author | goeckslab |
---|---|
date | Wed, 01 Jan 2025 03:19:40 +0000 |
parents | 915447b14520 |
children |
line wrap: on
line diff
--- a/base_model_trainer.py Sat Dec 14 23:18:02 2024 +0000 +++ b/base_model_trainer.py Wed Jan 01 03:19:40 2025 +0000 @@ -263,9 +263,13 @@ Best Model Plots</div> <div class="tab" onclick="openTab(event, 'feature')"> Feature Importance</div> - <div class="tab" onclick="openTab(event, 'explainer')"> - Explainer - </div> + """ + if self.plots_explainer_html: + html_content += """ + "<div class="tab" onclick="openTab(event, 'explainer')">" + Explainer Plots</div> + """ + html_content += f""" </div> <div id="summary" class="tab-content"> <h2>Setup Parameters</h2> @@ -299,13 +303,19 @@ <div id="feature" class="tab-content"> {feature_importance_html} </div> + """ + if self.plots_explainer_html: + html_content += f""" <div id="explainer" class="tab-content"> {self.plots_explainer_html} {tree_plots} </div> - {get_html_closing()} - """ - + {get_html_closing()} + """ + else: + html_content += f""" + {get_html_closing()} + """ with open(os.path.join( self.output_dir, "comparison_result.html"), "w") as file: file.write(html_content)