Index futures automation

Discussion in 'Journals' started by hilmy83, Jul 3, 2022.

Can a fully automated trading strategy work in the long run?

  1. YES!

    56 vote(s)
    66.7%
  2. Hell naw.

    15 vote(s)
    17.9%
  3. I don't know, I got my own trading to worry about.

    13 vote(s)
    15.5%
  1. Overnight

    Overnight

    You don't need mentoring. Your algo has been through both medium-term bear runs and bull runs, and it is performing net positive everyday since mid February.
     
    #301     Apr 15, 2023
  2. hilmy83

    hilmy83

    #302     Apr 17, 2023
  3. When you say errors in execution, do you mean error messages in the Journal, or that in certain scenarios the program doesn't behave as it should (e.g. doesn't fully close out a position)?

    Can you give a specific example?
     
    #303     Apr 17, 2023
  4. Overnight

    Overnight

    This is gift-horse in the mouth stuff. You are annoying. You have the holy grail in your algo. Quit yer bitchin' and do it live! Try it! The longer you stay on demo, the longer you will doubt yourself, and the more opportunity you will lose! Trust me, I know! Uggggg!

    P.S. Drop the gross line. It is pointless. Net is all that matters.
     
    #304     Apr 17, 2023
    rb7 likes this.
  5. hilmy83

    hilmy83

    Did you just accuse of trading "demo"? I mean, don't make clean you out with a bet bro...i'm not that guy
     
    #305     Apr 17, 2023
  6. hilmy83

    hilmy83

    It sets an incorrect target after a stop and reverse when the net postion turns zero momentarily. ex long 5 lots, short 5 lots, short 5 lots.

    The times where it reverses all full position, target is correct. I have a feeling that the code doesn't know how to handle that net zero position. This pattern happened twice, and thought it got fixed initially.
     
    #306     Apr 17, 2023
  7. Overnight

    Overnight

    My apologies. I remember now your AMP statement. I think I am just annoyed that you for two months have been doing so well, and refuse to get to the next level. But you need to get to that level at your own pace. I just want to see more success here, because there are so many failures! :-(
     
    #307     Apr 17, 2023
  8. If you want, ask your developer for the code with only the stop and reverse orders. No need to include the details of when, why and how, only the orders themselves and any surrounding logic. If that is possible without compromising your strategy, post it here.

    You will have similar problems with other platforms. Given the resources that you have expended to date, this would be your shortest path to a solution.
     
    #308     Apr 18, 2023
  9. hilmy83

    hilmy83

    He's MIA, but i did ask him to comment so i can review. This looks like whre he was figuring out how to handle it.

    I feel like if i can increase the sleep time, it gives enough time for the full position to be executed properly

    Code:
    //    How to avoid the situation with partial STOP-order filling with zero net position?
    //
          if( PP[0]==  0)                  // No position =======
          {Sleep(100);SPOS();              // double check
           if(PP[0]==  0)
           {SORD();
            if(1==TSLM[0]&&1==TSST[0])     // Target presented; STOP-REVERSE presented
            {                              // maybe not entire filling of STOP-REVERSE
                                                                                  return;
            }
            if(1==TBLM[0]&&1==TBST[0])     // Target presented; STOP-REVERSE presented
            {                              // maybe not entire filling of STOP-REVERSE
                                                                                  return;
            }
            if(  1==TSLM[0]+TBLM[0]
               &&0==TSST[0]+TBST[0] )      // Target presented; STOP-order absent
            {   ca=CLAL();                 // Close all
             if(ca)CLRV();//else           // Process termined
                                                                                  return;
            }
            if(  0==TSLM[0]+TBLM[0]
               &&1==TSST[0]+TBST[0] )      // Target absent; STOP-order presented
            {   ca=CLAL();                 // Close all
             if(ca)CLRV();//else           // Process termined
                                                                                  return;
            }
                      /*
            if(1==TSLM[0]+TBLM[0])         // Non-triggererd target or B/E presented
            {   ca=CLAL();                 // Close all
             if(ca)CLRV();//else           // Process termined
                                                                                  return;
            }else
            if(1<=TSST[0]+TBST[0])         // Non-triggered altsize presented
            {   ca=CLAL();                 // Close all
             if(ca)CLRV();//else           // Process termined
                                                                                  return;
            }else     */
            if(0==TSLM[0]+TBLM[0]          // No pending orders
                 +TSST[0]+TBST[0])
            {      CLRV();                 // Process termined
                                                                                  return;
            }
           }
          }
       }
    }
     
    Last edited: Apr 18, 2023
    #309     Apr 18, 2023
  10. I didn't know he's MIA, that certainly hamstrings you. There's not enough info in the code above. I need to know, among other things, how he determines there is no position, or exactly how PP[0] is defined. How does he process the orders? Without knowledge of MQL5, I can't expect you to answer these questions by uploading the necessary portions of code. So unfortunately I can't really be of much assistance in these circumstances.
     
    #310     Apr 18, 2023