discount_hack: Hack to Work Around a Discounting Issue

View source: R/utils.R

discount_hackR Documentation

Hack to Work Around a Discounting Issue

Description

This function is a hack to avoid a problem with discounting when the argument is a constant.

Usage

discount_hack(.dots, method = "start")

Arguments

.dots

A state object.

Details

The hack consists in replacing calls to discount(x) by discount(x * rep(1, n())) to ensure x is recycled to the correct length.

Value

A modified state object.


PolicyAnalysisInc/heRoMod documentation built on March 23, 2024, 4:29 p.m.