Function to perform rank by an external (pre-calculated) variable, accounting for membership. Analogous to 'momRankMembers' but assumes a pre-calculated variable, instead of calculating and ranking on price momentum.
1 | VarRankMembers(dn, s = 0, hist_members = newHM)
|
dn |
xts object of variables ready to rank. Columns assumed to be individual assets. |
s |
Skip period (integer). This is the time between the variable calculation date (end of formation period) and ranking (and presumably investment) date. |
hist_members |
xts object containing membership data. Column names are assumed to be asset names corresponding to those in df. Note: All entries not NA are assumed to represent active membership. |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.