Histogram subsets snap to bin edges

Closes #242
Merge pull request #336 from ChrisBeaumont/242

Histogram subsets snap to bin edges