Re: [R-SIG-Finance] Performance Analytics Calendar Returns
On Wed, Sep 5, 2012 at 12:21 AM, Nikos Rachmanis nikos.rachma...@gmail.com wrote: However, I am trying to transform the daily returns of my PL (which also include gaps) to monthly and unfortunately the to.monthly does not work very well. i am currently trying table.TrailingPeriods and rollapply. Any other ideas or functions? ?apply.monthly apply.monthly(PnL, sum) -Garrett ___ 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.
Re: [R-SIG-Finance] Performance Analytics Calendar Returns
Nice and elegant. Thanks. On Wed, Sep 5, 2012 at 11:16 AM, G See gsee...@gmail.com wrote: On Wed, Sep 5, 2012 at 12:21 AM, Nikos Rachmanis nikos.rachma...@gmail.com wrote: However, I am trying to transform the daily returns of my PL (which also include gaps) to monthly and unfortunately the to.monthly does not work very well. i am currently trying table.TrailingPeriods and rollapply. Any other ideas or functions? ?apply.monthly apply.monthly(PnL, sum) -Garrett ___ 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. ___ 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.
Re: [R-SIG-Finance] Performance Analytics Calendar Returns
Thank you Garrett! Worked very nice! On Wed, Sep 5, 2012 at 2:16 PM, G See gsee...@gmail.com wrote: On Wed, Sep 5, 2012 at 12:21 AM, Nikos Rachmanis nikos.rachma...@gmail.com wrote: However, I am trying to transform the daily returns of my PL (which also include gaps) to monthly and unfortunately the to.monthly does not work very well. i am currently trying table.TrailingPeriods and rollapply. Any other ideas or functions? ?apply.monthly apply.monthly(PnL, sum) -Garrett [[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.
Re: [R-SIG-Finance] Performance Analytics Calendar Returns
I am trying to use the table.CalendarReturns from the Performance Analytics package with daily returns. Last I checked the help/usage file states that it expects monthly return data. There are some zOo and xts functions that do this.. ?to.monthly ?table.Annualizedreturns Cheers Krishna t(table.CalendarReturns(tradedata$daily.pnl.norm[1998/2012],as.perc=TRUE,digits=4,geometric=TRUE)) 1) is there anything wrong with my command? if not, is there any way to transform the daily results to monthly? 2) is there a function that would give me the same table for volatility and sharpe? Thank you all in advance, Nikos [[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. ___ 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.