Learn R Programming

PortfolioTesteR (version 0.1.4)

ml_add_interactions: Add interaction panels to a feature list

Description

Builds new panels from existing ones via elementwise operations. Specification accepts either a shorthand list(new = c("A","B")) (defaults to product), or a structured form list(new = list(panels=c("A","B","C"), op=/, how="intersect", fill=NA)).

Usage

ml_add_interactions(features, interactions)

Value

The input features list with additional interaction panels.

Arguments

features

List of existing panels (wide data frames with Date).

interactions

Named list describing interactions to add.

Examples

Run this code
if (FALSE) {
X2 <- ml_add_interactions(X, list(mom_vol = c("mom12","vol")))
}

Run the code above in your browser using DataLab