calculate_sers: Function to calculate Self-evaluated Resiliency Score (SERS)

Description Usage Arguments Value Examples

View source: R/02-calculate_sers.R

Description

Function to calculate Self-evaluated Resiliency Score (SERS)

Usage

1
calculate_sers(df, keep.na = TRUE, response = 3, add = FALSE)

Arguments

df

Dataframe containing SERS-related variables

keep.na

Logical. Apply recoding to NA responses? If TRUE (default), NA responses will be recoded based on response. If FALSE, score will be NA.

response

What response to recode NA values. 1 for best possible response; 5 for worst possible response; 3 for neutral respnose. Default is 3. Ignored when keep.na FALSE.

add

Logical. Should the calculated SERS values be added to df? If TRUE, SERS scores will be concatenated to df using cbind. Default is FALSE.

Value

If add is TRUE, a data.frame made out of a column binding of df and the calculated per dimension and overall SERS. If add is FALSE, a SERS data.frame containing per dimension and overall SERS.

Examples

1

validmeasures/wfpKenya documentation built on Feb. 12, 2020, 7:14 p.m.