Creates table showing statistics for the worst drawdowns.

table.Drawdowns(R, top = 5, digits = 4, geometric = TRUE, ...)

Arguments

R

an xts, vector, matrix, data frame, timeSeries or zoo object of asset returns

top

the number of drawdowns to include

digits

number of digits to round results to

geometric

utilize geometric chaining (TRUE) or simple/arithmetic chaining (FALSE) to aggregate returns, default TRUE

any other passthru parameters

Details

Returns an data frame with columns:

  • From starting period, high water mark

  • Trough period of low point

  • To ending period, when initial high water mark is recovered

  • Depth drawdown to trough (typically as percentage returns)

  • Length length in periods

  • toTrough number of periods to trough

  • Recovery number of periods to recover

References

Bacon, C. Practical Portfolio Performance Measurement and Attribution. Wiley. 2004. p. 88

See also

DownsideDeviation maxDrawdown findDrawdowns sortDrawdowns chart.Drawdown table.DownsideRisk

Examples

data(edhec) table.Drawdowns(edhec[,1,drop=FALSE])
#> From Trough To Depth Length To Trough Recovery #> 1 2007-11-30 2008-11-30 <NA> -0.2927 23 13 NA #> 2 2004-05-31 2005-05-31 2006-02-28 -0.0822 22 13 9 #> 3 1998-08-31 1998-10-31 1999-03-31 -0.0712 8 3 5 #> 4 2003-06-30 2003-08-31 2003-10-31 -0.0215 5 3 2 #> 5 2007-07-31 2007-08-31 2007-10-31 -0.0197 4 2 2
table.Drawdowns(edhec[,12,drop=FALSE])
#> From Trough To Depth Length To Trough Recovery #> 1 1998-09-30 2000-08-31 2002-09-30 -0.4956 49 24 25 #> 2 2002-10-31 2007-05-31 2009-02-28 -0.3630 77 56 21 #> 3 2009-03-31 2009-08-31 <NA> -0.1972 7 6 NA #> 4 1997-04-30 1997-09-30 1998-03-31 -0.1502 12 6 6 #> 5 1997-01-31 1997-01-31 1997-02-28 -0.0166 2 1 1
data(managers) table.Drawdowns(managers[,8,drop=FALSE])
#> From Trough To Depth Length To Trough Recovery #> 1 2000-09-30 2002-09-30 2006-10-31 -0.4473 74 25 49 #> 2 1998-07-31 1998-08-31 1998-11-30 -0.1537 5 2 3 #> 3 2000-01-31 2000-02-29 2000-03-31 -0.0682 3 2 1 #> 4 1999-07-31 1999-09-30 1999-11-30 -0.0624 5 3 2 #> 5 1997-08-31 1997-08-31 1997-11-30 -0.0560 4 1 3
result=table.Drawdowns(managers[,1,drop=FALSE]) # This was really nice before Hmisc messed up 'format' from R-base #require("Hmisc") #textplot(Hmisc::format.df(result, na.blank=TRUE, numeric.dollar=FALSE, # cdec=c(rep(3,4), rep(0,3))), rmar = 0.8, cmar = 1.5, # max.cex=.9, halign = "center", valign = "top", row.valign="center", # wrap.rownames=5, wrap.colnames=10, mar = c(0,0,3,0)+0.1) # title(main="Largest Drawdowns for HAM1")