| filter_threshold | R Documentation |
Selects stocks above or below a threshold value.
filter_threshold(signal_df, value, type = c("above", "below"))
signal_df |
Data frame with signal values |
value |
Threshold value |
type |
"above" or "below" |
Binary selection matrix
data("sample_prices_weekly")
momentum <- calc_momentum(sample_prices_weekly, 12)
# Select stocks with positive momentum
positive <- filter_threshold(momentum, 0, type = "above")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.