Use a set instead so you can whitelist/blacklist certain characters. Remember that . is a magic character in string patterns, so to cancel out its characteristic you must escape it with a percent sign % before the period. So that means the pattern you get is "[^%d%.]+"
The ^ means to match anything that is not a digit or a period.