% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/CaseSeries.R
\name{createCaseSeriesSettings}
\alias{createCaseSeriesSettings}
\title{Create aggregate covariate study settings}
\usage{
createCaseSeriesSettings(
  targetIds,
  outcomeIds,
  limitToFirstInNDays = 99999,
  minPriorObservation = 0,
  outcomeWashoutDays = 0,
  riskWindowStart = 1,
  startAnchor = "cohort start",
  riskWindowEnd = 365,
  endAnchor = "cohort start",
  caseCovariateSettings = createDuringCovariateSettings(useConditionGroupEraDuring =
    TRUE, useDrugGroupEraDuring = TRUE, useProcedureOccurrenceDuring = TRUE,
    useDeviceExposureDuring = TRUE, useMeasurementDuring = TRUE, useObservationDuring =
    TRUE, useVisitConceptCountDuring = TRUE),
  casePreTargetDuration = 365,
  casePostOutcomeDuration = 365
)
}
\arguments{
\item{targetIds}{A list of cohortIds for the target cohorts}

\item{outcomeIds}{A list of cohortIds for the outcome cohorts}

\item{limitToFirstInNDays}{whether to limit each target cohort to the first entry into the cohort per N days per subject}

\item{minPriorObservation}{The minimum time (in days) in the database a patient in the target cohorts must be observed prior to index}

\item{outcomeWashoutDays}{Patients with the outcome within outcomeWashout days prior to index are excluded from the risk factor analysis}

\item{riskWindowStart}{The start of the risk window (in days) relative to the `startAnchor`.}

\item{startAnchor}{The anchor point for the start of the risk window. Can be `"cohort start"`
or `"cohort end"`.}

\item{riskWindowEnd}{The end of the risk window (in days) relative to the `endAnchor`.}

\item{endAnchor}{The anchor point for the end of the risk window. Can be `"cohort start"`
or `"cohort end"`.}

\item{caseCovariateSettings}{An object created using \code{createDuringCovariateSettings}}

\item{casePreTargetDuration}{The number of days prior to case index we use for FeatureExtraction}

\item{casePostOutcomeDuration}{The number of days prior to case index we use for FeatureExtraction}
}
\value{
A list with the settings
}
\description{
Create aggregate covariate study settings
}
\examples{

caseSeriesSetting <- createCaseSeriesSettings(
  targetIds = c(1,2),
  outcomeIds = c(3),
  limitToFirstInNDays = 365,
  minPriorObservation = 365,
  outcomeWashoutDays = 90,
  riskWindowStart = 1,
  startAnchor = "cohort start",
  riskWindowEnd = 365,
  endAnchor = "cohort start",
  casePreTargetDuration = 365,
  casePostOutcomeDuration = 365
)

}
\seealso{
Other Aggregate: 
\code{\link{createRiskFactorSettings}()},
\code{\link{createTargetBaselineSettings}()}
}
\concept{Aggregate}
