PerformanceAnalytics - Style Analysis- plotting R squared over time
On Wed, 2011-09-07 at 06:28 -0500, Kent Russell wrote:
I got the same error and data is definitely xts. I will try to debug today. Looks like my function works fine on a cumulative basis or if I use for loop but does not work with rollapply.
<...>
head(Rfund.z) ? 2000-01-31? ? 2000-03-02? ? 2000-03-31? ? 2000-05-01? ? 2000-05-31? ? 2000-07-01 -0.033951898? 0.052783466 -0.020335698 -0.006613730?
0.008663712?
0.091497179
This doesn't look like xts. An xts object of even one column will display with your dates as the index, and observations as rows. Your second, two column, series does look like an appropriately formatted xts object or matrix. Regards, - Brian
Brian G. Peterson http://braverock.com/brian/ Ph: 773-459-4973 IM: bgpbraverock