Toad 20 posts msg #124433 - Ignore Toad |
7/19/2015 11:48:50 PM
I am trying to create a screener that will indicate the number of days since the lowest low of a certain time period (have it set to 100 days currently). What I created seems to indicate the days since the highest high or lowest low only if the high (or low) has no higher high (or lower low) in the 100 days proceeding it..the lowday / highday returns -1 if this is not the case. Not sure that makes sense, so let me give an example:
Stock A has a highest high 20 days ago and no higher highs 100 days prior to it (so effectively no higher highs than the 20 day one for 120 days from the present). My screener returns the correct value, 20.
Stock A has a lowest low 50 days ago and has a lower low 60 days prior to it (so effectively no lower lows than the 50 day one for 110 days from the present). My screener returns the value, -1. I want my screener to return 50 for this since the lowest low in the past 100 days is 50 days ago.
Here is the screener so far:
|