age_in_days: Compute Age in Days

View source: R/input.R

age_in_daysR Documentation

Compute Age in Days

Description

By default the age in days is computed. If age on different date should be computed use pdate_today with a different values. In case you want to get a real number as the age, then use pb_floor = FALSE.

The function is based on https://stackoverflow.com/questions/14454476/get-the-difference-between-dates-in-terms-of-weeks-months-quarters-and-years

Usage

age_in_days(pdate_birth, pdate_today = lubridate::today(), pb_floor = TRUE)

Arguments

pdate_birth

date of birth

pdate_today

todays date

pb_floor

should age in days be rounded down

Value

age in days


sknqualitasag/qp4ewc documentation built on Sept. 27, 2022, 3:31 p.m.