Create an outcome model, and computes the relative risk
fitOutcomeModel( population, cohortMethodData = NULL, modelType = "logistic", stratified = FALSE, useCovariates = FALSE, inversePtWeighting = FALSE, interactionCovariateIds = c(), excludeCovariateIds = c(), includeCovariateIds = c(), profileGrid = NULL, profileBounds = c(log(0.1), log(10)), prior = createPrior("laplace", useCrossValidation = TRUE), control = createControl(cvType = "auto", seed = 1, resetCoefficients = TRUE, startingVariance = 0.01, tolerance = 2e-07, cvRepetitions = 10, noiseLevel = "quiet") )
A population object generated by
potentially filtered by other functions.
The type of outcome model that will be used. Possible values are "logistic", "poisson", or "cox".
Should the regression be conditioned on the strata defined in the population object (e.g. by matching or stratifying on propensity scores)?
Whether to use the covariates in the
object in the outcome model.
Use inverse probability of treatment weighting (IPTW)
An optional vector of covariate IDs to use to estimate interactions with the main treatment effect.
Exclude these covariates from the outcome model.
Include only these covariates in the outcome model.
A one-dimensional grid of points on the log(relative risk) scale where the likelihood for coefficient of variables is sampled. See details.
The bounds (on the log relative risk scale) for the adaptive sampling of the likelihood function. See details.
The prior used to fit the model. See
The control object used to control the cross-validation used to
determine the hyperparameters of the prior (if applicable). See
Cyclops::createControl() for details.
An object of class
OutcomeModel. Generic function
confint are available.
For likelihood profiling, either specify the
profileGrid for a completely user- defined grid, or
profileBounds for an adaptive grid. Both should be defined on the log effect size scale. When both
NULL likelihood profiling is disabled.