I must be missing something simple but i am trying to return from the below number to zero decimal places, nothing i try seems to work, any suggestion appreciated
const numbers = [bedroomtemp, bedroomventtemp, loungeventtemp, loungetemp];
let max = Math.max.apply(null, numbers);
let min = Math.min.apply(null, numbers);
I am expecting two variables, one "min" and one "max". I tried Math.round but could't get it to work, quite convinced it was a case of incorrect formatting when i typed it in
thanks, copied your code and changed to make it how i need it but can't get it through to the next node. If i send msg.control = {min:10, max:80} it works fine and the debug gives me the below image