Curious how you arrived at this?  Not too important for a one off, but I think the thresholds should be options with defaults.