Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Entry candle identification indicator

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Entry candle identification indicator

    Dear NT8,

    I am hoping you can help me with a script to identify candle sticks. I am a complete noob when it comes to coding. However having this indicator will significantly reduce my time testing a strategy so i would like to give it a shot.

    I need an indicator that identifies the following:
    1. Candle closing between 6am-10am GMT
    2. Candle has to open and close below 50% of the overall candle.

    What is the best way to create an indicator for this?

    Many thanks,
    P

    #2
    Hi prasanttrades, thanks for posting. We have an example of making a time filter here, this uses the Time[] array to read the timestamp of the bar:



    To do operations on bar values, you must first read about how to access each price type (Documentation). The scripting language separates each price type into its own array, so we have Open, High, Low, and Close arrays that can be accessed. e.g. Close[0], Open[0], High[0], Low[0] returns the most recent price values of the candle. One can do math operations on these values e.g.

    Code:
    var x = High[0]*.5
    
    if(Close[0] < x && Open[0] < x)
    {
        Print("Signal");
    }
    Kind regards,
    -ChrisL

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by Geovanny Suaza, 02-11-2026, 06:32 PM
    0 responses
    648 views
    0 likes
    Last Post Geovanny Suaza  
    Started by Geovanny Suaza, 02-11-2026, 05:51 PM
    0 responses
    369 views
    1 like
    Last Post Geovanny Suaza  
    Started by Mindset, 02-09-2026, 11:44 AM
    0 responses
    108 views
    0 likes
    Last Post Mindset
    by Mindset
     
    Started by Geovanny Suaza, 02-02-2026, 12:30 PM
    0 responses
    572 views
    1 like
    Last Post Geovanny Suaza  
    Started by RFrosty, 01-28-2026, 06:49 PM
    0 responses
    574 views
    1 like
    Last Post RFrosty
    by RFrosty
     
    Working...
    X