I am working on presenting some threadfield results in a star format (like the rating system) and I am struggling on the rounding of the outputted values. I need them to be a number like 1.5 or 2 or 2.5 etc, but I cannot figure out the correct conditional to do this.
This is my code so far:
The values for the threadfields are 3, 3 and 2 which gives me a result of 8.
I then divided 8 by 3
and that gave me a result of 2.66666667 and it is this number I want to round to 2.5.
I tried the code below but it just gave no output. I was hoping it would round it to the decimal point.
All help appreciated.