I encountered an error while following the "Mediation Analysis for survival data" tutorial, specifically in the Multinomial regression section. Here are the steps and the error details:
data(tTRACE)
dcut(tTRACE) <- ~.
weightmodel <- fit <- mlogit(wmicat.4 ~ agecat.4 + vf + chf, data = tTRACE, family = binomial)
Error in cluster.default(id) : only implemented for resamples objects
To further diagnose the issue, I tried running the example code from the mlogit help documentation, but encountered the same error:
data(bmt)
dfactor(bmt) <- cause1f ~ cause
drelevel(bmt, ref = 3) <- cause3f ~ cause
dlevels(bmt)
mreg <- mlogit(cause1f ~ tcell + platelet, bmt)
Error in cluster.default(id) : only implemented for resamples objects
Could you please help me understand where the issue might be?
Hi,
I encountered an error while following the "Mediation Analysis for survival data" tutorial, specifically in the Multinomial regression section. Here are the steps and the error details: data(tTRACE) dcut(tTRACE) <- ~. weightmodel <- fit <- mlogit(wmicat.4 ~ agecat.4 + vf + chf, data = tTRACE, family = binomial) Error in cluster.default(id) : only implemented for resamples objects To further diagnose the issue, I tried running the example code from the mlogit help documentation, but encountered the same error: data(bmt) dfactor(bmt) <- cause1f ~ cause drelevel(bmt, ref = 3) <- cause3f ~ cause dlevels(bmt) mreg <- mlogit(cause1f ~ tcell + platelet, bmt) Error in cluster.default(id) : only implemented for resamples objects Could you please help me understand where the issue might be?