Fix bug in calculations -- had to parse float