[Returnanalytics-commits] r2290 - pkg/PerformanceAnalytics/R

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Thu Oct 25 17:22:45 CEST 2012


Author: braverock
Date: 2012-10-25 17:22:45 +0200 (Thu, 25 Oct 2012)
New Revision: 2290

Modified:
   pkg/PerformanceAnalytics/R/StdDev.annualized.R
Log:
- use sd.default for vector

Modified: pkg/PerformanceAnalytics/R/StdDev.annualized.R
===================================================================
--- pkg/PerformanceAnalytics/R/StdDev.annualized.R	2012-10-06 17:10:15 UTC (rev 2289)
+++ pkg/PerformanceAnalytics/R/StdDev.annualized.R	2012-10-25 15:22:45 UTC (rev 2290)
@@ -66,7 +66,7 @@
                 yearly = {scale = 1}
             )
         }
-        sqrt(scale)*sd.xts(x, na.rm=TRUE)
+        sqrt(scale)*sd(x, na.rm=TRUE)
     } else { 
         result = apply(x, 2, sd.multiperiod, scale=scale)
         dim(result) = c(1,NCOL(x))



More information about the Returnanalytics-commits mailing list