View source: R/mhqol_utilities_to_scores.R
mhqol_utilities_to_scores | R Documentation |
This function provides the scores of the MHQoL based on the utilities provided (as described in the valueset).
mhqol_utilities_to_scores(
utilities,
country = "Netherlands",
ignore_invalid = FALSE,
ignore_NA = TRUE,
retain_old_variables = TRUE)
utilities |
A dataframe, numeric vector, or list containing the utilities of the MHQoL. |
country |
The country for which the utilities should be calculated. For now the only option is "Netherlands". |
ignore_invalid |
If TRUE, the function will ignore missing utilities and continue processing. |
ignore_NA |
If TRUE, the function will ignore NA values in the input data. |
retain_old_variables |
If TRUE, the function will retain the old variables in the output. |
A dataframe containing the scores of the MHQoL based on the utilities provided.
# Example usage of the mhqol_utilities_to_scores function
# Get the scores based on a numeric vector, not all utilities are present
mhqol_utilities_to_scores(
utilities = c(IN = -0.018, DA = -0.021, PH = -0.064, FU = -0.106),
ignore_invalid = TRUE
)
# Get the scores based on a dataframe
mhqol_utilities_to_scores(
utilities = data.frame(
SI = -0.137,
IN = -0.184,
MO = -0.063,
RE = -0.172,
DA = -0.021,
PH = -0.243,
FU = -0.170
)
)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.