During some projects I have needed to validate some data and be as certain as possible that it is javascript numerical value that can be used in mathematical operations.
If AMD sounds good to you, have a look at mout's isNumber().