Help with FOR NEXT Loop Please

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #27541 quote
    financier
    Participant
    Junior

    Hi coders.

    I am trying to write a simple piece of code which uses a FOR NEXT Loop that analyses certain conditions of the price close after a predetermined number of intradaybar increments. rather like the STEP command in BASIC.

    For example, on a 1 second timeframe chart I might want to return the position of a price every 60th of a second, rather than have a minute chart open at the same time.

    I was wondering if there was an easy way around this problem and would be grateful for any advice.

    Thank you in advance for your help.

    #27569 quote
    Nicolas
    Keymaster
    Master

    A rough idea:

    Count how many times the current Open is different from the previous one, if your count is equal to 60, one minute has passed.

    #28412 quote
    financier
    Participant
    Junior

    Thank you for your idea Nicolas

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

Help with FOR NEXT Loop Please


ProBuilder: Indicators & Custom Tools

New Reply
Author
author-avatar
financier @financier Participant
Summary

This topic contains 2 replies,
has 2 voices, and was last updated by financier
8 years, 11 months ago.

Topic Details
Forum: ProBuilder: Indicators & Custom Tools
Language: English
Started: 03/07/2017
Status: Active
Attachments: No files
Logo Logo
Loading...