Fix #3756: Convert values to float for number formatting