datetime_to_cols: DateTime to columns

Description Usage Arguments Details Value

Description

Extract various info from a DateTime value such as day of the week, time of day, day of the year, whether the time and day is during working hours, if it is a holiday or national vacation day, etc.

Usage

1
2
datetime_to_cols(datetime, country = "denmark", suffixes = NULL,
  return = "data.table", verbose = FALSE)

Arguments

datetime

A datetime object.

country

What country to get country specific values (holidays, vacations and time of day) from. See details for a list of countries.

suffixes

A character specifying the suffixes to be used for all columns.This is particularly handy if you want to keep track of multiple datetime inputs. NULL == no suffixes.

return

character; What class to return the output data in - either 'data.table', 'data.frame' or 'tibble'.

verbose

Show what is going on...

Details

The following countries are supported:

Value

A Data Frame including the following columns (class in parenthesis):


emillykkejensen/DateTimeWrangler documentation built on May 14, 2019, 9:37 a.m.