Forums › ProRealTime English forum › ProOrder support › Why Does Removing ONE Line of Unused Space Cause Profits to Reappear? › Reply To: Why Does Removing ONE Line of Unused Space Cause Profits to Reappear?
05/10/2020 at 4:49 PM
#130967
Not related to your question but why do you call the indicator twice? Just call it once and get all the values in one go.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 |
// Definition of code parameters DEFPARAM CumulateOrders = False // Cumulating positions deactivated indicator1, indicator2, ignored, ignored, ignored, indicator4 = CALL "PRC_MBFX Timing v2"[5, 0] // Conditions to enter long positions c1 = (indicator1 CROSSES OVER indicator2) IF c1 THEN BUY 1 PERPOINT AT MARKET ENDIF // Conditions to enter short positions c2 = (indicator1 CROSSES UNDER indicator4) IF c2 THEN SELLSHORT 1 PERPOINT AT MARKET ENDIF // Stops and targets SET STOP pLOSS 200 |