Support Board
Date/Time: Sat, 08 Feb 2025 15:35:31 +0000
Post From: based on slope
[2020-07-04 15:46:19] |
Sawtooth - Posts: 4173 |
Since you have so many other things going on, I'll just give you the slope formula for one of the lines, and you can go from there. Add the Spreadsheet Formula study, put this in the Formula field: =IF(OR(ID15.SG1>ID15.SG1[-1],AND(ID15.SG1[-2]>=ID15.SG1[-1],ID15.SG1>ID15.SG1[-1])),1,IF(OR(ID15.SG1<ID15.SG1[-1],AND(ID15.SG1[-2]<=ID15.SG1[-1],ID15.SG1<ID15.SG1[-1])),-1,ID16.SG1[-1])) - where ID16 is the Spreadsheet Formula study. Up slopes will be 1 and downslopes will be -1. |