Robert, There's actually a way to compute turnover with Return.portfolio, with verbose = TRUE. It returns end of period weights, and beginning of period weights, so the turnover can be computed as beginWeights - lag(endWeights).
-Ilya On Tue, May 10, 2016 at 3:50 PM, Robert Wages <rob...@rwages.com> wrote: > Return.portfolio is an easy function to use to calculate the aggregate > performance of a portfolio that is rebalanced on a regular basis or that > has > a custom weighting scheme on the same periodicity of returns. I cannot > find > any provision in Return.portfolio, however, for incorporating the > transaction costs for the rebalancing in the portfolio. The resulting > portfolio performance would seem to be high to the extent of the > transaction costs. > > > > On the other hand, running strategies in Quantstrat on individual > securities > (or groups of securities) allows one to take into account estimated trading > costs to generate somewhat realistic performance estimates. Quantstrat, > however, does not seem to have any readily accessible functions to balance > a > portfolio of securities within a portfolio limit. Previous related > discussions seem to suggest the only solution is to write custom order > sizing functions to include in the strategy's rules. > > > > I may be able to figure how to write custom functions in Quantstrat to do > this after a lot of brain damage, or alternatively my own version of > Return.portfolio, but I thought I should check with the community to see if > there are any better suggestions for this. Given that many investment > strategies rely on portfolio rebalancing under some set of rules, as > opposed > to buying and selling individual securities on the basis of rules, I would > be surprised if I were the first person to wonder about this. > > > > Robert C Wages > > USA Mobile: +1 717 618 2828 > > rob...@rwages.com <mailto:rob...@rwages.com> > > > > > [[alternative HTML version deleted]] > > _______________________________________________ > R-SIG-Finance@r-project.org mailing list > https://stat.ethz.ch/mailman/listinfo/r-sig-finance > -- Subscriber-posting only. If you want to post, subscribe first. > -- Also note that this is not the r-help list where general R questions > should go. > [[alternative HTML version deleted]] _______________________________________________ R-SIG-Finance@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-sig-finance -- Subscriber-posting only. If you want to post, subscribe first. -- Also note that this is not the r-help list where general R questions should go.