# Write model code for a model with an exponential dose-response function,
# with random treatment effects
model <- mbnma.write(fun=dexp(),
method="random",
likelihood="binomial",
link="logit"
)
names(model) <- NULL
print(model)
# Write model code for a model with an Emax dose-response function,
# relative effects modelled on Emax with a random effects model,
# a single parameter estimated for ED50 with a common effects model
model <- mbnma.write(fun=demax(emax="rel", ed50="common"),
likelihood="normal",
link="identity"
)
names(model) <- NULL
print(model)
# Write model code for a model with an Emax dose-response function,
# relative effects modelled on Emax and ED50.
# Class effects modelled on ED50 with common effects
model <- mbnma.write(fun=demax(),
likelihood="normal",
link="identity",
class.effect=list("ed50"="common")
)
names(model) <- NULL
print(model)
# Write model code for a model with an Emax dose-response function,
# relative effects modelled on Emax and ED50 with a
# random effects model that automatically models a correlation between
# both parameters.
model <- mbnma.write(fun=demax(),
method="random",
likelihood="normal",
link="identity",
)
names(model) <- NULL
print(model)
Run the code above in your browser using DataLab