% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/psych_scores.R
\name{k10_score}
\alias{k10_score}
\title{K10 scoring}
\usage{
k10_score(
  data,
  col_map = list(),
  na_action = c("keep", "omit", "error"),
  missing_prop_max = 0.2,
  impute = c("none", "mean"),
  prefix = "K10",
  verbose = TRUE
)
}
\arguments{
\item{data}{Data frame containing questionnaire item columns.}

\item{col_map}{Named list mapping canonical item IDs to column names; defaults assume items are already named.}

\item{na_action}{How to handle rows with missing items: \code{keep}, \code{omit}, or \code{error}.}

\item{missing_prop_max}{Maximum allowed proportion of missing items per row before the score is set to \code{NA}.}

\item{impute}{Imputation strategy for missing items when under the threshold: \code{none} or \code{mean} (row-wise mean).}

\item{prefix}{Prefix for output column names.}

\item{verbose}{Logical; if \code{TRUE}, emits informational messages about column resolution and scoring progress via \code{hm_inform()}.}
}
\value{
A tibble of score columns only: \code{K10_total}. Input columns are not included.
}
\description{
K10 scoring
}
\note{
K10 items are summed as provided. The original scale uses 1--5 coding
(total 10--50); some implementations subtract 1 (0--4, total 0--40).
The function accepts either coding, as no reverse-scored items are
involved and \code{min_val}/\code{max_val} only affect reversal.
}
\examples{
df <- data.frame(k10_01 = 0, k10_02 = 1, k10_03 = 2, k10_04 = 1, k10_05 = 0,
                 k10_06 = 1, k10_07 = 2, k10_08 = 1, k10_09 = 0, k10_10 = 1)
k10_score(df)
}
\references{
\insertRef{kessler2002k6k10}{HealthMarkers}
}
