For a vector with labels corresponding to intervals i.e. "(0,10]" returns a data.frame with left and right boundaries and mid point.

unbin(x)

Arguments

x

a vector of with intervals as names

Value

a data.frame with left and right boundaries and mid points.

Examples

x=summary(cut(runif(100),seq(0,1,.1))) unbin(x)
#> left right mid n #> (0,0.1] 0.0 0.1 0.05 12 #> (0.1,0.2] 0.1 0.2 0.15 8 #> (0.2,0.3] 0.2 0.3 0.25 11 #> (0.3,0.4] 0.3 0.4 0.35 11 #> (0.4,0.5] 0.4 0.5 0.45 14 #> (0.5,0.6] 0.5 0.6 0.55 10 #> (0.6,0.7] 0.6 0.7 0.65 10 #> (0.7,0.8] 0.7 0.8 0.75 10 #> (0.8,0.9] 0.8 0.9 0.85 6 #> (0.9,1] 0.9 1.0 0.95 8