Coding Criteria using multiple conditions

Forums ProRealTime English forum ProScreener support Coding Criteria using multiple conditions

Viewing 6 posts - 1 through 6 (of 6 total)
  • #145782

    Pro Screener Questions

    System Name Conqueror

    So I currently have this system that has 3 conditions. If all three conditions are met we have the count =+3 (we go long) and if all three conditions are not me we have the count=-3(we got short).

    I am trying to develop a screener where it will search for when we have the first initial count of +3 or -3 condition.

    I am not sure how to code it where the screener looks back to the previous day (maybe use barindex??)  to see if we have the count of +1, +2 or -1, -2 then sees that today… we now have the count of +3 or -3. In such that I want to go long or go short on the very first signal not during the middle of the move.

     

    In addition to searching for the first initial criteria of +3  or -3. I want and additional criteria where we use the ADX14 where the slope must be positive to take the trade ie show up in the screener.

    I have attached some screen shots of what a good signal and bad signal would be, the PRT indicator and the PRT screener code that I have developed so far.

    Any help would be greatly appreciated.

    #145790

    Here is the modified screener, so that it returns only the first signal, with the addition of ADX as a filter:

    When attaching files, please attach only:

    • ITF files for the ProRealTime platform
    • TXT or PDF files for unformatted text
    • PDF files for formatted text and documents
    • JPG or PNG files for images.

    Moreover, when posting ITF (code) files, please post also the source code (using the “Insert PRT code” button to make it easier to read).

    Thank you 🙂

     

    #146129

    Hi Roberto,

    Thank you so much for the support. I do have a few more questions. I did make a few modifications to your code that you provided. You can see my comments in the code. But for some reason this isnt working 100% correct all the time. Also I am the person that reached out on August 13 for one on one tutoring. I am almost ready to set up an appointment with you.

    The +3 trades seem to work most of the time (see attached screen shots)

    The -3 trades dont seem to work as well.   (see attached screen shots)

     

     

     

    #146236

    I replaced the last line of the screener with:

    then I converted it into this indicator:

    and it seems to be working fine.

     

     

    #146299

    Hi Roberto,

    Thank you once again. I added your adjustments to my code. I think I was a little bit vague in my last post.

    I am fairly confident in my indicator working correctly, but I am having trouble in the screener itself.

    I think we are very close to having it work 100%. I just ran the screener on the predefined list “US NASDAQ Stocks”.

    The Screener does produce initial +3 signals correctly most of the time… But for example this stock “FLDM” was listed as a fresh +3 signal, but it is actually the second +3 signal in the string and shouldnt have shown up at all. Thursday Oct 1st was the first +3 day, but the adx was negative so it technically shouldn’t show up in the screener for Oct 1.  On Oct 2nd we got another +3 signal and the first day we got a positive ADX.  So maybe the order of the code needs to be switched around so the adx is read first?

    Also

    #146423

    I was able to figure it out on my own.

    Thank you once again. !

    Now time to try to get a backtest worked out for this.

    1 user thanked author for this post.
Viewing 6 posts - 1 through 6 (of 6 total)

Create your free account now and post your request to benefit from the help of the community
Register or Login