Refactor to use floats