meltMyTS: Use 'reshape2"s 'melt' on multivariate time series object

Description Usage Arguments Value Author(s) See Also Examples

View source: R/meltMyTS.R

Description

meltMyTS is primarily designed to prepare data to be used with ggMyTS (QMSS) to make plots of time series trends with ggplot.

Usage

1
meltMyTS(mv.ts.object, time.var, keep.vars)

Arguments

mv.ts.object

A multivariate time series object created with ts.

time.var

A character string naming the time variable.

keep.vars

An optional character vector with names of variables to keep. If keep.vars is not specified then all variables in mv.ts.object will be kept. However, if any variables are named then all other variables will be dropped, except time.var, which is always kept.

Value

A molten data frame.

Author(s)

Jonah Gabry <jsg2201@columbia.edu>. See melt in (reshape2) for the author of the original melt function.

See Also

ggMyTS, melt.data.frame

Examples

1
See examples in documentation for ggMyTS.

jgabry/QMSS_package documentation built on May 19, 2019, 7:18 a.m.