year2age: Year to Age

Description Usage Arguments Details Value Examples

View source: R/util_helper.R

Description

This function converts years to ages. Assumes that age is in the column "age".

Usage

1
year2age(df, base_year)

Arguments

df

Data frame with age in "age".

base_year

Year the experiment took place

Details

Note: Assumes that humans do not grow older than 150.

Value

Data frame with years converted to age

Examples

1
df <- year2age(df,2016)

cog-ethz/evertools documentation built on April 1, 2020, 10:30 p.m.