Rounding Up

Optuma Forums Optuma Scripting Rounding Up

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
  • #52623
    • Topics: 4
    • Replies: 4
    • Posts: 8

    Good day, I would like to round numbers up regardless of lesser value. For example 7.2 rounded would equal 8.  7.8 would also = 8.

    I can’t currently see a way of doing this in scripts. Would anyone have an answer?

    Many thanks


    • Topics: 3
    • Replies: 7
    • Posts: 10

    Maybe you could add 0.5 to the value and then round? Then, if V < 0.5 it will always be rounded up. If V > 0.5, it will always be rounded down.

    • Topics: 32
    • Replies: 1,650
    • Posts: 1,682

    We also have a “Floor()” function which rounds down – but not a “Ceiling()” function. You could put your result in c1 and then add 1 to it


    c1 = {your result};
    Round(Floor(c1) + 1)

Viewing 3 posts - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.

Pin It on Pinterest

By continuing to use the site, you agree to the use of cookies. more information

The cookie settings on this website are set to "allow cookies" to give you the best browsing experience possible. If you continue to use this website without changing your cookie settings or you click "Accept" below then you are consenting to this.