dataset - How to Plot a Pre-Binned Histogram In R -
i have pre-binned frequency table rather large dataset. is, single column vector of bins , single column vector of counts associated bins. i'd r plot histogram of data doing further binning , summing existing counts. example, if in pre-binned data have [(0.01, 5000), (0.02, 231), (0.03, 948)], first number bin , second count, , choose 0.04 new bin width, i'd expect [(0.04, 6179)]. what's fastest , or easiest way in r? looks ggplot2 has answer. library(ggplot2) qplot(bin, data=cbind(bins,counts), weight=counts, geom="histogram")