Add a variable to replace hard-coded upper bound

Haven't tested this since I don't have a large set of data.
typo
Merge pull request #637 from hexmode/master

Add a variable to replace hard-coded upper bound