knitr::opts_chunk$set(
  collapse = TRUE,
  comment = "#>",
  fig.path = "man/figures/README-",
  out.width = "100%"
)

tsextras

Lifecycle: experimental

The goal of tsextras is to provide helper functions to analyse time series objects.

Installation

You can install the development version from GitHub with:

# install.packages("devtools")
devtools::install_github("alberto-mateos-mo/tsextras")

Example

ts_plot() function is a wrapper for other functions that plot ts objects.

library(tsextras)
library(ggplot2)

ts_plot(AirPassengers)

ts_trend() extracts and plots the trend of a time series.

library(tsextras)
library(ggplot2)

ts_trend(AirPassengers, order = 12)

ts_season() extracts and plots seasonal component of a time series.

library(tsextras)
library(ggplot2)

s <- AirPassengers
x <- ts_trend(s)
ts_season(x)


alberto-mateos-mo/tsextras documentation built on Feb. 3, 2020, 12:03 a.m.