Learn R Programming

anomalize (version 0.3.0)

prep_tbl_time: Automatically create tibbletime objects from tibbles

Description

Automatically create tibbletime objects from tibbles

Usage

prep_tbl_time(data, message = FALSE)

Value

Returns a tibbletime object of class tbl_time.

Arguments

data

A tibble.

message

A boolean. If TRUE, returns a message indicating any conversion details important to know during the conversion to tbl_time class.

Details

Detects a date or datetime index column and automatically

Examples

Run this code

library(dplyr)
library(tibbletime)

data_tbl <- tibble(
    date  = seq.Date(from = as.Date("2018-01-01"), by = "day", length.out = 10),
    value = rnorm(10)
    )

prep_tbl_time(data_tbl)

Run the code above in your browser using DataLab