Fixed Issue #1002. Added small test case and fixed passing in strings that look like numbers

Used type coercion to coerce strings that look like numbers.