rank2sell function

Compute the portfolio return knowing the rank of a stock in the input mtx'.This function computes the return earned knowing the rank of a stock computed elsewhere and named myrank associate with the data columns in the input mtx of stock returns. For example, mtx has p=28 Dow Jones stocks over n=169 monthly returns. Portfolio weights are assumed to be linearly declining. If maxChosen=4, the weights are 1/10, 2/10, 3/10 and 4/10, which add up to unity. These portfolio weights are assigned in their order in the sense that first chosen stock (choice rank =p) gets portfolio weight=4/10. The function computes return from the stocks using the myrank' argument. This helps in assessing out-of-sample performance of (short) the strategy of selling lowest ranking stocks. It is mostly for internal use by outOFsell(). This is a sell version of rank2return().

  • Maintainer: H. D. Vinod
  • License: GPL (>= 2)
  • Last published: 2023-10-09

Useful links