% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/SettingsObjects.R
\name{createCmAnalysesSpecifications}
\alias{createCmAnalysesSpecifications}
\title{Create full CM analysis specifications}
\usage{
createCmAnalysesSpecifications(
  cmAnalysisList,
  targetComparatorOutcomesList,
  analysesToExclude = NULL,
  refitPsForEveryOutcome = FALSE,
  refitPsForEveryStudyPopulation = TRUE,
  cmDiagnosticThresholds = createCmDiagnosticThresholds()
)
}
\arguments{
\item{cmAnalysisList}{A list of objects of type \code{cmAnalysis} as created using
the `\link{createCmAnalysis} function.}

\item{targetComparatorOutcomesList}{A list of objects of type \code{targetComparatorOutcomes} as
created using the \link{createTargetComparatorOutcomes}
function.}

\item{analysesToExclude}{Analyses to exclude. See the Analyses to Exclude section for details.}

\item{refitPsForEveryOutcome}{Should the propensity model be fitted for every outcome (i.e.
after people who already had the outcome are removed)? If
false, a single propensity model will be fitted, and people
who had the outcome previously will be removed afterwards.}

\item{refitPsForEveryStudyPopulation}{Should the propensity model be fitted for every study population
definition? If false, a single propensity model will be fitted,
and the study population criteria will be applied afterwards.}

\item{cmDiagnosticThresholds}{An object of type \code{CmDiagnosticThresholds} as created using
\code{\link[=createCmDiagnosticThresholds]{createCmDiagnosticThresholds()}}.}
}
\value{
An object of type \code{CmAnalysesSpecifications}.
}
\description{
Create full CM analysis specifications
}
\details{
\subsection{Analyses to Exclude}{

Normally, \code{runCmAnalyses} will run all combinations of target-comparator-outcome-analyses settings.
However, sometimes we may not need all those combinations. Using the \code{analysesToExclude} argument,
we can remove certain items from the full matrix. This argument should be a data frame with at least
one of the following columns:
\itemize{
\item targetId
\item comparatorId
\item nestingCohortId
\item outcomeId
\item analysisId
}

This data frame will be joined to the outcome model reference table before executing, and matching rows
will be removed. For example, if one specifies only one target ID and analysis ID, then any analyses with
that target and that analysis ID will be skipped.
}
}
