date_format {injurytools}R Documentation

Proper Conversion of Date objects

Description

Converts Date objects into a common format used for every Date object throughout the package.

Usage

date_format(date)

Arguments

date

a Date object.

Details

To limit the scope of the changes to LC_TIME and the timezone, a temporary locale modification is made using the withr package.

Value

A "%Y-%m-%d" formatted Date object with respect to a fixed locale and time zone, i.e. setting the LC_TIME component to C and timezone to UTC (the safest choice, non-geographic and Coordinated Universal Time).


[Package injurytools version 1.0.3 Index]