Jss scripting .state to number?

What is the right syntax for converting .state to number in jss rules?

var tempcalibration = (items.getItem(Thermostat1_local_temperature).state … i already tried few thinks without luck ?

ok found it parseInt()