Reply To: Swing Retracement Scan

Optuma Forums Optuma Scripting Swing Retracement Scan Reply To: Swing Retracement Scan

#54353
DarrenDarren
  • Topics: 66
  • Replies: 590
  • Posts: 656

Hi Miguel,

To calculate the ratio of the current swing to the previous use this for a 3 bar swing (NOTE: this is slightly different from the script above in that inside bars are included in the swing counts).

Note however that it calculates the last confirmed swing end value, which will be different from the current close. For example AAPL’s most recent swing end value of $212.14 occurred 3 bars ago, which is 67.94% of the previous swing. The next swing hasn’t been confirmed yet, so the last close of $206.50 is only 48.35% of the previous swing.

To calculate the retracement to the most recent close instead change variable V2 above (line 10) to the following:

V2 = CLOSE()-SS1;

Save the workbook attached.

Capture

Attachments:

Pin It on Pinterest