new method to test if a string is numeric