tlverse / sl3

💪 🤔 Modern Super Learning with Machine Learning Pipelines
https://tlverse.org/sl3/
GNU General Public License v3.0
100 stars 40 forks source link

Using sl3 fits in tmle3 #407

Open Ofran-a opened 1 year ago

Ofran-a commented 1 year ago

Hello Running tmle3 fit is not working for me: one of the problems I have is that I cannot specify the number of folds in the tmle_task. I have generated two sl3 fits for the Q ang g models. Is there a way to use these existing results into a tmle fit to estimate the ATT please. Many thanks

jeremyrcoyle commented 1 year ago

Hello,

Yes, you can pass fitted sl3 objects into the library instead of the unfitted one.

Please be aware that by default tmle3 implements cv-tmle and so the fold structure should be the same across likelihood factors (e.g outcome regression Q and propensity score g). You can achieve this by pregenerating the folds using origami and passing them to the relevant tasks

Ofran-a commented 1 year ago

Many thanks, is there an example of this on tlverse that you could point me to please.