% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/cvd_risk.R
\name{cvd_risk_stroke}
\alias{cvd_risk_stroke}
\title{Stroke 10-year risk}
\usage{
cvd_risk_stroke(data, col_map = NULL, na_warn_prop = 0.2, verbose = TRUE, ...)
}
\arguments{
\item{data}{A data frame with the required cardiovascular risk columns.}

\item{col_map}{Optional named list mapping internal keys (\code{age}, \code{sex},
\code{race}, \code{smoker}, \code{total_chol}, \code{HDL_c}, \code{sbp},
\code{bp_treated}, \code{diabetes}, \code{bmi}) to actual column names in
\code{data}. If \code{NULL} (default), column names are auto-inferred then fall
back to the key names themselves. \code{sex} accepts \code{1}/\code{0},
\code{"m"}/\code{"f"}, or \code{"male"}/\code{"female"} (case-insensitive).}

\item{na_warn_prop}{Proportion (0-1) to flag high missingness warnings (default 0.2).
Only used when \code{verbose = TRUE}.}

\item{verbose}{Logical; if TRUE, prints progress and a short summary.}

\item{...}{Passed to \code{PooledCohort::predict_10yr_stroke_risk()}.}
}
\value{
A tibble with \code{model}, \code{year}, \code{risk}.
}
\description{
Wrapper around \code{PooledCohort::predict_10yr_stroke_risk()} with quiet
fallback to NA if the backend errors.
}
\examples{
if (requireNamespace("PooledCohort", quietly = TRUE)) {
  df <- data.frame(age = 55, sex = 1, race = "white", smoker = FALSE,
    total_chol = 200, HDL_c = 50, sbp = 140, bp_treated = FALSE,
    diabetes = FALSE, bmi = 27)
  cvd_risk_stroke(df)
}
}
\references{
\insertRef{goff2014accaha}{HealthMarkers}
}
