djhunter/binsmooth

Deal with bounded upper bins

Opened this issue · 0 comments

The functions all estimate the mean assuming the top bin is unbounded. If the top bin is bounded, we should estimate the mean using something like the following.

if(is.null(m))  # no mean provided, so make one up
    m <- sum(0.5*(bEdges[1:L]+c(0, bEdges[1:(L-1)]))*bCounts/tot)