Registered User Joined: 6/30/2017 Posts: 1,227
|
Not making any claims for the "Knoxville Divergence" but I've been pondering price/momentum divergences lately, and this seems like a reasonable short-term setup.
The first step in the process (in TC2000) I would assume is to identify "pivots" (and perhaps highlight pivots on the price pane with dots above pivot highs and below pivot lows). For this discussion a pivot high is defined as a bar whose high is surrounded by two lower highs. Reverse for pivot lows.
Given the definition, I know that plotting the dot would be delayed by a bar, but that's probably okay.
The rest of the Knoxville Divergence is probably not automate-able in TC2000, but if anyone can, Bruce can figure it out. Or at least partly. The fewer charts I have to flip through, the more time I can spend at the golf course. :)
I'm thinking the best we can do is be alerted, or scan for, pivots, then visually inspect momentum (pick your favorite measure) since the previous pivot, and then check RSI. The RSI value would be easy to scan for, I guess, but as with other divergence setups, scanning for momentum divergences is the sticky bit.
What drew me to this divergence is that it's pretty much the classic defintion of a divergence (leaving out the RSI for now).
... and the arrival of a pivot seems as good a time as any to check for divergences.
... and in the video (link above) Jeff Gibby says this particular implementation of a divergence setup doesn't occur very often. And why would Jeff lie? LOL. Just kidding. Not disparaging Jeff, just saying that I learned long ago not to believe everything I see on the internet.
The only person I trust online is Bruce. :)
|
|
Worden Trainer
Joined: 10/7/2004 Posts: 65,138
|
The basic idea is pretty much the same as in the Divergence between Price and MACD Histogram topic, but things can be a lot shorter using nested IIF() functions than with MACD, because we are looking for the pivot high in price instead of the MACD Histogram.
MAXH2 < H2 AND H2 > MAXH2.3 AND WRSI21.2 > 70 AND H2 / H22 < IIF(MAXH2.3 < H5 AND H5 > MAXH2.6, IIF(H2 > H5, C5 / C25, 0), IIF(MAXH2.4 < H6 AND H6 > MAXH2.7, IIF(H2 > H6, C6 / C26, 0), IIF(MAXH2.5 < H7 AND H7 > MAXH2.8, IIF(H2 > H7, C7 / C27, 0), IIF(MAXH2.6 < H8 AND H8 > MAXH2.9, IIF(H2 > H8, C8 / C28, 0), IIF(MAXH2.7 < H9 AND H9 > MAXH2.10, IIF(H2 > H9, C9 / C29, 0), IIF(MAXH2.8 < H10 AND H10 > MAXH2.11, IIF(H2 > H10, C10 / C30, 0), IIF(MAXH2.9 < H11 AND H11 > MAXH2.12, IIF(H2 > H11, C11 / C31, 0), IIF(MAXH2.10 < H12 AND H12 > MAXH2.13, IIF(H2 > H12, C12 / C32, 0), IIF(MAXH2.11 < H13 AND H13 > MAXH2.14, IIF(H2 > H13, C13 / C33, 0), IIF(MAXH2.12 < H14 AND H14 > MAXH2.15, IIF(H2 > H14, C14 / C34, 0), IIF(MAXH2.13 < H15 AND H15 > MAXH2.16, IIF(H2 > H15, C15 / C35, 0), IIF(MAXH2.14 < H16 AND H16 > MAXH2.17, IIF(H2 > H16, C16 / C36, 0), IIF(MAXH2.15 < H17 AND H17 > MAXH2.18, IIF(H2 > H17, C17 / C37, 0), IIF(MAXH2.16 < H18 AND H18 > MAXH2.19, IIF(H2 > H18, C18 / C38, 0), IIF(MAXH2.17 < H19 AND H19 > MAXH2.20, IIF(H2 > H19, C19 / C39, 0), IIF(MAXH2.18 < H20 AND H20 > MAXH2.21, IIF(H2 > H20, C20 / C40, 0), IIF(MAXH2.19 < H21 AND H21 > MAXH2.22, IIF(H2 > H21, C21 / C41, 0), IIF(MAXH2.20 < H22 AND H22 > MAXH2.23, IIF(H2 > H22, C22 / C42, 0), IIF(MAXH2.21 < H23 AND H23 > MAXH2.24, IIF(H2 > H23, C23 / C43, 0), IIF(MAXH2.22 < H24 AND H24 > MAXH2.25, IIF(H2 > H24, C24 / C44, 0), IIF(MAXH2.23 < H25 AND H25 > MAXH2.26, IIF(H2 > H25, C25 / C45, 0), IIF(MAXH2.24 < H26 AND H26 > MAXH2.27, IIF(H2 > H26, C26 / C46, 0), IIF(MAXH2.25 < H27 AND H27 > MAXH2.28, IIF(H2 > H27, C27 / C47, 0), IIF(MAXH2.26 < H28 AND H28 > MAXH2.29, IIF(H2 > H28, C28 / C48, 0), IIF(MAXH2.27 < H29 AND H29 > MAXH2.30, IIF(H2 > H29, C29 / C49, 0), IIF(MAXH2.28 < H30 AND H30 > MAXH2.31, IIF(H2 > H30, C30 / C50, 0), IIF(MAXH2.29 < H31 AND H31 > MAXH2.32, IIF(H2 > H31, C31 / C51, 0), IIF(MAXH2.30 < H32 AND H32 > MAXH2.33, IIF(H2 > H32, C32 / C52, 0), IIF(MAXH2.31 < H33 AND H33 > MAXH2.34, IIF(H2 > H33, C33 / C53, 0), IIF(MAXH2.32 < H34 AND H34 > MAXH2.35, IIF(H2 > H34, C34 / C54, 0), IIF(MAXH2.33 < H35 AND H35 > MAXH2.36, IIF(H2 > H35, C35 / C55, 0), IIF(MAXH2.34 < H36 AND H36 > MAXH2.37, IIF(H2 > H36, C36 / C56, 0), IIF(MAXH2.35 < H37 AND H37 > MAXH2.38, IIF(H2 > H37, C37 / C57, 0), IIF(MAXH2.36 < H38 AND H38 > MAXH2.39, IIF(H2 > H38, C38 / C58, 0), IIF(MAXH2.37 < H39 AND H39 > MAXH2.40, IIF(H2 > H39, C39 / C59, 0), IIF(MAXH2.38 < H40 AND H40 > MAXH2.41, IIF(H2 > H40, C40 / C60, 0), IIF(MAXH2.39 < H41 AND H41 > MAXH2.42, IIF(H2 > H41, C41 / C61, 0), IIF(MAXH2.40 < H42 AND H42 > MAXH2.43, IIF(H2 > H42, C42 / C62, 0), IIF(MAXH2.41 < H43 AND H43 > MAXH2.44, IIF(H2 > H43, C43 / C63, 0), IIF(MAXH2.42 < H44 AND H44 > MAXH2.45, IIF(H2 > H44, C44 / C64, 0), IIF(MAXH2.43 < H45 AND H45 > MAXH2.46, IIF(H2 > H45, C45 / C65, 0), IIF(MAXH2.44 < H46 AND H46 > MAXH2.47, IIF(H2 > H46, C46 / C66, 0), IIF(MAXH2.45 < H47 AND H47 > MAXH2.48, IIF(H2 > H47, C47 / C67, 0), IIF(MAXH2.46 < H48 AND H48 > MAXH2.49, IIF(H2 > H48, C48 / C68, 0), IIF(MAXH2.47 < H49 AND H49 > MAXH2.50, IIF(H2 > H49, C49 / C69, 0), IIF(MAXH2.48 < H50 AND H50 > MAXH2.51, IIF(H2 > H50, C50 / C70, 0), IIF(MAXH2.49 < H51 AND H51 > MAXH2.52, IIF(H2 > H51, C51 / C71, 0), IIF(MAXH2.50 < H52 AND H52 > MAXH2.53, IIF(H2 > H52, C52 / C72, 0), IIF(MAXH2.51 < H53 AND H53 > MAXH2.54, IIF(H2 > H53, C53 / C73, 0), IIF(MAXH2.52 < H54 AND H54 > MAXH2.55, IIF(H2 > H54, C54 / C74, 0), 0))))))))))))))))))))))))))))))))))))))))))))))))))
-Bruce Personal Criteria Formulas TC2000 Support Articles
|
|
Registered User Joined: 6/30/2017 Posts: 1,227
|
Being a computer programmer, I should be better at reading PCFs, but the lack of identation, whitespace, and comments just fry my brain cells. Sorry.
What is this PCF doing? Finding the latest pivot? Comparing the last two pivots? Is momentum in there somewhere?
|
|
Worden Trainer
Joined: 10/7/2004 Posts: 65,138
|
The first part checks for a pivot high, the 21 period Wilder's RSI at that pivot high being greater than 70 and calculates the 20 period momentum at the pivot high (without actually multiplying it by 100 to convert it into a percentage).
MAXH2 < H2 AND H2 > MAXH2.3 AND WRSI21.2 > 70 AND H2 / H22
The next part checks for the most recent pivot high (checking between 5 bars through 54 bars ago). If it finds a pivot high, it calculates the 20 period momentum at that pivot high only if the pivot high at H2 is higher (otherwise it returns 0).
It uses nested IIF() functions for this because we can't use a formula as an offset parameter. Otherwise this part would be a lot shorter (the following version of the last part will not work!).
IIF(SinceTrue(MAXH2.3 < H5 AND H5 > MAXH2.6, 50) >= 0, C(SinceTrue(MAXH2.3 < H5 AND H5 > MAXH2.6, 50) + 5) / C(SinceTrue(MAXH2.3 < H5 AND H5 > MAXH2.6), 50) + 25)
There is a < sign between that last part and the calculation of the momentum at the most recent previous pivot high to check for the momentum to have gone down (which can't be true if that last part returns 0 instead of a momentum value).
-Bruce Personal Criteria Formulas TC2000 Support Articles
|
|
Registered User Joined: 6/30/2017 Posts: 1,227
|
Pretty cool. Thanks, Bruce!
And to think, MetaStock charges $99 for their Knoxville Divergence add-on.
Bruce, you're AWESOME.
|
|
Registered User Joined: 6/30/2017 Posts: 1,227
|
Not to be a pain, but ... I'm sure Rob Booker is the world's greatest trader but can we get a PCF without checking the RSI?
I know that that means it is no longer a "Knoxville" divergence, but I'm interested in the price/momentum divergence aspect of this.
And with both PCFs available, folks can compare & contrast and see which they prefer. :)
|
|
Registered User Joined: 6/30/2017 Posts: 1,227
|
Another reason to toss the RSI ... I don't recommend watching Rob Booker's video (it's almost an hour) unless you're really interested, but Rob also includes Stochastics in the mix.
Booker's video is circa 2013, while MetaStock's is from this year, so maybe Booker no longer uses Stochastics in this setup. Or maybe he does and they decided not to include that tiny detail in their MetaStock implementation.
Also, in Booker's video the RSI > 70 requirement is at any time during the span of bars from the previous pivot to the latest pivot, not just at the latest pivot. Granted, RSI will probably be at its highest point at the most recent pivot, but maybe not.
Long story short, when you have a minute ... how about a PCF with the two pivots, and momentum. Pretty please?
I really like your choice of looking back 20 periods for momentum, and looking back between 5 and 54 bars for the previous pivot.
If anyone has any experience with Rob Booker, I'd love to hear about it. Is he "for reals"? He seems to have been smoking something the day he recorded that video. Suppose that's just his style. If it ain't broke...
|
|
Worden Trainer
Joined: 10/7/2004 Posts: 65,138
|
I pulled the 20 period momentum I used from a PDF or webpage I found on the subject (so not really my idea... was just trying to find some numbers to plug into the formula). The lookback used to check for another pivot was entirely arbitrary (well the lower bound is not, but the upper bound is).
Removing AND WRSI21.2 > 70 from the formula should make it do what you want.
MAXH2 < H2 AND H2 > MAXH2.3 AND H2 / H22 < IIF(MAXH2.3 < H5 AND H5 > MAXH2.6, IIF(H2 > H5, C5 / C25, 0), IIF(MAXH2.4 < H6 AND H6 > MAXH2.7, IIF(H2 > H6, C6 / C26, 0), IIF(MAXH2.5 < H7 AND H7 > MAXH2.8, IIF(H2 > H7, C7 / C27, 0), IIF(MAXH2.6 < H8 AND H8 > MAXH2.9, IIF(H2 > H8, C8 / C28, 0), IIF(MAXH2.7 < H9 AND H9 > MAXH2.10, IIF(H2 > H9, C9 / C29, 0), IIF(MAXH2.8 < H10 AND H10 > MAXH2.11, IIF(H2 > H10, C10 / C30, 0), IIF(MAXH2.9 < H11 AND H11 > MAXH2.12, IIF(H2 > H11, C11 / C31, 0), IIF(MAXH2.10 < H12 AND H12 > MAXH2.13, IIF(H2 > H12, C12 / C32, 0), IIF(MAXH2.11 < H13 AND H13 > MAXH2.14, IIF(H2 > H13, C13 / C33, 0), IIF(MAXH2.12 < H14 AND H14 > MAXH2.15, IIF(H2 > H14, C14 / C34, 0), IIF(MAXH2.13 < H15 AND H15 > MAXH2.16, IIF(H2 > H15, C15 / C35, 0), IIF(MAXH2.14 < H16 AND H16 > MAXH2.17, IIF(H2 > H16, C16 / C36, 0), IIF(MAXH2.15 < H17 AND H17 > MAXH2.18, IIF(H2 > H17, C17 / C37, 0), IIF(MAXH2.16 < H18 AND H18 > MAXH2.19, IIF(H2 > H18, C18 / C38, 0), IIF(MAXH2.17 < H19 AND H19 > MAXH2.20, IIF(H2 > H19, C19 / C39, 0), IIF(MAXH2.18 < H20 AND H20 > MAXH2.21, IIF(H2 > H20, C20 / C40, 0), IIF(MAXH2.19 < H21 AND H21 > MAXH2.22, IIF(H2 > H21, C21 / C41, 0), IIF(MAXH2.20 < H22 AND H22 > MAXH2.23, IIF(H2 > H22, C22 / C42, 0), IIF(MAXH2.21 < H23 AND H23 > MAXH2.24, IIF(H2 > H23, C23 / C43, 0), IIF(MAXH2.22 < H24 AND H24 > MAXH2.25, IIF(H2 > H24, C24 / C44, 0), IIF(MAXH2.23 < H25 AND H25 > MAXH2.26, IIF(H2 > H25, C25 / C45, 0), IIF(MAXH2.24 < H26 AND H26 > MAXH2.27, IIF(H2 > H26, C26 / C46, 0), IIF(MAXH2.25 < H27 AND H27 > MAXH2.28, IIF(H2 > H27, C27 / C47, 0), IIF(MAXH2.26 < H28 AND H28 > MAXH2.29, IIF(H2 > H28, C28 / C48, 0), IIF(MAXH2.27 < H29 AND H29 > MAXH2.30, IIF(H2 > H29, C29 / C49, 0), IIF(MAXH2.28 < H30 AND H30 > MAXH2.31, IIF(H2 > H30, C30 / C50, 0), IIF(MAXH2.29 < H31 AND H31 > MAXH2.32, IIF(H2 > H31, C31 / C51, 0), IIF(MAXH2.30 < H32 AND H32 > MAXH2.33, IIF(H2 > H32, C32 / C52, 0), IIF(MAXH2.31 < H33 AND H33 > MAXH2.34, IIF(H2 > H33, C33 / C53, 0), IIF(MAXH2.32 < H34 AND H34 > MAXH2.35, IIF(H2 > H34, C34 / C54, 0), IIF(MAXH2.33 < H35 AND H35 > MAXH2.36, IIF(H2 > H35, C35 / C55, 0), IIF(MAXH2.34 < H36 AND H36 > MAXH2.37, IIF(H2 > H36, C36 / C56, 0), IIF(MAXH2.35 < H37 AND H37 > MAXH2.38, IIF(H2 > H37, C37 / C57, 0), IIF(MAXH2.36 < H38 AND H38 > MAXH2.39, IIF(H2 > H38, C38 / C58, 0), IIF(MAXH2.37 < H39 AND H39 > MAXH2.40, IIF(H2 > H39, C39 / C59, 0), IIF(MAXH2.38 < H40 AND H40 > MAXH2.41, IIF(H2 > H40, C40 / C60, 0), IIF(MAXH2.39 < H41 AND H41 > MAXH2.42, IIF(H2 > H41, C41 / C61, 0), IIF(MAXH2.40 < H42 AND H42 > MAXH2.43, IIF(H2 > H42, C42 / C62, 0), IIF(MAXH2.41 < H43 AND H43 > MAXH2.44, IIF(H2 > H43, C43 / C63, 0), IIF(MAXH2.42 < H44 AND H44 > MAXH2.45, IIF(H2 > H44, C44 / C64, 0), IIF(MAXH2.43 < H45 AND H45 > MAXH2.46, IIF(H2 > H45, C45 / C65, 0), IIF(MAXH2.44 < H46 AND H46 > MAXH2.47, IIF(H2 > H46, C46 / C66, 0), IIF(MAXH2.45 < H47 AND H47 > MAXH2.48, IIF(H2 > H47, C47 / C67, 0), IIF(MAXH2.46 < H48 AND H48 > MAXH2.49, IIF(H2 > H48, C48 / C68, 0), IIF(MAXH2.47 < H49 AND H49 > MAXH2.50, IIF(H2 > H49, C49 / C69, 0), IIF(MAXH2.48 < H50 AND H50 > MAXH2.51, IIF(H2 > H50, C50 / C70, 0), IIF(MAXH2.49 < H51 AND H51 > MAXH2.52, IIF(H2 > H51, C51 / C71, 0), IIF(MAXH2.50 < H52 AND H52 > MAXH2.53, IIF(H2 > H52, C52 / C72, 0), IIF(MAXH2.51 < H53 AND H53 > MAXH2.54, IIF(H2 > H53, C53 / C73, 0), IIF(MAXH2.52 < H54 AND H54 > MAXH2.55, IIF(H2 > H54, C54 / C74, 0), 0))))))))))))))))))))))))))))))))))))))))))))))))))
-Bruce Personal Criteria Formulas TC2000 Support Articles
|
|
Registered User Joined: 6/30/2017 Posts: 1,227
|
QUOTE (Bruce_L) I pulled the 20 period momentum I used from a PDF or webpage I found on the subject (so not really my idea... was just trying to find some numbers to plug into the formula).
Don't be modest Bruce. I heard Steve Jobs once ascribe a quote to Pable Picasso:
Good artists copy; great artists steal.
There's some debate if Picasso actually said it, but the point stands. I've come up with original ideas on my own, but some of my best work is taking something else and making it waaaay better. Not everything has to be built from scratch. Some wheels aren't worth reinventing.
That said, I appreciate the new version. Once I isolate price/momentum divergence with this, I can always look at overbought/oversold criteria separately if I choose to.
Thanks again, Bruce!
Today's topic is parabolic and parabolic-ish PCFs. Some folks count sheep trying to fall asleep - others try to come up with setups.
Stay tuned. Will be in touch soon. :)
|
|
Registered User Joined: 1/28/2005 Posts: 6,049
|
QUOTE (Bruce_L)
The basic idea is pretty much the same as in the Divergence between Price and MACD Histogram topic, but things can be a lot shorter using nested IIF() functions than with MACD, because we are looking for the pivot high in price instead of the MACD Histogram.
MAXH2 < H2 AND H2 > MAXH2.3 AND WRSI21.2 > 70 AND H2 / H22 < IIF(MAXH2.3 < H5 AND H5 > MAXH2.6, IIF(H2 > H5, C5 / C25, 0), IIF(MAXH2.4 < H6 AND H6 > MAXH2.7, IIF(H2 > H6, C6 / C26, 0), IIF(MAXH2.5 < H7 AND H7 > MAXH2.8, IIF(H2 > H7, C7 / C27, 0), IIF(MAXH2.6 < H8 AND H8 > MAXH2.9, IIF(H2 > H8, C8 / C28, 0), IIF(MAXH2.7 < H9 AND H9 > MAXH2.10, IIF(H2 > H9, C9 / C29, 0), IIF(MAXH2.8 < H10 AND H10 > MAXH2.11, IIF(H2 > H10, C10 / C30, 0), IIF(MAXH2.9 < H11 AND H11 > MAXH2.12, IIF(H2 > H11, C11 / C31, 0), IIF(MAXH2.10 < H12 AND H12 > MAXH2.13, IIF(H2 > H12, C12 / C32, 0), IIF(MAXH2.11 < H13 AND H13 > MAXH2.14, IIF(H2 > H13, C13 / C33, 0), IIF(MAXH2.12 < H14 AND H14 > MAXH2.15, IIF(H2 > H14, C14 / C34, 0), IIF(MAXH2.13 < H15 AND H15 > MAXH2.16, IIF(H2 > H15, C15 / C35, 0), IIF(MAXH2.14 < H16 AND H16 > MAXH2.17, IIF(H2 > H16, C16 / C36, 0), IIF(MAXH2.15 < H17 AND H17 > MAXH2.18, IIF(H2 > H17, C17 / C37, 0), IIF(MAXH2.16 < H18 AND H18 > MAXH2.19, IIF(H2 > H18, C18 / C38, 0), IIF(MAXH2.17 < H19 AND H19 > MAXH2.20, IIF(H2 > H19, C19 / C39, 0), IIF(MAXH2.18 < H20 AND H20 > MAXH2.21, IIF(H2 > H20, C20 / C40, 0), IIF(MAXH2.19 < H21 AND H21 > MAXH2.22, IIF(H2 > H21, C21 / C41, 0), IIF(MAXH2.20 < H22 AND H22 > MAXH2.23, IIF(H2 > H22, C22 / C42, 0), IIF(MAXH2.21 < H23 AND H23 > MAXH2.24, IIF(H2 > H23, C23 / C43, 0), IIF(MAXH2.22 < H24 AND H24 > MAXH2.25, IIF(H2 > H24, C24 / C44, 0), IIF(MAXH2.23 < H25 AND H25 > MAXH2.26, IIF(H2 > H25, C25 / C45, 0), IIF(MAXH2.24 < H26 AND H26 > MAXH2.27, IIF(H2 > H26, C26 / C46, 0), IIF(MAXH2.25 < H27 AND H27 > MAXH2.28, IIF(H2 > H27, C27 / C47, 0), IIF(MAXH2.26 < H28 AND H28 > MAXH2.29, IIF(H2 > H28, C28 / C48, 0), IIF(MAXH2.27 < H29 AND H29 > MAXH2.30, IIF(H2 > H29, C29 / C49, 0), IIF(MAXH2.28 < H30 AND H30 > MAXH2.31, IIF(H2 > H30, C30 / C50, 0), IIF(MAXH2.29 < H31 AND H31 > MAXH2.32, IIF(H2 > H31, C31 / C51, 0), IIF(MAXH2.30 < H32 AND H32 > MAXH2.33, IIF(H2 > H32, C32 / C52, 0), IIF(MAXH2.31 < H33 AND H33 > MAXH2.34, IIF(H2 > H33, C33 / C53, 0), IIF(MAXH2.32 < H34 AND H34 > MAXH2.35, IIF(H2 > H34, C34 / C54, 0), IIF(MAXH2.33 < H35 AND H35 > MAXH2.36, IIF(H2 > H35, C35 / C55, 0), IIF(MAXH2.34 < H36 AND H36 > MAXH2.37, IIF(H2 > H36, C36 / C56, 0), IIF(MAXH2.35 < H37 AND H37 > MAXH2.38, IIF(H2 > H37, C37 / C57, 0), IIF(MAXH2.36 < H38 AND H38 > MAXH2.39, IIF(H2 > H38, C38 / C58, 0), IIF(MAXH2.37 < H39 AND H39 > MAXH2.40, IIF(H2 > H39, C39 / C59, 0), IIF(MAXH2.38 < H40 AND H40 > MAXH2.41, IIF(H2 > H40, C40 / C60, 0), IIF(MAXH2.39 < H41 AND H41 > MAXH2.42, IIF(H2 > H41, C41 / C61, 0), IIF(MAXH2.40 < H42 AND H42 > MAXH2.43, IIF(H2 > H42, C42 / C62, 0), IIF(MAXH2.41 < H43 AND H43 > MAXH2.44, IIF(H2 > H43, C43 / C63, 0), IIF(MAXH2.42 < H44 AND H44 > MAXH2.45, IIF(H2 > H44, C44 / C64, 0), IIF(MAXH2.43 < H45 AND H45 > MAXH2.46, IIF(H2 > H45, C45 / C65, 0), IIF(MAXH2.44 < H46 AND H46 > MAXH2.47, IIF(H2 > H46, C46 / C66, 0), IIF(MAXH2.45 < H47 AND H47 > MAXH2.48, IIF(H2 > H47, C47 / C67, 0), IIF(MAXH2.46 < H48 AND H48 > MAXH2.49, IIF(H2 > H48, C48 / C68, 0), IIF(MAXH2.47 < H49 AND H49 > MAXH2.50, IIF(H2 > H49, C49 / C69, 0), IIF(MAXH2.48 < H50 AND H50 > MAXH2.51, IIF(H2 > H50, C50 / C70, 0), IIF(MAXH2.49 < H51 AND H51 > MAXH2.52, IIF(H2 > H51, C51 / C71, 0), IIF(MAXH2.50 < H52 AND H52 > MAXH2.53, IIF(H2 > H52, C52 / C72, 0), IIF(MAXH2.51 < H53 AND H53 > MAXH2.54, IIF(H2 > H53, C53 / C73, 0), IIF(MAXH2.52 < H54 AND H54 > MAXH2.55, IIF(H2 > H54, C54 / C74, 0), 0))))))))))))))))))))))))))))))))))))))))))))))))))
Can youi make the inverse of that. (Long version)
Thanks
|
|
Worden Trainer
Joined: 10/7/2004 Posts: 65,138
|
I think the long version of the formula with the WRSI in it would be the following.
MINL2 > L2 AND L2 < MINL2.3 AND WRSI21.2 < 30 AND L2 / L22 > IIF(MINL2.3 > L5 AND L5 < MINL2.6, IIF(L2 < L5, C5 / C25, 0), IIF(MINL2.4 > L6 AND L6 < MINL2.7, IIF(L2 < L6, C6 / C26, 0), IIF(MINL2.5 > L7 AND L7 < MINL2.8, IIF(L2 < L7, C7 / C27, 0), IIF(MINL2.6 > L8 AND L8 < MINL2.9, IIF(L2 < L8, C8 / C28, 0), IIF(MINL2.7 > L9 AND L9 < MINL2.10, IIF(L2 < L9, C9 / C29, 0), IIF(MINL2.8 > L10 AND L10 < MINL2.11, IIF(L2 < L10, C10 / C30, 0), IIF(MINL2.9 > L11 AND L11 < MINL2.12, IIF(L2 < L11, C11 / C31, 0), IIF(MINL2.10 > L12 AND L12 < MINL2.13, IIF(L2 < L12, C12 / C32, 0), IIF(MINL2.11 > L13 AND L13 < MINL2.14, IIF(L2 < L13, C13 / C33, 0), IIF(MINL2.12 > L14 AND L14 < MINL2.15, IIF(L2 < L14, C14 / C34, 0), IIF(MINL2.13 > L15 AND L15 < MINL2.16, IIF(L2 < L15, C15 / C35, 0), IIF(MINL2.14 > L16 AND L16 < MINL2.17, IIF(L2 < L16, C16 / C36, 0), IIF(MINL2.15 > L17 AND L17 < MINL2.18, IIF(L2 < L17, C17 / C37, 0), IIF(MINL2.16 > L18 AND L18 < MINL2.19, IIF(L2 < L18, C18 / C38, 0), IIF(MINL2.17 > L19 AND L19 < MINL2.20, IIF(L2 < L19, C19 / C39, 0), IIF(MINL2.18 > L20 AND L20 < MINL2.21, IIF(L2 < L20, C20 / C40, 0), IIF(MINL2.19 > L21 AND L21 < MINL2.22, IIF(L2 < L21, C21 / C41, 0), IIF(MINL2.20 > L22 AND L22 < MINL2.23, IIF(L2 < L22, C22 / C42, 0), IIF(MINL2.21 > L23 AND L23 < MINL2.24, IIF(L2 < L23, C23 / C43, 0), IIF(MINL2.22 > L24 AND L24 < MINL2.25, IIF(L2 < L24, C24 / C44, 0), IIF(MINL2.23 > L25 AND L25 < MINL2.26, IIF(L2 < L25, C25 / C45, 0), IIF(MINL2.24 > L26 AND L26 < MINL2.27, IIF(L2 < L26, C26 / C46, 0), IIF(MINL2.25 > L27 AND L27 < MINL2.28, IIF(L2 < L27, C27 / C47, 0), IIF(MINL2.26 > L28 AND L28 < MINL2.29, IIF(L2 < L28, C28 / C48, 0), IIF(MINL2.27 > L29 AND L29 < MINL2.30, IIF(L2 < L29, C29 / C49, 0), IIF(MINL2.28 > L30 AND L30 < MINL2.31, IIF(L2 < L30, C30 / C50, 0), IIF(MINL2.29 > L31 AND L31 < MINL2.32, IIF(L2 < L31, C31 / C51, 0), IIF(MINL2.30 > L32 AND L32 < MINL2.33, IIF(L2 < L32, C32 / C52, 0), IIF(MINL2.31 > L33 AND L33 < MINL2.34, IIF(L2 < L33, C33 / C53, 0), IIF(MINL2.32 > L34 AND L34 < MINL2.35, IIF(L2 < L34, C34 / C54, 0), IIF(MINL2.33 > L35 AND L35 < MINL2.36, IIF(L2 < L35, C35 / C55, 0), IIF(MINL2.34 > L36 AND L36 < MINL2.37, IIF(L2 < L36, C36 / C56, 0), IIF(MINL2.35 > L37 AND L37 < MINL2.38, IIF(L2 < L37, C37 / C57, 0), IIF(MINL2.36 > L38 AND L38 < MINL2.39, IIF(L2 < L38, C38 / C58, 0), IIF(MINL2.37 > L39 AND L39 < MINL2.40, IIF(L2 < L39, C39 / C59, 0), IIF(MINL2.38 > L40 AND L40 < MINL2.41, IIF(L2 < L40, C40 / C60, 0), IIF(MINL2.39 > L41 AND L41 < MINL2.42, IIF(L2 < L41, C41 / C61, 0), IIF(MINL2.40 > L42 AND L42 < MINL2.43, IIF(L2 < L42, C42 / C62, 0), IIF(MINL2.41 > L43 AND L43 < MINL2.44, IIF(L2 < L43, C43 / C63, 0), IIF(MINL2.42 > L44 AND L44 < MINL2.45, IIF(L2 < L44, C44 / C64, 0), IIF(MINL2.43 > L45 AND L45 < MINL2.46, IIF(L2 < L45, C45 / C65, 0), IIF(MINL2.44 > L46 AND L46 < MINL2.47, IIF(L2 < L46, C46 / C66, 0), IIF(MINL2.45 > L47 AND L47 < MINL2.48, IIF(L2 < L47, C47 / C67, 0), IIF(MINL2.46 > L48 AND L48 < MINL2.49, IIF(L2 < L48, C48 / C68, 0), IIF(MINL2.47 > L49 AND L49 < MINL2.50, IIF(L2 < L49, C49 / C69, 0), IIF(MINL2.48 > L50 AND L50 < MINL2.51, IIF(L2 < L50, C50 / C70, 0), IIF(MINL2.49 > L51 AND L51 < MINL2.52, IIF(L2 < L51, C51 / C71, 0), IIF(MINL2.50 > L52 AND L52 < MINL2.53, IIF(L2 < L52, C52 / C72, 0), IIF(MINL2.51 > L53 AND L53 < MINL2.54, IIF(L2 < L53, C53 / C73, 0), IIF(MINL2.52 > L54 AND L54 < MINL2.55, IIF(L2 < L54, C54 / C74, 0), 0))))))))))))))))))))))))))))))))))))))))))))))))))
-Bruce Personal Criteria Formulas TC2000 Support Articles
|
|
Registered User Joined: 9/7/2014 Posts: 36
|
Formula for "option days till expiration" between 30-60 days
|
|
Worden Trainer
Joined: 10/7/2004 Posts: 65,138
|
You can include fundamentals or options data in a Personal Criteria Formula.
What you can do is add Option Days Till Expiration as a WatchList Column in an Option Chain window to show this values for each of the available options.
-Bruce Personal Criteria Formulas TC2000 Support Articles
|
|
Guest-1 |