Skip to contents

Computes the summary score mh_p_famhx__alc__moth__fath_indicator (Family History [Parent] (Alcohol) Endorsed: Either parent)

  • Notes:

    • Following values are recoded as NA prior to any computation

      • 777

      • 888

      • 999

    • Following logic is applied to compute the score:

      • father endorsed yes OR mother endorsed yes = 1

      • father endorsed no AND mother endorsed no = 0

      • all other cases set to NA

Usage

vars_mh_p_famhx__alc__moth__fath_indicator

compute_mh_p_famhx__alc__moth__fath_indicator(
  data,
  name = "mh_p_famhx__alc__moth__fath_indicator",
  combine = TRUE
)

Format

a character vector of base name of the check boxes used to compute mh_p_famhx__alc__moth__fath_indicator.

Arguments

data

tibble. A data frame containing the data.

name

character. The name of the output column for the computed score.

combine

logical. Whether to combine the summary score column with the input data frame (Default: TRUE).

Value

tbl. The input data frame with the summary score appended as a new column.