Memoize catalog statistics for speed

See #114
tweak input types for caching
Merge pull request #115 from ChrisBeaumont/memoize

Memoize catalog statistics