split_data {midasr}R Documentation

Split mixed frequency data into in-sample and out-of-sample

Description

Splits mixed frequency data into in-sample and out-of-sample datasets given the indexes of the low frequency data

Usage

split_data(data, insample, outsample)

Arguments

data

a list containing mixed frequency data

insample

the low frequency indexes for in-sample data

outsample

the low frequency indexes for out-of-sample data

Details

It is assumed that data is a list containing mixed frequency data. Then given the indexes of the low frequency data the function splits the data into two subsets.

Value

a list with elements indata and outdata containing respectively in-sample and out-of-sample data sets

Author(s)

Virmantas Kvedaras, Vaidotas Zemlys

Examples


#Monthly data
x <- 1:24
#Quartely data
z <- 1:8
#Yearly data
y <- 1:2
split_data(list(y=y,x=x,z=z),insample=1,outsample=2)

[Package midasr version 0.8 Index]