The calculation is failing because the values are interpreted as strings rather than numbers.
Assuming you expect the values to be integers, try extracting them like this:
I would suggest using a regex to validate the content is numeric before attempting to parse.
Cheers