evaluate_momentum_predict_price: Evaluate momentum price prediction

Description Usage Arguments Value

View source: R/momentum_data.R

Description

Give the price predicted by the momentum.

Usage

1
2
3
4
5
6
evaluate_momentum_predict_price(
  agg_windows,
  momentum_window_size,
  momentum_colname = "momentum",
  use_signed_momentum = TRUE
)

Arguments

momentum_window_size

the size determining momentum, which must be at least 2 and is assumed to be at most the size of the price windows in agg_windows

momentum_colname

The name of the column holding the true momentum values (as a string), defaults to "momentum".

aggregated_momentum_data

A tibble of class @eval{AGG_WINDOW_CLASS_NAME} as returned from aggregate_price_and_mean_windows, with an added column of column name momentum_colname holding the momentum.

consider_negative_momentum

TRUE to treat momentum as signed (see evaluate_signed_momentum_at_window()), otherwise assumed to be regular momentum (see evaluate_momentum_at_window())

Value

A column vector whose ith entry is the predicted price for the ith row, using the predicted momentum as a guide.


benSepanski/pfselect documentation built on May 1, 2020, 1:57 p.m.