calc_simple_return: Compute simple net returns for a vector Used in scripts:

View source: R/calculations.R

calc_simple_returnR Documentation

Compute simple net returns for a vector Used in scripts:

Description

calc_simple_return helper function for compute_return. Takes every element of x except the first and divides by every element of x excep the last and subtracts one (1).

Usage

calc_simple_return(x)

Arguments

x

numeric vector

Value

Vector of same length as x


AndreSjuve/dretools documentation built on Dec. 4, 2024, 3:12 a.m.