indicator Rounded number price value

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #90894 quote
    PEDRAM.JOKARPEDRAM.JOKAR
    Participant
    Average

    Hi

    Kindly, help with an indicator that draw horizontal lines on chart in rounded market price numbers with maximum hundredth value. (example, 1.23000)

    #90900 quote
    robertogozzirobertogozzi
    Moderator
    Legend

    If you need to keep only 2 decimal digits you’ll have to:

    • multiply it by 100
    • round it
    • divide it by 100
    a = close * 100
    b = round(a - 0.5)
    c = b / 100

    whether CLOSE is 1.23380, or 1.23999, it will be rounded to 1.23000

    PEDRAM.JOKAR and BobFlynn thanked this post
    #90902 quote
    VonasiVonasi
    Moderator
    Master

    There is this one in the library:

    Sweet Spots – round numbers

    PEDRAM.JOKAR thanked this post
Viewing 3 posts - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.
ProRealAI ProRealAI New

Stuck on this ProBuilder code?

Describe what this topic is trying to build, in plain English, and ProRealAI writes the ProRealTime™ indicator, screener or system for you.

Available in 7 languages
Try ProRealAI

indicator Rounded number price value


ProBuilder: Indicators & Custom Tools

New Reply
Author
Summary

This topic contains 2 replies,
has 3 voices, and was last updated by VonasiVonasi
7 years, 7 months ago.

Topic Details
Forum: ProBuilder: Indicators & Custom Tools
Language: English
Started: 02/08/2019
Status: Active
Attachments: No files
ProRealCode ProRealCode
Loading...