map_causes: Maps cause predictions to broader causes

View source: R/utils.R

map_causesR Documentation

Maps cause predictions to broader causes

Description

Maps cause predictions to broader causes

Usage

map_causes(causes, cause_map)

Arguments

causes

Either a character vector with the single predicted cause per individual, or a matrix with each row giving cause predictions for an individual. The columns of this matrix must have the original cause names

cause_map

A data frame, with a column cause giving the original cause, and a column broad_cause giving the broader cause corresponding to the original cause

Value

A matrix giving individual probabilities for the broad causes


jfiksel/CalibratedVA documentation built on Nov. 14, 2022, 2:59 p.m.