Skip to content

Commit

Permalink
move model instantiation inside loop
Browse files Browse the repository at this point in the history
  • Loading branch information
jgallowa07 committed Jan 10, 2024
1 parent 8b7ad8e commit a1d0784
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion notebooks/func_effect_shifts.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -148,11 +148,11 @@
"n_lasso = len(params[\"lasso_shifts\"])\n",
"fig, ax = plt.subplots(n_lasso, 2, figsize=[6, n_lasso * 3])\n",
"\n",
"model = multidms.Model(data)\n",
"mutations_df = []\n",
"for i, lasso_shift in enumerate(lasso_shifts):\n",
" lasso_shift = float(lasso_shift)\n",
" print(f\"Fitting model for {lasso_shift=}\")\n",
" model = multidms.Model(data)\n",
" model.fit(lasso_shift=lasso_shift)\n",
" mutations_df.append(\n",
" model.get_mutations_df(phenotype_as_effect=True).assign(lasso_shift=lasso_shift)\n",
Expand Down

0 comments on commit a1d0784

Please sign in to comment.