Download software Tutorial videos
Subscription & data-feed pricing Class schedule


New account application Trading resources
Margin rates Stock & option commissions

Attention: Discussion forums are read-only for extended maintenance until further notice.
Welcome Guest, please sign in to participate in a discussion. Search | Active Topics |

Swing PCF Topic Rating:
Previous Topic · Next Topic Watch this topic · Print this topic ·
dhirenshah
Posted : Wednesday, May 17, 2017 3:36:38 PM
Registered User
Joined: 3/10/2012
Posts: 465

Hey Bruce 

i need help to create a pcf please 

for swing low i use this L13 * ABS(MINL13 > L13 AND L13 < MINL13.14)  and for swing high i use this H13 * ABS(MAXH13 < H13 AND H13 > MAXH13.14)

 

so the pcf i want to create is that current low within last 5 bars is touching or in between  0.618 or  0.786 from the swing low to swing high when a fib retracement is drawn , 

is there a way to do the pcf ?? 

example is JACK "  on daily chart and swing low was april 18th and swing high was may 05th and low touching 0.786 was may 15th 

hope that helps 

Regards

Bruce_L
Posted : Wednesday, May 17, 2017 4:45:31 PM


Worden Trainer

Joined: 10/7/2004
Posts: 65,138

I really can't think of a good way to write this. A basic template would be something like the following.

A Condition Formula for this happening during the current bar might be possible in TC2000 v17 (both the swing high and swing low need to have been identified with the most recent 50 bars).

ABS(L - .298 * IIF(MAXH13 < H13 AND H13 > MAXH13.14, H13, IIF(MAXH13.1 < H14 AND H14 > MAXH13.15, H14, IIF(MAXH13.2 < H15 AND H15 > MAXH13.16, H15, IIF(MAXH13.3 < H16 AND H16 > MAXH13.17, H16, IIF(MAXH13.4 < H17 AND H17 > MAXH13.18, H17, IIF(MAXH13.5 < H18 AND H18 > MAXH13.19, H18, IIF(MAXH13.6 < H19 AND H19 > MAXH13.20, H19, IIF(MAXH13.7 < H20 AND H20 > MAXH13.21, H20, IIF(MAXH13.8 < H21 AND H21 > MAXH13.22, H21, IIF(MAXH13.9 < H22 AND H22 > MAXH13.23, H22, IIF(MAXH13.10 < H23 AND H23 > MAXH13.24, H23, IIF(MAXH13.11 < H24 AND H24 > MAXH13.25, H24, IIF(MAXH13.12 < H25 AND H25 > MAXH13.26, H25, IIF(MAXH13.13 < H26 AND H26 > MAXH13.27, H26, IIF(MAXH13.14 < H27 AND H27 > MAXH13.28, H27, IIF(MAXH13.15 < H28 AND H28 > MAXH13.29, H28, IIF(MAXH13.16 < H29 AND H29 > MAXH13.30, H29, IIF(MAXH13.17 < H30 AND H30 > MAXH13.31, H30, IIF(MAXH13.18 < H31 AND H31 > MAXH13.32, H31, IIF(MAXH13.19 < H32 AND H32 > MAXH13.33, H32, IIF(MAXH13.20 < H33 AND H33 > MAXH13.34, H33, IIF(MAXH13.21 < H34 AND H34 > MAXH13.35, H34, IIF(MAXH13.22 < H35 AND H35 > MAXH13.36, H35, IIF(MAXH13.23 < H36 AND H36 > MAXH13.37, H36, IIF(MAXH13.24 < H37 AND H37 > MAXH13.38, H37, IIF(MAXH13.25 < H38 AND H38 > MAXH13.39, H38, IIF(MAXH13.26 < H39 AND H39 > MAXH13.40, H39, IIF(MAXH13.27 < H40 AND H40 > MAXH13.41, H40, IIF(MAXH13.28 < H41 AND H41 > MAXH13.42, H41, IIF(MAXH13.29 < H42 AND H42 > MAXH13.43, H42, IIF(MAXH13.30 < H43 AND H43 > MAXH13.44, H43, IIF(MAXH13.31 < H44 AND H44 > MAXH13.45, H44, IIF(MAXH13.32 < H45 AND H45 > MAXH13.46, H45, IIF(MAXH13.33 < H46 AND H46 > MAXH13.47, H46, IIF(MAXH13.34 < H47 AND H47 > MAXH13.48, H47, IIF(MAXH13.35 < H48 AND H48 > MAXH13.49, H48, IIF(MAXH13.36 < H49 AND H49 > MAXH13.50, H49, IIF(MAXH13.37 < H50 AND H50 > MAXH13.51, H50, IIF(MAXH13.38 < H51 AND H51 > MAXH13.52, H51, IIF(MAXH13.39 < H52 AND H52 > MAXH13.53, H52, IIF(MAXH13.40 < H53 AND H53 > MAXH13.54, H53, IIF(MAXH13.41 < H54 AND H54 > MAXH13.55, H54, IIF(MAXH13.42 < H55 AND H55 > MAXH13.56, H55, IIF(MAXH13.43 < H56 AND H56 > MAXH13.57, H56, IIF(MAXH13.44 < H57 AND H57 > MAXH13.58, H57, IIF(MAXH13.45 < H58 AND H58 > MAXH13.59, H58, IIF(MAXH13.46 < H59 AND H59 > MAXH13.60, H59, IIF(MAXH13.47 < H60 AND H60 > MAXH13.61, H60, IIF(MAXH13.48 < H61 AND H61 > MAXH13.62, H61, IIF(MAXH13.49 < H62 AND H62 > MAXH13.63, H62, 1/0)))))))))))))))))))))))))))))))))))))))))))))))))) - .702 * IIF(MINL13 > L13 AND L13 < MINL13.14, L13, IIF(MINL13.1 > L14 AND L14 < MINL13.15, L14, IIF(MINL13.2 > L15 AND L15 < MINL13.16, L15, IIF(MINL13.3 > L16 AND L16 < MINL13.17, L16, IIF(MINL13.4 > L17 AND L17 < MINL13.18, L17, IIF(MINL13.5 > L18 AND L18 < MINL13.19, L18, IIF(MINL13.6 > L19 AND L19 < MINL13.20, L19, IIF(MINL13.7 > L20 AND L20 < MINL13.21, L20, IIF(MINL13.8 > L21 AND L21 < MINL13.22, L21, IIF(MINL13.9 > L22 AND L22 < MINL13.23, L22, IIF(MINL13.10 > L23 AND L23 < MINL13.24, L23, IIF(MINL13.11 > L24 AND L24 < MINL13.25, L24, IIF(MINL13.12 > L25 AND L25 < MINL13.26, L25, IIF(MINL13.13 > L26 AND L26 < MINL13.27, L26, IIF(MINL13.14 > L27 AND L27 < MINL13.28, L27, IIF(MINL13.15 > L28 AND L28 < MINL13.29, L28, IIF(MINL13.16 > L29 AND L29 < MINL13.30, L29, IIF(MINL13.17 > L30 AND L30 < MINL13.31, L30, IIF(MINL13.18 > L31 AND L31 < MINL13.32, L31, IIF(MINL13.19 > L32 AND L32 < MINL13.33, L32, IIF(MINL13.20 > L33 AND L33 < MINL13.34, L33, IIF(MINL13.21 > L34 AND L34 < MINL13.35, L34, IIF(MINL13.22 > L35 AND L35 < MINL13.36, L35, IIF(MINL13.23 > L36 AND L36 < MINL13.37, L36, IIF(MINL13.24 > L37 AND L37 < MINL13.38, L37, IIF(MINL13.25 > L38 AND L38 < MINL13.39, L38, IIF(MINL13.26 > L39 AND L39 < MINL13.40, L39, IIF(MINL13.27 > L40 AND L40 < MINL13.41, L40, IIF(MINL13.28 > L41 AND L41 < MINL13.42, L41, IIF(MINL13.29 > L42 AND L42 < MINL13.43, L42, IIF(MINL13.30 > L43 AND L43 < MINL13.44, L43, IIF(MINL13.31 > L44 AND L44 < MINL13.45, L44, IIF(MINL13.32 > L45 AND L45 < MINL13.46, L45, IIF(MINL13.33 > L46 AND L46 < MINL13.47, L46, IIF(MINL13.34 > L47 AND L47 < MINL13.48, L47, IIF(MINL13.35 > L48 AND L48 < MINL13.49, L48, IIF(MINL13.36 > L49 AND L49 < MINL13.50, L49, IIF(MINL13.37 > L50 AND L50 < MINL13.51, L50, IIF(MINL13.38 > L51 AND L51 < MINL13.52, L51, IIF(MINL13.39 > L52 AND L52 < MINL13.53, L52, IIF(MINL13.40 > L53 AND L53 < MINL13.54, L53, IIF(MINL13.41 > L54 AND L54 < MINL13.55, L54, IIF(MINL13.42 > L55 AND L55 < MINL13.56, L55, IIF(MINL13.43 > L56 AND L56 < MINL13.57, L56, IIF(MINL13.44 > L57 AND L57 < MINL13.58, L57, IIF(MINL13.45 > L58 AND L58 < MINL13.59, L58, IIF(MINL13.46 > L59 AND L59 < MINL13.60, L59, IIF(MINL13.47 > L60 AND L60 < MINL13.61, L60, IIF(MINL13.48 > L61 AND L61 < MINL13.62, L61, IIF(MINL13.49 > L62 AND L62 < MINL13.63, L62, 1/0))))))))))))))))))))))))))))))))))))))))))))))))))) <= .084 * (IIF(MAXH13 < H13 AND H13 > MAXH13.14, H13, IIF(MAXH13.1 < H14 AND H14 > MAXH13.15, H14, IIF(MAXH13.2 < H15 AND H15 > MAXH13.16, H15, IIF(MAXH13.3 < H16 AND H16 > MAXH13.17, H16, IIF(MAXH13.4 < H17 AND H17 > MAXH13.18, H17, IIF(MAXH13.5 < H18 AND H18 > MAXH13.19, H18, IIF(MAXH13.6 < H19 AND H19 > MAXH13.20, H19, IIF(MAXH13.7 < H20 AND H20 > MAXH13.21, H20, IIF(MAXH13.8 < H21 AND H21 > MAXH13.22, H21, IIF(MAXH13.9 < H22 AND H22 > MAXH13.23, H22, IIF(MAXH13.10 < H23 AND H23 > MAXH13.24, H23, IIF(MAXH13.11 < H24 AND H24 > MAXH13.25, H24, IIF(MAXH13.12 < H25 AND H25 > MAXH13.26, H25, IIF(MAXH13.13 < H26 AND H26 > MAXH13.27, H26, IIF(MAXH13.14 < H27 AND H27 > MAXH13.28, H27, IIF(MAXH13.15 < H28 AND H28 > MAXH13.29, H28, IIF(MAXH13.16 < H29 AND H29 > MAXH13.30, H29, IIF(MAXH13.17 < H30 AND H30 > MAXH13.31, H30, IIF(MAXH13.18 < H31 AND H31 > MAXH13.32, H31, IIF(MAXH13.19 < H32 AND H32 > MAXH13.33, H32, IIF(MAXH13.20 < H33 AND H33 > MAXH13.34, H33, IIF(MAXH13.21 < H34 AND H34 > MAXH13.35, H34, IIF(MAXH13.22 < H35 AND H35 > MAXH13.36, H35, IIF(MAXH13.23 < H36 AND H36 > MAXH13.37, H36, IIF(MAXH13.24 < H37 AND H37 > MAXH13.38, H37, IIF(MAXH13.25 < H38 AND H38 > MAXH13.39, H38, IIF(MAXH13.26 < H39 AND H39 > MAXH13.40, H39, IIF(MAXH13.27 < H40 AND H40 > MAXH13.41, H40, IIF(MAXH13.28 < H41 AND H41 > MAXH13.42, H41, IIF(MAXH13.29 < H42 AND H42 > MAXH13.43, H42, IIF(MAXH13.30 < H43 AND H43 > MAXH13.44, H43, IIF(MAXH13.31 < H44 AND H44 > MAXH13.45, H44, IIF(MAXH13.32 < H45 AND H45 > MAXH13.46, H45, IIF(MAXH13.33 < H46 AND H46 > MAXH13.47, H46, IIF(MAXH13.34 < H47 AND H47 > MAXH13.48, H47, IIF(MAXH13.35 < H48 AND H48 > MAXH13.49, H48, IIF(MAXH13.36 < H49 AND H49 > MAXH13.50, H49, IIF(MAXH13.37 < H50 AND H50 > MAXH13.51, H50, IIF(MAXH13.38 < H51 AND H51 > MAXH13.52, H51, IIF(MAXH13.39 < H52 AND H52 > MAXH13.53, H52, IIF(MAXH13.40 < H53 AND H53 > MAXH13.54, H53, IIF(MAXH13.41 < H54 AND H54 > MAXH13.55, H54, IIF(MAXH13.42 < H55 AND H55 > MAXH13.56, H55, IIF(MAXH13.43 < H56 AND H56 > MAXH13.57, H56, IIF(MAXH13.44 < H57 AND H57 > MAXH13.58, H57, IIF(MAXH13.45 < H58 AND H58 > MAXH13.59, H58, IIF(MAXH13.46 < H59 AND H59 > MAXH13.60, H59, IIF(MAXH13.47 < H60 AND H60 > MAXH13.61, H60, IIF(MAXH13.48 < H61 AND H61 > MAXH13.62, H61, IIF(MAXH13.49 < H62 AND H62 > MAXH13.63, H62, 1/0)))))))))))))))))))))))))))))))))))))))))))))))))) - IIF(MINL13 > L13 AND L13 < MINL13.14, L13, IIF(MINL13.1 > L14 AND L14 < MINL13.15, L14, IIF(MINL13.2 > L15 AND L15 < MINL13.16, L15, IIF(MINL13.3 > L16 AND L16 < MINL13.17, L16, IIF(MINL13.4 > L17 AND L17 < MINL13.18, L17, IIF(MINL13.5 > L18 AND L18 < MINL13.19, L18, IIF(MINL13.6 > L19 AND L19 < MINL13.20, L19, IIF(MINL13.7 > L20 AND L20 < MINL13.21, L20, IIF(MINL13.8 > L21 AND L21 < MINL13.22, L21, IIF(MINL13.9 > L22 AND L22 < MINL13.23, L22, IIF(MINL13.10 > L23 AND L23 < MINL13.24, L23, IIF(MINL13.11 > L24 AND L24 < MINL13.25, L24, IIF(MINL13.12 > L25 AND L25 < MINL13.26, L25, IIF(MINL13.13 > L26 AND L26 < MINL13.27, L26, IIF(MINL13.14 > L27 AND L27 < MINL13.28, L27, IIF(MINL13.15 > L28 AND L28 < MINL13.29, L28, IIF(MINL13.16 > L29 AND L29 < MINL13.30, L29, IIF(MINL13.17 > L30 AND L30 < MINL13.31, L30, IIF(MINL13.18 > L31 AND L31 < MINL13.32, L31, IIF(MINL13.19 > L32 AND L32 < MINL13.33, L32, IIF(MINL13.20 > L33 AND L33 < MINL13.34, L33, IIF(MINL13.21 > L34 AND L34 < MINL13.35, L34, IIF(MINL13.22 > L35 AND L35 < MINL13.36, L35, IIF(MINL13.23 > L36 AND L36 < MINL13.37, L36, IIF(MINL13.24 > L37 AND L37 < MINL13.38, L37, IIF(MINL13.25 > L38 AND L38 < MINL13.39, L38, IIF(MINL13.26 > L39 AND L39 < MINL13.40, L39, IIF(MINL13.27 > L40 AND L40 < MINL13.41, L40, IIF(MINL13.28 > L41 AND L41 < MINL13.42, L41, IIF(MINL13.29 > L42 AND L42 < MINL13.43, L42, IIF(MINL13.30 > L43 AND L43 < MINL13.44, L43, IIF(MINL13.31 > L44 AND L44 < MINL13.45, L44, IIF(MINL13.32 > L45 AND L45 < MINL13.46, L45, IIF(MINL13.33 > L46 AND L46 < MINL13.47, L46, IIF(MINL13.34 > L47 AND L47 < MINL13.48, L47, IIF(MINL13.35 > L48 AND L48 < MINL13.49, L48, IIF(MINL13.36 > L49 AND L49 < MINL13.50, L49, IIF(MINL13.37 > L50 AND L50 < MINL13.51, L50, IIF(MINL13.38 > L51 AND L51 < MINL13.52, L51, IIF(MINL13.39 > L52 AND L52 < MINL13.53, L52, IIF(MINL13.40 > L53 AND L53 < MINL13.54, L53, IIF(MINL13.41 > L54 AND L54 < MINL13.55, L54, IIF(MINL13.42 > L55 AND L55 < MINL13.56, L55, IIF(MINL13.43 > L56 AND L56 < MINL13.57, L56, IIF(MINL13.44 > L57 AND L57 < MINL13.58, L57, IIF(MINL13.45 > L58 AND L58 < MINL13.59, L58, IIF(MINL13.46 > L59 AND L59 < MINL13.60, L59, IIF(MINL13.47 > L60 AND L60 < MINL13.61, L60, IIF(MINL13.48 > L61 AND L61 < MINL13.62, L61, IIF(MINL13.49 > L62 AND L62 < MINL13.63, L62, 1/0)))))))))))))))))))))))))))))))))))))))))))))))))))

But checking if this happened during any of the most recent 5 bars would result in a formula which is too long and slow to be practical.



-Bruce
Personal Criteria Formulas
TC2000 Support Articles
dhirenshah
Posted : Thursday, May 18, 2017 3:18:21 AM
Registered User
Joined: 3/10/2012
Posts: 465

Ouch Bruce ,that;s one heck of a formula... i can't even think of coding this one ,didn't realize that pcf will have to go this long,,,, but your pcf gives me results that i can eyeball and work around.thanks a lot-

could you please do one more for the same logic - but this time current price low is touching or between 0.382 and 50% when fib retracement is drawn from swing low to swing high and it is necessary that current CLOSE cannot go below 50%  of the swing low to swing high retracement  thats where i need pcf to be true , also in some cases swing high may not have been formed with 13 bars since the retracement is shallow so emphasis will be more on to using 13 bar  swing low  for sure to be complete with most recent high for retacement of current low to rest in area of 0.382 - 50% - like incase of "Jack "swing low was complete but swing high did not have 13 bars yet to mark it as a 13 bar swing high, 

 

And last question on this topic if possible -

 i want to find out where is the current price low in relation to 13 bar swing low in terms of ratio , so how to do that ?

Cheers :)

Bruce_L
Posted : Thursday, May 18, 2017 10:46:54 AM


Worden Trainer

Joined: 10/7/2004
Posts: 65,138

I can't make a formula which just guesses at how many bars to use for the swing high. The formula uses the most recent 13 bar swing high for its calculations.

Also based on the example given in your previous request, you had wanted the 0.618 or 0.786 to be near the bottom of the range. If that was true, then the 0.382 to 0.500 will be near the top of the range. If the low is in the top half of the range, then the close will be as well.

We can substitute .559 for .298 (the midpoint of the range), .441 for .702 (1 - midpoint), and .059 for .084 (half the width of the range) to convert the original formula to the new formula.

ABS(L - .559 * IIF(MAXH13 < H13 AND H13 > MAXH13.14, H13, IIF(MAXH13.1 < H14 AND H14 > MAXH13.15, H14, IIF(MAXH13.2 < H15 AND H15 > MAXH13.16, H15, IIF(MAXH13.3 < H16 AND H16 > MAXH13.17, H16, IIF(MAXH13.4 < H17 AND H17 > MAXH13.18, H17, IIF(MAXH13.5 < H18 AND H18 > MAXH13.19, H18, IIF(MAXH13.6 < H19 AND H19 > MAXH13.20, H19, IIF(MAXH13.7 < H20 AND H20 > MAXH13.21, H20, IIF(MAXH13.8 < H21 AND H21 > MAXH13.22, H21, IIF(MAXH13.9 < H22 AND H22 > MAXH13.23, H22, IIF(MAXH13.10 < H23 AND H23 > MAXH13.24, H23, IIF(MAXH13.11 < H24 AND H24 > MAXH13.25, H24, IIF(MAXH13.12 < H25 AND H25 > MAXH13.26, H25, IIF(MAXH13.13 < H26 AND H26 > MAXH13.27, H26, IIF(MAXH13.14 < H27 AND H27 > MAXH13.28, H27, IIF(MAXH13.15 < H28 AND H28 > MAXH13.29, H28, IIF(MAXH13.16 < H29 AND H29 > MAXH13.30, H29, IIF(MAXH13.17 < H30 AND H30 > MAXH13.31, H30, IIF(MAXH13.18 < H31 AND H31 > MAXH13.32, H31, IIF(MAXH13.19 < H32 AND H32 > MAXH13.33, H32, IIF(MAXH13.20 < H33 AND H33 > MAXH13.34, H33, IIF(MAXH13.21 < H34 AND H34 > MAXH13.35, H34, IIF(MAXH13.22 < H35 AND H35 > MAXH13.36, H35, IIF(MAXH13.23 < H36 AND H36 > MAXH13.37, H36, IIF(MAXH13.24 < H37 AND H37 > MAXH13.38, H37, IIF(MAXH13.25 < H38 AND H38 > MAXH13.39, H38, IIF(MAXH13.26 < H39 AND H39 > MAXH13.40, H39, IIF(MAXH13.27 < H40 AND H40 > MAXH13.41, H40, IIF(MAXH13.28 < H41 AND H41 > MAXH13.42, H41, IIF(MAXH13.29 < H42 AND H42 > MAXH13.43, H42, IIF(MAXH13.30 < H43 AND H43 > MAXH13.44, H43, IIF(MAXH13.31 < H44 AND H44 > MAXH13.45, H44, IIF(MAXH13.32 < H45 AND H45 > MAXH13.46, H45, IIF(MAXH13.33 < H46 AND H46 > MAXH13.47, H46, IIF(MAXH13.34 < H47 AND H47 > MAXH13.48, H47, IIF(MAXH13.35 < H48 AND H48 > MAXH13.49, H48, IIF(MAXH13.36 < H49 AND H49 > MAXH13.50, H49, IIF(MAXH13.37 < H50 AND H50 > MAXH13.51, H50, IIF(MAXH13.38 < H51 AND H51 > MAXH13.52, H51, IIF(MAXH13.39 < H52 AND H52 > MAXH13.53, H52, IIF(MAXH13.40 < H53 AND H53 > MAXH13.54, H53, IIF(MAXH13.41 < H54 AND H54 > MAXH13.55, H54, IIF(MAXH13.42 < H55 AND H55 > MAXH13.56, H55, IIF(MAXH13.43 < H56 AND H56 > MAXH13.57, H56, IIF(MAXH13.44 < H57 AND H57 > MAXH13.58, H57, IIF(MAXH13.45 < H58 AND H58 > MAXH13.59, H58, IIF(MAXH13.46 < H59 AND H59 > MAXH13.60, H59, IIF(MAXH13.47 < H60 AND H60 > MAXH13.61, H60, IIF(MAXH13.48 < H61 AND H61 > MAXH13.62, H61, IIF(MAXH13.49 < H62 AND H62 > MAXH13.63, H62, 1/0)))))))))))))))))))))))))))))))))))))))))))))))))) - .441 * IIF(MINL13 > L13 AND L13 < MINL13.14, L13, IIF(MINL13.1 > L14 AND L14 < MINL13.15, L14, IIF(MINL13.2 > L15 AND L15 < MINL13.16, L15, IIF(MINL13.3 > L16 AND L16 < MINL13.17, L16, IIF(MINL13.4 > L17 AND L17 < MINL13.18, L17, IIF(MINL13.5 > L18 AND L18 < MINL13.19, L18, IIF(MINL13.6 > L19 AND L19 < MINL13.20, L19, IIF(MINL13.7 > L20 AND L20 < MINL13.21, L20, IIF(MINL13.8 > L21 AND L21 < MINL13.22, L21, IIF(MINL13.9 > L22 AND L22 < MINL13.23, L22, IIF(MINL13.10 > L23 AND L23 < MINL13.24, L23, IIF(MINL13.11 > L24 AND L24 < MINL13.25, L24, IIF(MINL13.12 > L25 AND L25 < MINL13.26, L25, IIF(MINL13.13 > L26 AND L26 < MINL13.27, L26, IIF(MINL13.14 > L27 AND L27 < MINL13.28, L27, IIF(MINL13.15 > L28 AND L28 < MINL13.29, L28, IIF(MINL13.16 > L29 AND L29 < MINL13.30, L29, IIF(MINL13.17 > L30 AND L30 < MINL13.31, L30, IIF(MINL13.18 > L31 AND L31 < MINL13.32, L31, IIF(MINL13.19 > L32 AND L32 < MINL13.33, L32, IIF(MINL13.20 > L33 AND L33 < MINL13.34, L33, IIF(MINL13.21 > L34 AND L34 < MINL13.35, L34, IIF(MINL13.22 > L35 AND L35 < MINL13.36, L35, IIF(MINL13.23 > L36 AND L36 < MINL13.37, L36, IIF(MINL13.24 > L37 AND L37 < MINL13.38, L37, IIF(MINL13.25 > L38 AND L38 < MINL13.39, L38, IIF(MINL13.26 > L39 AND L39 < MINL13.40, L39, IIF(MINL13.27 > L40 AND L40 < MINL13.41, L40, IIF(MINL13.28 > L41 AND L41 < MINL13.42, L41, IIF(MINL13.29 > L42 AND L42 < MINL13.43, L42, IIF(MINL13.30 > L43 AND L43 < MINL13.44, L43, IIF(MINL13.31 > L44 AND L44 < MINL13.45, L44, IIF(MINL13.32 > L45 AND L45 < MINL13.46, L45, IIF(MINL13.33 > L46 AND L46 < MINL13.47, L46, IIF(MINL13.34 > L47 AND L47 < MINL13.48, L47, IIF(MINL13.35 > L48 AND L48 < MINL13.49, L48, IIF(MINL13.36 > L49 AND L49 < MINL13.50, L49, IIF(MINL13.37 > L50 AND L50 < MINL13.51, L50, IIF(MINL13.38 > L51 AND L51 < MINL13.52, L51, IIF(MINL13.39 > L52 AND L52 < MINL13.53, L52, IIF(MINL13.40 > L53 AND L53 < MINL13.54, L53, IIF(MINL13.41 > L54 AND L54 < MINL13.55, L54, IIF(MINL13.42 > L55 AND L55 < MINL13.56, L55, IIF(MINL13.43 > L56 AND L56 < MINL13.57, L56, IIF(MINL13.44 > L57 AND L57 < MINL13.58, L57, IIF(MINL13.45 > L58 AND L58 < MINL13.59, L58, IIF(MINL13.46 > L59 AND L59 < MINL13.60, L59, IIF(MINL13.47 > L60 AND L60 < MINL13.61, L60, IIF(MINL13.48 > L61 AND L61 < MINL13.62, L61, IIF(MINL13.49 > L62 AND L62 < MINL13.63, L62, 1/0))))))))))))))))))))))))))))))))))))))))))))))))))) <= .059 * (IIF(MAXH13 < H13 AND H13 > MAXH13.14, H13, IIF(MAXH13.1 < H14 AND H14 > MAXH13.15, H14, IIF(MAXH13.2 < H15 AND H15 > MAXH13.16, H15, IIF(MAXH13.3 < H16 AND H16 > MAXH13.17, H16, IIF(MAXH13.4 < H17 AND H17 > MAXH13.18, H17, IIF(MAXH13.5 < H18 AND H18 > MAXH13.19, H18, IIF(MAXH13.6 < H19 AND H19 > MAXH13.20, H19, IIF(MAXH13.7 < H20 AND H20 > MAXH13.21, H20, IIF(MAXH13.8 < H21 AND H21 > MAXH13.22, H21, IIF(MAXH13.9 < H22 AND H22 > MAXH13.23, H22, IIF(MAXH13.10 < H23 AND H23 > MAXH13.24, H23, IIF(MAXH13.11 < H24 AND H24 > MAXH13.25, H24, IIF(MAXH13.12 < H25 AND H25 > MAXH13.26, H25, IIF(MAXH13.13 < H26 AND H26 > MAXH13.27, H26, IIF(MAXH13.14 < H27 AND H27 > MAXH13.28, H27, IIF(MAXH13.15 < H28 AND H28 > MAXH13.29, H28, IIF(MAXH13.16 < H29 AND H29 > MAXH13.30, H29, IIF(MAXH13.17 < H30 AND H30 > MAXH13.31, H30, IIF(MAXH13.18 < H31 AND H31 > MAXH13.32, H31, IIF(MAXH13.19 < H32 AND H32 > MAXH13.33, H32, IIF(MAXH13.20 < H33 AND H33 > MAXH13.34, H33, IIF(MAXH13.21 < H34 AND H34 > MAXH13.35, H34, IIF(MAXH13.22 < H35 AND H35 > MAXH13.36, H35, IIF(MAXH13.23 < H36 AND H36 > MAXH13.37, H36, IIF(MAXH13.24 < H37 AND H37 > MAXH13.38, H37, IIF(MAXH13.25 < H38 AND H38 > MAXH13.39, H38, IIF(MAXH13.26 < H39 AND H39 > MAXH13.40, H39, IIF(MAXH13.27 < H40 AND H40 > MAXH13.41, H40, IIF(MAXH13.28 < H41 AND H41 > MAXH13.42, H41, IIF(MAXH13.29 < H42 AND H42 > MAXH13.43, H42, IIF(MAXH13.30 < H43 AND H43 > MAXH13.44, H43, IIF(MAXH13.31 < H44 AND H44 > MAXH13.45, H44, IIF(MAXH13.32 < H45 AND H45 > MAXH13.46, H45, IIF(MAXH13.33 < H46 AND H46 > MAXH13.47, H46, IIF(MAXH13.34 < H47 AND H47 > MAXH13.48, H47, IIF(MAXH13.35 < H48 AND H48 > MAXH13.49, H48, IIF(MAXH13.36 < H49 AND H49 > MAXH13.50, H49, IIF(MAXH13.37 < H50 AND H50 > MAXH13.51, H50, IIF(MAXH13.38 < H51 AND H51 > MAXH13.52, H51, IIF(MAXH13.39 < H52 AND H52 > MAXH13.53, H52, IIF(MAXH13.40 < H53 AND H53 > MAXH13.54, H53, IIF(MAXH13.41 < H54 AND H54 > MAXH13.55, H54, IIF(MAXH13.42 < H55 AND H55 > MAXH13.56, H55, IIF(MAXH13.43 < H56 AND H56 > MAXH13.57, H56, IIF(MAXH13.44 < H57 AND H57 > MAXH13.58, H57, IIF(MAXH13.45 < H58 AND H58 > MAXH13.59, H58, IIF(MAXH13.46 < H59 AND H59 > MAXH13.60, H59, IIF(MAXH13.47 < H60 AND H60 > MAXH13.61, H60, IIF(MAXH13.48 < H61 AND H61 > MAXH13.62, H61, IIF(MAXH13.49 < H62 AND H62 > MAXH13.63, H62, 1/0)))))))))))))))))))))))))))))))))))))))))))))))))) - IIF(MINL13 > L13 AND L13 < MINL13.14, L13, IIF(MINL13.1 > L14 AND L14 < MINL13.15, L14, IIF(MINL13.2 > L15 AND L15 < MINL13.16, L15, IIF(MINL13.3 > L16 AND L16 < MINL13.17, L16, IIF(MINL13.4 > L17 AND L17 < MINL13.18, L17, IIF(MINL13.5 > L18 AND L18 < MINL13.19, L18, IIF(MINL13.6 > L19 AND L19 < MINL13.20, L19, IIF(MINL13.7 > L20 AND L20 < MINL13.21, L20, IIF(MINL13.8 > L21 AND L21 < MINL13.22, L21, IIF(MINL13.9 > L22 AND L22 < MINL13.23, L22, IIF(MINL13.10 > L23 AND L23 < MINL13.24, L23, IIF(MINL13.11 > L24 AND L24 < MINL13.25, L24, IIF(MINL13.12 > L25 AND L25 < MINL13.26, L25, IIF(MINL13.13 > L26 AND L26 < MINL13.27, L26, IIF(MINL13.14 > L27 AND L27 < MINL13.28, L27, IIF(MINL13.15 > L28 AND L28 < MINL13.29, L28, IIF(MINL13.16 > L29 AND L29 < MINL13.30, L29, IIF(MINL13.17 > L30 AND L30 < MINL13.31, L30, IIF(MINL13.18 > L31 AND L31 < MINL13.32, L31, IIF(MINL13.19 > L32 AND L32 < MINL13.33, L32, IIF(MINL13.20 > L33 AND L33 < MINL13.34, L33, IIF(MINL13.21 > L34 AND L34 < MINL13.35, L34, IIF(MINL13.22 > L35 AND L35 < MINL13.36, L35, IIF(MINL13.23 > L36 AND L36 < MINL13.37, L36, IIF(MINL13.24 > L37 AND L37 < MINL13.38, L37, IIF(MINL13.25 > L38 AND L38 < MINL13.39, L38, IIF(MINL13.26 > L39 AND L39 < MINL13.40, L39, IIF(MINL13.27 > L40 AND L40 < MINL13.41, L40, IIF(MINL13.28 > L41 AND L41 < MINL13.42, L41, IIF(MINL13.29 > L42 AND L42 < MINL13.43, L42, IIF(MINL13.30 > L43 AND L43 < MINL13.44, L43, IIF(MINL13.31 > L44 AND L44 < MINL13.45, L44, IIF(MINL13.32 > L45 AND L45 < MINL13.46, L45, IIF(MINL13.33 > L46 AND L46 < MINL13.47, L46, IIF(MINL13.34 > L47 AND L47 < MINL13.48, L47, IIF(MINL13.35 > L48 AND L48 < MINL13.49, L48, IIF(MINL13.36 > L49 AND L49 < MINL13.50, L49, IIF(MINL13.37 > L50 AND L50 < MINL13.51, L50, IIF(MINL13.38 > L51 AND L51 < MINL13.52, L51, IIF(MINL13.39 > L52 AND L52 < MINL13.53, L52, IIF(MINL13.40 > L53 AND L53 < MINL13.54, L53, IIF(MINL13.41 > L54 AND L54 < MINL13.55, L54, IIF(MINL13.42 > L55 AND L55 < MINL13.56, L55, IIF(MINL13.43 > L56 AND L56 < MINL13.57, L56, IIF(MINL13.44 > L57 AND L57 < MINL13.58, L57, IIF(MINL13.45 > L58 AND L58 < MINL13.59, L58, IIF(MINL13.46 > L59 AND L59 < MINL13.60, L59, IIF(MINL13.47 > L60 AND L60 < MINL13.61, L60, IIF(MINL13.48 > L61 AND L61 < MINL13.62, L61, IIF(MINL13.49 > L62 AND L62 < MINL13.63, L62, 1/0)))))))))))))))))))))))))))))))))))))))))))))))))))

You can switch the first two factors in the formula if the range needs to be close to the swing low instead of close to the swing high (although then it would need a check for the close being in the top half of the range). You can also switch the first two factors in the first formula if it should be near the swing high instead of near the swing low.

I probably should know which direction you actually mean if I am going to write a formula to calculate retracement based on the low of the current bar.



-Bruce
Personal Criteria Formulas
TC2000 Support Articles
dhirenshah
Posted : Thursday, May 18, 2017 11:33:27 AM
Registered User
Joined: 3/10/2012
Posts: 465

Excellent Yes Bruce the formula that you did is correct idea i was looking for 0.382 to 0.50  near the top of the range and good examples are RCL AND HON on daily chart and even FSLR qualifies for this formula idea that i was looking for , they were perfect thanks a lot ,

And your question I probably should know which direction you actually mean if I am going to write a formula to calculate retracement based on the low of the current bar.

so to that context taking example of " ORLY" on daily chart .. where we have clear defined 13 bar swing low and when i draw fib retracement from swing low May 01 2017 to the most recent high on May 15th  the current low of today falls between 50 and 61.8% fib retracement when drawn from 13 bar swing low to recent high  so my specific question was " i want to find out where is the current price low in relation to 13 bar swing low in terms of ratio whether the current low is 51% , 52% ,53% or 58.5% etc i needed that ratio value in number ??

Thanks for all your help

Regards

Bruce_L
Posted : Thursday, May 18, 2017 12:57:20 PM


Worden Trainer

Joined: 10/7/2004
Posts: 65,138

Please try the following Indicator Formula.

100 * (IIF(MAXH13 < H13 AND H13 > MAXH13.14, H13, IIF(MAXH13.1 < H14 AND H14 > MAXH13.15, H14, IIF(MAXH13.2 < H15 AND H15 > MAXH13.16, H15, IIF(MAXH13.3 < H16 AND H16 > MAXH13.17, H16, IIF(MAXH13.4 < H17 AND H17 > MAXH13.18, H17, IIF(MAXH13.5 < H18 AND H18 > MAXH13.19, H18, IIF(MAXH13.6 < H19 AND H19 > MAXH13.20, H19, IIF(MAXH13.7 < H20 AND H20 > MAXH13.21, H20, IIF(MAXH13.8 < H21 AND H21 > MAXH13.22, H21, IIF(MAXH13.9 < H22 AND H22 > MAXH13.23, H22, IIF(MAXH13.10 < H23 AND H23 > MAXH13.24, H23, IIF(MAXH13.11 < H24 AND H24 > MAXH13.25, H24, IIF(MAXH13.12 < H25 AND H25 > MAXH13.26, H25, IIF(MAXH13.13 < H26 AND H26 > MAXH13.27, H26, IIF(MAXH13.14 < H27 AND H27 > MAXH13.28, H27, IIF(MAXH13.15 < H28 AND H28 > MAXH13.29, H28, IIF(MAXH13.16 < H29 AND H29 > MAXH13.30, H29, IIF(MAXH13.17 < H30 AND H30 > MAXH13.31, H30, IIF(MAXH13.18 < H31 AND H31 > MAXH13.32, H31, IIF(MAXH13.19 < H32 AND H32 > MAXH13.33, H32, IIF(MAXH13.20 < H33 AND H33 > MAXH13.34, H33, IIF(MAXH13.21 < H34 AND H34 > MAXH13.35, H34, IIF(MAXH13.22 < H35 AND H35 > MAXH13.36, H35, IIF(MAXH13.23 < H36 AND H36 > MAXH13.37, H36, IIF(MAXH13.24 < H37 AND H37 > MAXH13.38, H37, IIF(MAXH13.25 < H38 AND H38 > MAXH13.39, H38, IIF(MAXH13.26 < H39 AND H39 > MAXH13.40, H39, IIF(MAXH13.27 < H40 AND H40 > MAXH13.41, H40, IIF(MAXH13.28 < H41 AND H41 > MAXH13.42, H41, IIF(MAXH13.29 < H42 AND H42 > MAXH13.43, H42, IIF(MAXH13.30 < H43 AND H43 > MAXH13.44, H43, IIF(MAXH13.31 < H44 AND H44 > MAXH13.45, H44, IIF(MAXH13.32 < H45 AND H45 > MAXH13.46, H45, IIF(MAXH13.33 < H46 AND H46 > MAXH13.47, H46, IIF(MAXH13.34 < H47 AND H47 > MAXH13.48, H47, IIF(MAXH13.35 < H48 AND H48 > MAXH13.49, H48, IIF(MAXH13.36 < H49 AND H49 > MAXH13.50, H49, IIF(MAXH13.37 < H50 AND H50 > MAXH13.51, H50, IIF(MAXH13.38 < H51 AND H51 > MAXH13.52, H51, IIF(MAXH13.39 < H52 AND H52 > MAXH13.53, H52, IIF(MAXH13.40 < H53 AND H53 > MAXH13.54, H53, IIF(MAXH13.41 < H54 AND H54 > MAXH13.55, H54, IIF(MAXH13.42 < H55 AND H55 > MAXH13.56, H55, IIF(MAXH13.43 < H56 AND H56 > MAXH13.57, H56, IIF(MAXH13.44 < H57 AND H57 > MAXH13.58, H57, IIF(MAXH13.45 < H58 AND H58 > MAXH13.59, H58, IIF(MAXH13.46 < H59 AND H59 > MAXH13.60, H59, IIF(MAXH13.47 < H60 AND H60 > MAXH13.61, H60, IIF(MAXH13.48 < H61 AND H61 > MAXH13.62, H61, IIF(MAXH13.49 < H62 AND H62 > MAXH13.63, H62, 1/0)))))))))))))))))))))))))))))))))))))))))))))))))) - L) / (IIF(MAXH13 < H13 AND H13 > MAXH13.14, H13, IIF(MAXH13.1 < H14 AND H14 > MAXH13.15, H14, IIF(MAXH13.2 < H15 AND H15 > MAXH13.16, H15, IIF(MAXH13.3 < H16 AND H16 > MAXH13.17, H16, IIF(MAXH13.4 < H17 AND H17 > MAXH13.18, H17, IIF(MAXH13.5 < H18 AND H18 > MAXH13.19, H18, IIF(MAXH13.6 < H19 AND H19 > MAXH13.20, H19, IIF(MAXH13.7 < H20 AND H20 > MAXH13.21, H20, IIF(MAXH13.8 < H21 AND H21 > MAXH13.22, H21, IIF(MAXH13.9 < H22 AND H22 > MAXH13.23, H22, IIF(MAXH13.10 < H23 AND H23 > MAXH13.24, H23, IIF(MAXH13.11 < H24 AND H24 > MAXH13.25, H24, IIF(MAXH13.12 < H25 AND H25 > MAXH13.26, H25, IIF(MAXH13.13 < H26 AND H26 > MAXH13.27, H26, IIF(MAXH13.14 < H27 AND H27 > MAXH13.28, H27, IIF(MAXH13.15 < H28 AND H28 > MAXH13.29, H28, IIF(MAXH13.16 < H29 AND H29 > MAXH13.30, H29, IIF(MAXH13.17 < H30 AND H30 > MAXH13.31, H30, IIF(MAXH13.18 < H31 AND H31 > MAXH13.32, H31, IIF(MAXH13.19 < H32 AND H32 > MAXH13.33, H32, IIF(MAXH13.20 < H33 AND H33 > MAXH13.34, H33, IIF(MAXH13.21 < H34 AND H34 > MAXH13.35, H34, IIF(MAXH13.22 < H35 AND H35 > MAXH13.36, H35, IIF(MAXH13.23 < H36 AND H36 > MAXH13.37, H36, IIF(MAXH13.24 < H37 AND H37 > MAXH13.38, H37, IIF(MAXH13.25 < H38 AND H38 > MAXH13.39, H38, IIF(MAXH13.26 < H39 AND H39 > MAXH13.40, H39, IIF(MAXH13.27 < H40 AND H40 > MAXH13.41, H40, IIF(MAXH13.28 < H41 AND H41 > MAXH13.42, H41, IIF(MAXH13.29 < H42 AND H42 > MAXH13.43, H42, IIF(MAXH13.30 < H43 AND H43 > MAXH13.44, H43, IIF(MAXH13.31 < H44 AND H44 > MAXH13.45, H44, IIF(MAXH13.32 < H45 AND H45 > MAXH13.46, H45, IIF(MAXH13.33 < H46 AND H46 > MAXH13.47, H46, IIF(MAXH13.34 < H47 AND H47 > MAXH13.48, H47, IIF(MAXH13.35 < H48 AND H48 > MAXH13.49, H48, IIF(MAXH13.36 < H49 AND H49 > MAXH13.50, H49, IIF(MAXH13.37 < H50 AND H50 > MAXH13.51, H50, IIF(MAXH13.38 < H51 AND H51 > MAXH13.52, H51, IIF(MAXH13.39 < H52 AND H52 > MAXH13.53, H52, IIF(MAXH13.40 < H53 AND H53 > MAXH13.54, H53, IIF(MAXH13.41 < H54 AND H54 > MAXH13.55, H54, IIF(MAXH13.42 < H55 AND H55 > MAXH13.56, H55, IIF(MAXH13.43 < H56 AND H56 > MAXH13.57, H56, IIF(MAXH13.44 < H57 AND H57 > MAXH13.58, H57, IIF(MAXH13.45 < H58 AND H58 > MAXH13.59, H58, IIF(MAXH13.46 < H59 AND H59 > MAXH13.60, H59, IIF(MAXH13.47 < H60 AND H60 > MAXH13.61, H60, IIF(MAXH13.48 < H61 AND H61 > MAXH13.62, H61, IIF(MAXH13.49 < H62 AND H62 > MAXH13.63, H62, 1/0)))))))))))))))))))))))))))))))))))))))))))))))))) - IIF(MINL13 > L13 AND L13 < MINL13.14, L13, IIF(MINL13.1 > L14 AND L14 < MINL13.15, L14, IIF(MINL13.2 > L15 AND L15 < MINL13.16, L15, IIF(MINL13.3 > L16 AND L16 < MINL13.17, L16, IIF(MINL13.4 > L17 AND L17 < MINL13.18, L17, IIF(MINL13.5 > L18 AND L18 < MINL13.19, L18, IIF(MINL13.6 > L19 AND L19 < MINL13.20, L19, IIF(MINL13.7 > L20 AND L20 < MINL13.21, L20, IIF(MINL13.8 > L21 AND L21 < MINL13.22, L21, IIF(MINL13.9 > L22 AND L22 < MINL13.23, L22, IIF(MINL13.10 > L23 AND L23 < MINL13.24, L23, IIF(MINL13.11 > L24 AND L24 < MINL13.25, L24, IIF(MINL13.12 > L25 AND L25 < MINL13.26, L25, IIF(MINL13.13 > L26 AND L26 < MINL13.27, L26, IIF(MINL13.14 > L27 AND L27 < MINL13.28, L27, IIF(MINL13.15 > L28 AND L28 < MINL13.29, L28, IIF(MINL13.16 > L29 AND L29 < MINL13.30, L29, IIF(MINL13.17 > L30 AND L30 < MINL13.31, L30, IIF(MINL13.18 > L31 AND L31 < MINL13.32, L31, IIF(MINL13.19 > L32 AND L32 < MINL13.33, L32, IIF(MINL13.20 > L33 AND L33 < MINL13.34, L33, IIF(MINL13.21 > L34 AND L34 < MINL13.35, L34, IIF(MINL13.22 > L35 AND L35 < MINL13.36, L35, IIF(MINL13.23 > L36 AND L36 < MINL13.37, L36, IIF(MINL13.24 > L37 AND L37 < MINL13.38, L37, IIF(MINL13.25 > L38 AND L38 < MINL13.39, L38, IIF(MINL13.26 > L39 AND L39 < MINL13.40, L39, IIF(MINL13.27 > L40 AND L40 < MINL13.41, L40, IIF(MINL13.28 > L41 AND L41 < MINL13.42, L41, IIF(MINL13.29 > L42 AND L42 < MINL13.43, L42, IIF(MINL13.30 > L43 AND L43 < MINL13.44, L43, IIF(MINL13.31 > L44 AND L44 < MINL13.45, L44, IIF(MINL13.32 > L45 AND L45 < MINL13.46, L45, IIF(MINL13.33 > L46 AND L46 < MINL13.47, L46, IIF(MINL13.34 > L47 AND L47 < MINL13.48, L47, IIF(MINL13.35 > L48 AND L48 < MINL13.49, L48, IIF(MINL13.36 > L49 AND L49 < MINL13.50, L49, IIF(MINL13.37 > L50 AND L50 < MINL13.51, L50, IIF(MINL13.38 > L51 AND L51 < MINL13.52, L51, IIF(MINL13.39 > L52 AND L52 < MINL13.53, L52, IIF(MINL13.40 > L53 AND L53 < MINL13.54, L53, IIF(MINL13.41 > L54 AND L54 < MINL13.55, L54, IIF(MINL13.42 > L55 AND L55 < MINL13.56, L55, IIF(MINL13.43 > L56 AND L56 < MINL13.57, L56, IIF(MINL13.44 > L57 AND L57 < MINL13.58, L57, IIF(MINL13.45 > L58 AND L58 < MINL13.59, L58, IIF(MINL13.46 > L59 AND L59 < MINL13.60, L59, IIF(MINL13.47 > L60 AND L60 < MINL13.61, L60, IIF(MINL13.48 > L61 AND L61 < MINL13.62, L61, IIF(MINL13.49 > L62 AND L62 < MINL13.63, L62, 1/0)))))))))))))))))))))))))))))))))))))))))))))))))))



-Bruce
Personal Criteria Formulas
TC2000 Support Articles
dhirenshah
Posted : Thursday, May 18, 2017 1:49:33 PM
Registered User
Joined: 3/10/2012
Posts: 465

Bruce i like the idea what u have done but this is not what i wanted as a final number in output

for example ORLY " on daily custom indicator formula that u did has number as 69.17  but when i draw fib retracement from 13 bar swing low to recent swing  high the current low is i m guessing at 55.02(approx) and your formula gives  69.17 so i wanted the number as 55.02 in my output result(which the fib ratio as where the the current low is resting) -- hope it make sense ?? and not 69.17 so how to fix that and more or less i think u have come very near to the idea ...

Another good example take NFLX on daily where13 bar swing low is April 19th 2017 and most recent high is may 15th 2017 so   current low is just above 38.2 % fib retracement when drawn from swing low to recent high  so my output number in the formula u just did should come out as 37.00 as value for current low $153.24 will match with number 37.00 in fib retracement from swing low to recent high as drawn from low to high ! but ypur formula give it as -51.40 so i don;t know how to fix that !

Sorry for all trouble but this is will give me quick easy way to find where stock is at in terms for fib retracement when i run a sorting list ....

Thanks for being patient and working on with me on this idea...

Bruce_L
Posted : Thursday, May 18, 2017 2:05:55 PM


Worden Trainer

Joined: 10/7/2004
Posts: 65,138

The most recent swing low for ORLY was 239.12 on 5/1/17 and the most recent swing high was  270.10 on 4/24/17. When I connect these points and set one of the lines of the retracement to draw at 69.17, it lines up with today's low.

The most recent swing low for NFLX was in fact 138.66 on 4/19/17, but the most recent identifyable swing high 13 was 148.29 on 3/30/17 and not on 5/15/17 as there have not been 13 lower highs since (and I already pointed out I can't write a formula which just guesses at how many lower highs you want for a swing high or higher lows you want for a swing low). Connecting them and plotting a retracement at -51.40 also lines up with today's low.

If you have some other objective definition you want to use for a swing high 13 than being surrounded on both sides by 13 lower highs or for a swing low 13 than being surrounded on both sides by 13 higher lows, then we could look into creating a formula using that definition instead.



-Bruce
Personal Criteria Formulas
TC2000 Support Articles
dhirenshah
Posted : Thursday, May 18, 2017 2:26:06 PM
Registered User
Joined: 3/10/2012
Posts: 465

Yes Bruce you are absolutely correct on your swing details you mentioned but  fib retracement example what u mentioned on ORLY taking swing low $239.12 and swing high as $270.10 that is because you drawing fib retracement from low to upper left  which has already occured but i m drawing fib retracement from swing low to upper right which is currently occuring ,,, so thats where swing low is defined correctly for both of us as $239.12 and for me the most recent high (not necessarily the 13 bar swinghigh)  but only most recent high was may 15th   $260.31 and todays current low when i m drawing  fib retracement from low of $239.12 to high of $260.31 the current low comes at that number of 55 approx  that is what i want as output in formula ....

 

Same for NFLX  u are correct in identifying swing high of $148.29 because u drawing from low to upper left that is already occured but i m wanting the swing low $138.66 and drawing to most recent high $161.78 happened on MAy 15 2017 and toda'ys current low (153.24) when drawing fib retracement from $ 148.29 to 161.78 comes at number 37.00 so i want that number 37.00 in custom formula

hope it helps ,

thanks

 

Bruce_L
Posted : Thursday, May 18, 2017 2:51:40 PM


Worden Trainer

Joined: 10/7/2004
Posts: 65,138

So if I am understanding this correctly, we only need to identify the swing low 13 and we don't have to try and identify the swing high at all. All we do is use the highest high since the swing low (excluding the bar of the swing low).

100 * (IIF(MINL13 > L13 AND L13 < MINL13.14, MAXH13, IIF(MINL13.1 > L14 AND L14 < MINL13.15, MAXH14, IIF(MINL13.2 > L15 AND L15 < MINL13.16, MAXH15, IIF(MINL13.3 > L16 AND L16 < MINL13.17, MAXH16, IIF(MINL13.4 > L17 AND L17 < MINL13.18, MAXH17, IIF(MINL13.5 > L18 AND L18 < MINL13.19, MAXH18, IIF(MINL13.6 > L19 AND L19 < MINL13.20, MAXH19, IIF(MINL13.7 > L20 AND L20 < MINL13.21, MAXH20, IIF(MINL13.8 > L21 AND L21 < MINL13.22, MAXH21, IIF(MINL13.9 > L22 AND L22 < MINL13.23, MAXH22, IIF(MINL13.10 > L23 AND L23 < MINL13.24, MAXH23, IIF(MINL13.11 > L24 AND L24 < MINL13.25, MAXH24, IIF(MINL13.12 > L25 AND L25 < MINL13.26, MAXH25, IIF(MINL13.13 > L26 AND L26 < MINL13.27, MAXH26, IIF(MINL13.14 > L27 AND L27 < MINL13.28, MAXH27, IIF(MINL13.15 > L28 AND L28 < MINL13.29, MAXH28, IIF(MINL13.16 > L29 AND L29 < MINL13.30, MAXH29, IIF(MINL13.17 > L30 AND L30 < MINL13.31, MAXH30, IIF(MINL13.18 > L31 AND L31 < MINL13.32, MAXH31, IIF(MINL13.19 > L32 AND L32 < MINL13.33, MAXH32, IIF(MINL13.20 > L33 AND L33 < MINL13.34, MAXH33, IIF(MINL13.21 > L34 AND L34 < MINL13.35, MAXH34, IIF(MINL13.22 > L35 AND L35 < MINL13.36, MAXH35, IIF(MINL13.23 > L36 AND L36 < MINL13.37, MAXH36, IIF(MINL13.24 > L37 AND L37 < MINL13.38, MAXH37, IIF(MINL13.25 > L38 AND L38 < MINL13.39, MAXH38, IIF(MINL13.26 > L39 AND L39 < MINL13.40, MAXH39, IIF(MINL13.27 > L40 AND L40 < MINL13.41, MAXH40, IIF(MINL13.28 > L41 AND L41 < MINL13.42, MAXH41, IIF(MINL13.29 > L42 AND L42 < MINL13.43, MAXH42, IIF(MINL13.30 > L43 AND L43 < MINL13.44, MAXH43, IIF(MINL13.31 > L44 AND L44 < MINL13.45, MAXH44, IIF(MINL13.32 > L45 AND L45 < MINL13.46, MAXH45, IIF(MINL13.33 > L46 AND L46 < MINL13.47, MAXH46, IIF(MINL13.34 > L47 AND L47 < MINL13.48, MAXH47, IIF(MINL13.35 > L48 AND L48 < MINL13.49, MAXH48, IIF(MINL13.36 > L49 AND L49 < MINL13.50, MAXH49, IIF(MINL13.37 > L50 AND L50 < MINL13.51, MAXH50, IIF(MINL13.38 > L51 AND L51 < MINL13.52, MAXH51, IIF(MINL13.39 > L52 AND L52 < MINL13.53, MAXH52, IIF(MINL13.40 > L53 AND L53 < MINL13.54, MAXH53, IIF(MINL13.41 > L54 AND L54 < MINL13.55, MAXH54, IIF(MINL13.42 > L55 AND L55 < MINL13.56, MAXH55, IIF(MINL13.43 > L56 AND L56 < MINL13.57, MAXH56, IIF(MINL13.44 > L57 AND L57 < MINL13.58, MAXH57, IIF(MINL13.45 > L58 AND L58 < MINL13.59, MAXH58, IIF(MINL13.46 > L59 AND L59 < MINL13.60, MAXH59, IIF(MINL13.47 > L60 AND L60 < MINL13.61, MAXH60, IIF(MINL13.48 > L61 AND L61 < MINL13.62, MAXH61, IIF(MINL13.49 > L62 AND L62 < MINL13.63, MAXH62, 1/0)))))))))))))))))))))))))))))))))))))))))))))))))) - L) / IIF(MINL13 > L13 AND L13 < MINL13.14, MAXH13 - L13, IIF(MINL13.1 > L14 AND L14 < MINL13.15, MAXH14 - L14, IIF(MINL13.2 > L15 AND L15 < MINL13.16, MAXH15 - L15, IIF(MINL13.3 > L16 AND L16 < MINL13.17, MAXH16 - L16, IIF(MINL13.4 > L17 AND L17 < MINL13.18, MAXH17 - L17, IIF(MINL13.5 > L18 AND L18 < MINL13.19, MAXH18 - L18, IIF(MINL13.6 > L19 AND L19 < MINL13.20, MAXH19 - L19, IIF(MINL13.7 > L20 AND L20 < MINL13.21, MAXH20 - L20, IIF(MINL13.8 > L21 AND L21 < MINL13.22, MAXH21 - L21, IIF(MINL13.9 > L22 AND L22 < MINL13.23, MAXH22 - L22, IIF(MINL13.10 > L23 AND L23 < MINL13.24, MAXH23 - L23, IIF(MINL13.11 > L24 AND L24 < MINL13.25, MAXH24 - L24, IIF(MINL13.12 > L25 AND L25 < MINL13.26, MAXH25 - L25, IIF(MINL13.13 > L26 AND L26 < MINL13.27, MAXH26 - L26, IIF(MINL13.14 > L27 AND L27 < MINL13.28, MAXH27 - L27, IIF(MINL13.15 > L28 AND L28 < MINL13.29, MAXH28 - L28, IIF(MINL13.16 > L29 AND L29 < MINL13.30, MAXH29 - L29, IIF(MINL13.17 > L30 AND L30 < MINL13.31, MAXH30 - L30, IIF(MINL13.18 > L31 AND L31 < MINL13.32, MAXH31 - L31, IIF(MINL13.19 > L32 AND L32 < MINL13.33, MAXH32 - L32, IIF(MINL13.20 > L33 AND L33 < MINL13.34, MAXH33 - L33, IIF(MINL13.21 > L34 AND L34 < MINL13.35, MAXH34 - L34, IIF(MINL13.22 > L35 AND L35 < MINL13.36, MAXH35 - L35, IIF(MINL13.23 > L36 AND L36 < MINL13.37, MAXH36 - L36, IIF(MINL13.24 > L37 AND L37 < MINL13.38, MAXH37 - L37, IIF(MINL13.25 > L38 AND L38 < MINL13.39, MAXH38 - L38, IIF(MINL13.26 > L39 AND L39 < MINL13.40, MAXH39 - L39, IIF(MINL13.27 > L40 AND L40 < MINL13.41, MAXH40 - L40, IIF(MINL13.28 > L41 AND L41 < MINL13.42, MAXH41 - L41, IIF(MINL13.29 > L42 AND L42 < MINL13.43, MAXH42 - L42, IIF(MINL13.30 > L43 AND L43 < MINL13.44, MAXH43 - L43, IIF(MINL13.31 > L44 AND L44 < MINL13.45, MAXH44 - L44, IIF(MINL13.32 > L45 AND L45 < MINL13.46, MAXH45 - L45, IIF(MINL13.33 > L46 AND L46 < MINL13.47, MAXH46 - L46, IIF(MINL13.34 > L47 AND L47 < MINL13.48, MAXH47 - L47, IIF(MINL13.35 > L48 AND L48 < MINL13.49, MAXH48 - L48, IIF(MINL13.36 > L49 AND L49 < MINL13.50, MAXH49 - L49, IIF(MINL13.37 > L50 AND L50 < MINL13.51, MAXH50 - L50, IIF(MINL13.38 > L51 AND L51 < MINL13.52, MAXH51 - L51, IIF(MINL13.39 > L52 AND L52 < MINL13.53, MAXH52 - L52, IIF(MINL13.40 > L53 AND L53 < MINL13.54, MAXH53 - L53, IIF(MINL13.41 > L54 AND L54 < MINL13.55, MAXH54 - L54, IIF(MINL13.42 > L55 AND L55 < MINL13.56, MAXH55 - L55, IIF(MINL13.43 > L56 AND L56 < MINL13.57, MAXH56 - L56, IIF(MINL13.44 > L57 AND L57 < MINL13.58, MAXH57 - L57, IIF(MINL13.45 > L58 AND L58 < MINL13.59, MAXH58 - L58, IIF(MINL13.46 > L59 AND L59 < MINL13.60, MAXH59 - L59, IIF(MINL13.47 > L60 AND L60 < MINL13.61, MAXH60 - L60, IIF(MINL13.48 > L61 AND L61 < MINL13.62, MAXH61 - L61, IIF(MINL13.49 > L62 AND L62 < MINL13.63, MAXH62 - L62, 1/0))))))))))))))))))))))))))))))))))))))))))))))))))



-Bruce
Personal Criteria Formulas
TC2000 Support Articles
dhirenshah
Posted : Thursday, May 18, 2017 3:03:46 PM
Registered User
Joined: 3/10/2012
Posts: 465

BRUCE BRUCE BRUCE you da Man !

that is exactly what i wanted - you don;t know but u just computed complex harmonic patterns .... i m deeply thankful to u ... i asked u about this few years back and at that time i didn't have a good way back testing but now u make it look everything simple on chart !

TCmail me your Hamptons address and I will send you bucket of goodies  !:))

thanks a lot again brother

Cheers!

Dhiren

dhirenshah
Posted : Friday, July 14, 2017 3:29:51 AM
Registered User
Joined: 3/10/2012
Posts: 465

hi Bruce 

couple of months back you worked a formula for me in swing low and it works perfect, and now i need it in swing high as below parameters please

1)  i want pcf to find out where is the current price high in relation to 13 bar swing high in terms of fib ratio , i use H13 * ABS(MAXH13 < H13 AND H13 > MAXH13.14)   for swing high

2)we only need to identify most recent swing high 13 and we don't have to try and identify the swing low at all. All we do is use the lowest low since the swing high (excluding the bar of the swing high) and drawing retracement from SWING HIGH TO LOWER RIGHT for lowest low 

example "AAPL" on daily chart as 13 bar swing high on JUNE 07, 2017, So when drawing retracement from swing high to the lowest low (lower right ) is june 16,2017 and based on that the  current high of july 13,2017 is output result as 46.10(approx) so i need that number as PCF 

Thanks a lot 

Dhiren

Bruce_L
Posted : Friday, July 14, 2017 12:41:24 PM


Worden Trainer

Joined: 10/7/2004
Posts: 65,138

Please try the following.

100 * (IIF(MAXH13 < H13 AND H13 > MAXH13.14, MINL13, IIF(MAXH13.1 < H14 AND H14 > MAXH13.15, MINL14, IIF(MAXH13.2 < H15 AND H15 > MAXH13.16, MINL15, IIF(MAXH13.3 < H16 AND H16 > MAXH13.17, MINL16, IIF(MAXH13.4 < H17 AND H17 > MAXH13.18, MINL17, IIF(MAXH13.5 < H18 AND H18 > MAXH13.19, MINL18, IIF(MAXH13.6 < H19 AND H19 > MAXH13.20, MINL19, IIF(MAXH13.7 < H20 AND H20 > MAXH13.21, MINL20, IIF(MAXH13.8 < H21 AND H21 > MAXH13.22, MINL21, IIF(MAXH13.9 < H22 AND H22 > MAXH13.23, MINL22, IIF(MAXH13.10 < H23 AND H23 > MAXH13.24, MINL23, IIF(MAXH13.11 < H24 AND H24 > MAXH13.25, MINL24, IIF(MAXH13.12 < H25 AND H25 > MAXH13.26, MINL25, IIF(MAXH13.13 < H26 AND H26 > MAXH13.27, MINL26, IIF(MAXH13.14 < H27 AND H27 > MAXH13.28, MINL27, IIF(MAXH13.15 < H28 AND H28 > MAXH13.29, MINL28, IIF(MAXH13.16 < H29 AND H29 > MAXH13.30, MINL29, IIF(MAXH13.17 < H30 AND H30 > MAXH13.31, MINL30, IIF(MAXH13.18 < H31 AND H31 > MAXH13.32, MINL31, IIF(MAXH13.19 < H32 AND H32 > MAXH13.33, MINL32, IIF(MAXH13.20 < H33 AND H33 > MAXH13.34, MINL33, IIF(MAXH13.21 < H34 AND H34 > MAXH13.35, MINL34, IIF(MAXH13.22 < H35 AND H35 > MAXH13.36, MINL35, IIF(MAXH13.23 < H36 AND H36 > MAXH13.37, MINL36, IIF(MAXH13.24 < H37 AND H37 > MAXH13.38, MINL37, IIF(MAXH13.25 < H38 AND H38 > MAXH13.39, MINL38, IIF(MAXH13.26 < H39 AND H39 > MAXH13.40, MINL39, IIF(MAXH13.27 < H40 AND H40 > MAXH13.41, MINL40, IIF(MAXH13.28 < H41 AND H41 > MAXH13.42, MINL41, IIF(MAXH13.29 < H42 AND H42 > MAXH13.43, MINL42, IIF(MAXH13.30 < H43 AND H43 > MAXH13.44, MINL43, IIF(MAXH13.31 < H44 AND H44 > MAXH13.45, MINL44, IIF(MAXH13.32 < H45 AND H45 > MAXH13.46, MINL45, IIF(MAXH13.33 < H46 AND H46 > MAXH13.47, MINL46, IIF(MAXH13.34 < H47 AND H47 > MAXH13.48, MINL47, IIF(MAXH13.35 < H48 AND H48 > MAXH13.49, MINL48, IIF(MAXH13.36 < H49 AND H49 > MAXH13.50, MINL49, IIF(MAXH13.37 < H50 AND H50 > MAXH13.51, MINL50, IIF(MAXH13.38 < H51 AND H51 > MAXH13.52, MINL51, IIF(MAXH13.39 < H52 AND H52 > MAXH13.53, MINL52, IIF(MAXH13.40 < H53 AND H53 > MAXH13.54, MINL53, IIF(MAXH13.41 < H54 AND H54 > MAXH13.55, MINL54, IIF(MAXH13.42 < H55 AND H55 > MAXH13.56, MINL55, IIF(MAXH13.43 < H56 AND H56 > MAXH13.57, MINL56, IIF(MAXH13.44 < H57 AND H57 > MAXH13.58, MINL57, IIF(MAXH13.45 < H58 AND H58 > MAXH13.59, MINL58, IIF(MAXH13.46 < H59 AND H59 > MAXH13.60, MINL59, IIF(MAXH13.47 < H60 AND H60 > MAXH13.61, MINL60, IIF(MAXH13.48 < H61 AND H61 > MAXH13.62, MINL61, IIF(MAXH13.49 < H62 AND H62 > MAXH13.63, MINL62, 1/0)))))))))))))))))))))))))))))))))))))))))))))))))) - H) / IIF(MAXH13 < H13 AND H13 > MAXH13.14, MINL13 - H13, IIF(MAXH13.1 < H14 AND H14 > MAXH13.15, MINL14 - H14, IIF(MAXH13.2 < H15 AND H15 > MAXH13.16, MINL15 - H15, IIF(MAXH13.3 < H16 AND H16 > MAXH13.17, MINL16 - H16, IIF(MAXH13.4 < H17 AND H17 > MAXH13.18, MINL17 - H17, IIF(MAXH13.5 < H18 AND H18 > MAXH13.19, MINL18 - H18, IIF(MAXH13.6 < H19 AND H19 > MAXH13.20, MINL19 - H19, IIF(MAXH13.7 < H20 AND H20 > MAXH13.21, MINL20 - H20, IIF(MAXH13.8 < H21 AND H21 > MAXH13.22, MINL21 - H21, IIF(MAXH13.9 < H22 AND H22 > MAXH13.23, MINL22 - H22, IIF(MAXH13.10 < H23 AND H23 > MAXH13.24, MINL23 - H23, IIF(MAXH13.11 < H24 AND H24 > MAXH13.25, MINL24 - H24, IIF(MAXH13.12 < H25 AND H25 > MAXH13.26, MINL25 - H25, IIF(MAXH13.13 < H26 AND H26 > MAXH13.27, MINL26 - H26, IIF(MAXH13.14 < H27 AND H27 > MAXH13.28, MINL27 - H27, IIF(MAXH13.15 < H28 AND H28 > MAXH13.29, MINL28 - H28, IIF(MAXH13.16 < H29 AND H29 > MAXH13.30, MINL29 - H29, IIF(MAXH13.17 < H30 AND H30 > MAXH13.31, MINL30 - H30, IIF(MAXH13.18 < H31 AND H31 > MAXH13.32, MINL31 - H31, IIF(MAXH13.19 < H32 AND H32 > MAXH13.33, MINL32 - H32, IIF(MAXH13.20 < H33 AND H33 > MAXH13.34, MINL33 - H33, IIF(MAXH13.21 < H34 AND H34 > MAXH13.35, MINL34 - H34, IIF(MAXH13.22 < H35 AND H35 > MAXH13.36, MINL35 - H35, IIF(MAXH13.23 < H36 AND H36 > MAXH13.37, MINL36 - H36, IIF(MAXH13.24 < H37 AND H37 > MAXH13.38, MINL37 - H37, IIF(MAXH13.25 < H38 AND H38 > MAXH13.39, MINL38 - H38, IIF(MAXH13.26 < H39 AND H39 > MAXH13.40, MINL39 - H39, IIF(MAXH13.27 < H40 AND H40 > MAXH13.41, MINL40 - H40, IIF(MAXH13.28 < H41 AND H41 > MAXH13.42, MINL41 - H41, IIF(MAXH13.29 < H42 AND H42 > MAXH13.43, MINL42 - H42, IIF(MAXH13.30 < H43 AND H43 > MAXH13.44, MINL43 - H43, IIF(MAXH13.31 < H44 AND H44 > MAXH13.45, MINL44 - H44, IIF(MAXH13.32 < H45 AND H45 > MAXH13.46, MINL45 - H45, IIF(MAXH13.33 < H46 AND H46 > MAXH13.47, MINL46 - H46, IIF(MAXH13.34 < H47 AND H47 > MAXH13.48, MINL47 - H47, IIF(MAXH13.35 < H48 AND H48 > MAXH13.49, MINL48 - H48, IIF(MAXH13.36 < H49 AND H49 > MAXH13.50, MINL49 - H49, IIF(MAXH13.37 < H50 AND H50 > MAXH13.51, MINL50 - H50, IIF(MAXH13.38 < H51 AND H51 > MAXH13.52, MINL51 - H51, IIF(MAXH13.39 < H52 AND H52 > MAXH13.53, MINL52 - H52, IIF(MAXH13.40 < H53 AND H53 > MAXH13.54, MINL53 - H53, IIF(MAXH13.41 < H54 AND H54 > MAXH13.55, MINL54 - H54, IIF(MAXH13.42 < H55 AND H55 > MAXH13.56, MINL55 - H55, IIF(MAXH13.43 < H56 AND H56 > MAXH13.57, MINL56 - H56, IIF(MAXH13.44 < H57 AND H57 > MAXH13.58, MINL57 - H57, IIF(MAXH13.45 < H58 AND H58 > MAXH13.59, MINL58 - H58, IIF(MAXH13.46 < H59 AND H59 > MAXH13.60, MINL59 - H59, IIF(MAXH13.47 < H60 AND H60 > MAXH13.61, MINL60 - H60, IIF(MAXH13.48 < H61 AND H61 > MAXH13.62, MINL61 - H61, IIF(MAXH13.49 < H62 AND H62 > MAXH13.63, MINL62 - H62, 1/0))))))))))))))))))))))))))))))))))))))))))))))))))



-Bruce
Personal Criteria Formulas
TC2000 Support Articles
dhirenshah
Posted : Friday, July 14, 2017 1:17:58 PM
Registered User
Joined: 3/10/2012
Posts: 465

Thankyou very much Bruce 

 

that works perfect 

 

Cheers

Dhiren

dhirenshah
Posted : Friday, July 28, 2017 3:07:29 PM
Registered User
Joined: 3/10/2012
Posts: 465

Hi Bruce 

Could u please compute your formula on Friday, July 14, 2017 12:41:24 PM 

for 5 bar swing high  i use H2 * ABS(H < H2 AND H1 < H2 AND H2 > H3 AND H2 > H4) 

 

and if u can please compute your pcf Thursday, May 18, 2017 2:51:40 PM

for 5 bar swing low i use L2 * ABS(L > L1 AND L1 > L2 AND L2 < L3 AND L3 < L4) 

 

I m having trouble getting around it..

 

thanks 

Dhiren

Bruce_L
Posted : Friday, July 28, 2017 3:55:50 PM


Worden Trainer

Joined: 10/7/2004
Posts: 65,138

If that is your "5 bar swing high", then the previous formulas are for a 27 bar swing high and not a 13 bar swing high. The old formulas used 13 bars both before and after the central bar having lower highs (for a swing high) or higher lows (for a swing low). The new count uses the total span in bars from the beginning to the end of the pattern as the count for the length of the swing high.

The old formulas also use a different technique than at least one of the new formulas in that the central bar only needs to be higher than the 13 bars before and after the central bar to be a swing high. Your new technique in defining the swing high matches this technique, but the swing low seems to require 2 lower lows in a row followed by 2 higher lows in a row and does not match your algorithm for the swing high.

Do you know how you want to count the length of the swing high and swing low?

Do you need to have the original formulas re-written to be 13 bar swing highs and lows based on the counting method presented in your most recent posts?

Do you just need the central bar to have a higher high and the other bars or the central bar to have a lower low than the other bars, or do you need the consecutive inceases and decreases in the lows or highs as seems to be done in your newest swing low formula?



-Bruce
Personal Criteria Formulas
TC2000 Support Articles
dhirenshah
Posted : Friday, July 28, 2017 4:56:15 PM
Registered User
Joined: 3/10/2012
Posts: 465

Bruce i m not sure how to answer your question 

but lets take an example of what i want from this idea to work 

i want when current close to be above my 5 bar formula of swing high (H2 * ABS(H < H2 AND H1 < H2 AND H2 > H3 AND H2 > H4)   then the output result should have a value of 100.01

example "BA " on Daily chart has swing high(my pcf as above) on june 26 2017 so on  July 11,2017 price closed above that swing high point and thats what i need in output result as +100.01

 

and for same for swing low example "TBPH" my pcf L2 * ABS(L > L1 AND L1 > L2 AND L2 < L3 AND L3 < L4)  had swing low at june 15, 2017 on daily and price closed below  swing low on July 25,2017 so thats where the result output should have  -100.01

 

 

and while we are on this topic could please compute same idea of 5 bar swings as u did for 13 bar swings having 5 bars both before and after the central bar having lower highs (for a swing high) or higher lows (for a swing low).

thanks  a lot 

dhirenshah
Posted : Saturday, July 29, 2017 12:48:04 AM
Registered User
Joined: 3/10/2012
Posts: 465

Bruce sorry a little tweak to add onto the pcf after doing a little test work i want when current close happens to be above my 5 bar formula of swing high (H2 * ABS(H < H2 AND H1 < H2 AND H2 > H3 AND H2 > H4)  and the swing high has to be is above EMA21(HLC) and current close is above EMA 21 ONLY  then the output result should have a value of 100.01 or else it should not show anything ... 

EXAMPLE NFLX " ON 195 min CHART AS SWING HIGH is  june 26,2017 bar 12.45 pm , and next swing high that qualifies the criteria is July 13,2017 andboth are above EMA21(HLC) but i would like to only accept JULY 13,2017 SWING HIGH AS current price on july 14,2017 4.00 pm bar  crossing up and close above was the closest to that swing high of july 13,2017 12.45 pm bar  so i will discount the previous swing high and pcf should only use most recent swing high closest to the current price..

Another Example FSLR " on daily chart when swing high happend on June 28,2017 it was above EMA 21(HLC) AND ANOTHER SWING HIGH happened july 03 ,2017  NOTE : THEY ARE CLOSE TO EACH OTHER so i will discount (june 28,2017 swing high and use data of most recent swing high of July 03, so my interest on pcf is on JULY 12,2017 when it crossed above the JULY 03,2017 SWING HIGH AND CLOSED I hope i was able to explain clearly...

And same thing for inverse where swing low happened below EMA21(HLC) FROM THE EXAMPLE OF TBPH DAILY AND CLOSE HAPPEND JULY 25,2017 BUT BELOW EMA 21(HLC)

ANOTHER example of swing low on 30 min chart on " WIX" IF YOU NOTE SWING LOW HAPPENED JULY 27,2017 BELOW EMA21(HLC)  AND PRICE TO THE RIGHT CURRENT BAR JULY 27,2017 1.00 PM BAR CLOSED BELOW SWING LOW AND CLOSE WAS BELOW EMA21(HLC) thats where the PCF SHOULD RESULT -100.01

I can see all these manually and took trades based on them but i want to Automate this idea... i have never seen you disappoint anyone so this would be a piece of pie for GENIUS like you, 

Cheers  have good weekend ...

Bruce_L
Posted : Monday, July 31, 2017 1:02:36 PM


Worden Trainer

Joined: 10/7/2004
Posts: 65,138

Hopefully I am misunderstanding what you want, because the longest lookback which is fast enough to post in the forums only goes out to 13 bars for the swing high.

IIF(MAXH2 < H2 AND H2 > MAXH2.3 AND 3 * H2 > XAVG(H2 + L2 + C2, 21) AND 3 * C > XAVG(H + L + C, 21) H2, IIF(MAXH2.1 < H3 AND H3 > MAXH2.4 AND 3 * H3 > XAVG(H3 + L3 + C3, 21) AND 3 * C1 > XAVG(H1 + L1 + C1, 21), H3, IIF(MAXH2.2 < H4 AND H4 > MAXH2.5 AND 3 * H4 > XAVG(H4 + L4 + C4, 21) AND 3 * C2 > XAVG(H2 + L2 + C2, 21), H4, IIF(MAXH2.3 < H5 AND H5 > MAXH2.6 AND 3 * H5 > XAVG(H5 + L5 + C5, 21) AND 3 * C3 > XAVG(H3 + L3 + C3, 21), H5, IIF(MAXH2.4 < H6 AND H6 > MAXH2.7 AND 3 * H6 > XAVG(H6 + L6 + C6, 21) AND 3 * C4 > XAVG(H4 + L4 + C4, 21), H6, IIF(MAXH2.5 < H7 AND H7 > MAXH2.8 AND 3 * H7 > XAVG(H7 + L7 + C7, 21) AND 3 * C5 > XAVG(H5 + L5 + C5, 21), H7, IIF(MAXH2.6 < H8 AND H8 > MAXH2.9 AND 3 * H8 > XAVG(H8 + L8 + C8, 21) AND 3 * C6 > XAVG(H6 + L6 + C6, 21), H8, IIF(MAXH2.7 < H9 AND H9 > MAXH2.10 AND 3 * H9 > XAVG(H9 + L9 + C9, 21) AND 3 * C7 > XAVG(H7 + L7 + C7, 21), H9, IIF(MAXH2.8 < H10 AND H10 > MAXH2.11 AND 3 * H10 > XAVG(H10 + L10 + C10, 21) AND 3 * C8 > XAVG(H8 + L8 + C8, 21), H10, IIF(MAXH2.9 < H11 AND H11 > MAXH2.12 AND 3 * H11 > XAVG(H11 + L11 + C11, 21) AND 3 * C9 > XAVG(H9 + L9 + C9, 21), H11, IIF(MAXH2.10 < H12 AND H12 > MAXH2.13 AND 3 * H12 > XAVG(H12 + L12 + C12, 21) AND 3 * C10 > XAVG(H10 + L10 + C10, 21), H12, IIF(MAXH2.11 < H13 AND H13 > MAXH2.14 AND 3 * H13 > XAVG(H13 + L13 + C13, 21) AND 3 * C11 > XAVG(H11 + L11 + C11, 21), H13, 1 / 0))))))))))))

And the same for the swing low.

IIF(MINL2 > L2 AND L2 < MINL2.3 AND 3 * L2 < XAVG(L2 + L2 + C2, 21) AND 3 * C < XAVG(L + L + C, 21), L2, IIF(MINL2.1 > L3 AND L3 < MINL2.4 AND 3 * L3 < XAVG(L3 + L3 + C3, 21) AND 3 * C1 < XAVG(L1 + L1 + C1, 21), L3, IIF(MINL2.2 > L4 AND L4 < MINL2.5 AND 3 * L4 < XAVG(L4 + L4 + C4, 21) AND 3 * C2 < XAVG(L2 + L2 + C2, 21), L4, IIF(MINL2.3 > L5 AND L5 < MINL2.6 AND 3 * L5 < XAVG(L5 + L5 + C5, 21) AND 3 * C3 < XAVG(L3 + L3 + C3, 21), L5, IIF(MINL2.4 > L6 AND L6 < MINL2.7 AND 3 * L6 < XAVG(L6 + L6 + C6, 21) AND 3 * C4 < XAVG(L4 + L4 + C4, 21), L6, IIF(MINL2.5 > L7 AND L7 < MINL2.8 AND 3 * L7 < XAVG(L7 + L7 + C7, 21) AND 3 * C5 < XAVG(L5 + L5 + C5, 21), L7, IIF(MINL2.6 > L8 AND L8 < MINL2.9 AND 3 * L8 < XAVG(L8 + L8 + C8, 21) AND 3 * C6 < XAVG(L6 + L6 + C6, 21), L8, IIF(MINL2.7 > L9 AND L9 < MINL2.10 AND 3 * L9 < XAVG(L9 + L9 + C9, 21) AND 3 * C7 < XAVG(L7 + L7 + C7, 21), L9, IIF(MINL2.8 > L10 AND L10 < MINL2.11 AND 3 * L10 < XAVG(L10 + L10 + C10, 21) AND 3 * C8 < XAVG(L8 + L8 + C8, 21), L10, IIF(MINL2.9 > L11 AND L11 < MINL2.12 AND 3 * L11 < XAVG(L11 + L11 + C11, 21) AND 3 * C9 < XAVG(L9 + L9 + C9, 21), L11, IIF(MINL2.10 > L12 AND L12 < MINL2.13 AND 3 * L12 < XAVG(L12 + L12 + C12, 21) AND 3 * C10 < XAVG(L10 + L10 + C10, 21), L12, IIF(MINL2.11 > L13 AND L13 < MINL2.14 AND 3 * L13 < XAVG(L13 + L13 + C13, 21) AND 3 * C11 < XAVG(L11 + L11 + C11, 21), L13, 1 / 0))))))))))))


-Bruce
Personal Criteria Formulas
TC2000 Support Articles
dhirenshah
Posted : Monday, July 31, 2017 1:53:16 PM
Registered User
Joined: 3/10/2012
Posts: 465

No Bruce this isn't what i was asking... but lets try another way of getting through this... 

if u see your formula Friday, July 14, 2017 12:41:24 PM   where i asked u where is the current high in comparison to swing high 13(my formula in original post) and that works perfect

and when i scan Friday, July 14, 2017 12:41:24 PM  that pcf  is between 100.01 and 101 then i get the current bar to the right of the 13 bar swing as 1 tick higher then the swing high of 13 bar or 1 point higher... u can test...

SO in my present request i wanted exact same idea where using swing high of 5 bars has already happened and now when i draw horizontal line from top of swing high to the current price on to the right the current close is 1 tick higher then the swing 5 bar high  example : NUGT on hourly chart when i noticed manually the swing high happened July 28,2017 3.00 pm bar and July 31,2017 11.00 am bar closed above that swing high , so that where the pcf should respond as 100.01  now next swing high happened july 31,2017 12.00 pm bar at price value of $33.62 so as soon as current price crosses and closes above $33.62 then the output result should show 100.01  that way i will discount the July 28,2017 3.00 pm bar and use the mpst recent bar closest to the price as my data information 

Another example "C" ON MONTHLY CHART HAS 5 BAR SWING HIGH APRIL 2,2016 AND THE FIRST CLOSE ABOVE THAT SWING HIGH HAPPENED OCTOBER 31,2016 ON MONTHLY CHART THATS WHERE THE PCF SHOULD RESULT 100.01

thanks 

 

Bruce_L
Posted : Monday, July 31, 2017 2:16:35 PM


Worden Trainer

Joined: 10/7/2004
Posts: 65,138

That is a lot of words that don't make much sense at all to me. Do you just want a condition which returns true when the formula crossed up through 100?



-Bruce
Personal Criteria Formulas
TC2000 Support Articles
dhirenshah
Posted : Monday, July 31, 2017 2:25:02 PM
Registered User
Joined: 3/10/2012
Posts: 465

Yes lets try that condition which returns true when the formula crossed up through 100 and "closed "  and same for swing low where formula crossed below 100 and closed... Sorry for making you read lot of words... I m a expressive person hahaha :)

Al_Gorithm
Posted : Monday, July 31, 2017 2:35:21 PM

Registered User
Joined: 6/30/2017
Posts: 1,227
"I know you hate it when I use a hundred words when a couple will do."
 
- Jackson Gibbs
dhirenshah
Posted : Monday, July 31, 2017 2:56:56 PM
Registered User
Joined: 3/10/2012
Posts: 465

UnclePennybags  haha :

You have been pretty active lately in forums with all the screen saver images that you post are funny...

But a wise man once said  " First you Learn, then remove the L" from it ..."

Cheers 

Al_Gorithm
Posted : Monday, July 31, 2017 3:19:57 PM

Registered User
Joined: 6/30/2017
Posts: 1,227

He also said...

"When one hand itches, I scratch it with the other."

 

Bruce_L
Posted : Monday, July 31, 2017 3:20:10 PM


Worden Trainer

Joined: 10/7/2004
Posts: 65,138

Maybe the following for the swing high?

C > IIF(MAXH2 < H2 AND H2 > MAXH2.3, C, IIF(MAXH2.1 < H3 AND H3 > MAXH2.4, H3, IIF(MAXH2.2 < H4 AND H4 > MAXH2.5, IIF(C1 < H4, H4, C), IIF(MAXH2.3 < H5 AND H5 > MAXH2.6, IIF(MAXC2.1 < H5, H5, C), IIF(MAXH2.4 < H6 AND H6 > MAXH2.7, IIF(MAXC3.1 < H6, H6, C), IIF(MAXH2.5 < H7 AND H7 > MAXH2.8, IIF(MAXC4.1 < H7, H7, C), IIF(MAXH2.6 < H8 AND H8 > MAXH2.9, IIF(MAXC5.1 < H8, H8, C), IIF(MAXH2.7 < H9 AND H9 > MAXH2.10, IIF(MAXC6.1 < H9, H9, C), IIF(MAXH2.8 < H10 AND H10 > MAXH2.11, IIF(MAXC7.1 < H10, H10, C), IIF(MAXH2.9 < H11 AND H11 > MAXH2.12, IIF(MAXC8.1 < H11, H11, C), IIF(MAXH2.10 < H12 AND H12 > MAXH2.13, IIF(MAXC9.1 < H12, H12, C), IIF(MAXH2.11 < H13 AND H13 > MAXH2.14, IIF(MAXC10.1 < H13, H13, C), IIF(MAXH2.12 < H14 AND H14 > MAXH2.15, IIF(MAXC11.1 < H14, H14, C), IIF(MAXH2.13 < H15 AND H15 > MAXH2.16, IIF(MAXC12.1 < H15, H15, C), IIF(MAXH2.14 < H16 AND H16 > MAXH2.17, IIF(MAXC13.1 < H16, H16, C), IIF(MAXH2.15 < H17 AND H17 > MAXH2.18, IIF(MAXC14.1 < H17, H17, C), IIF(MAXH2.16 < H18 AND H18 > MAXH2.19, IIF(MAXC15.1 < H18, H18, C), IIF(MAXH2.17 < H19 AND H19 > MAXH2.20, IIF(MAXC16.1 < H19, H19, C), IIF(MAXH2.18 < H20 AND H20 > MAXH2.21, IIF(MAXC17.1 < H20, H20, C), IIF(MAXH2.19 < H21 AND H21 > MAXH2.22, IIF(MAXC18.1 < H21, H21, C), IIF(MAXH2.20 < H22 AND H22 > MAXH2.23, IIF(MAXC19.1 < H22, H22, C), IIF(MAXH2.21 < H23 AND H23 > MAXH2.24, IIF(MAXC20.1 < H23, H23, C), IIF(MAXH2.22 < H24 AND H24 > MAXH2.25, IIF(MAXC21.1 < H24, H24, C), IIF(MAXH2.23 < H25 AND H25 > MAXH2.26, IIF(MAXC22.1 < H25, H25, C), IIF(MAXH2.24 < H26 AND H26 > MAXH2.27, IIF(MAXC23.1 < H26, H26, C), IIF(MAXH2.25 < H27 AND H27 > MAXH2.28, IIF(MAXC24.1 < H27, H27, C), IIF(MAXH2.26 < H28 AND H28 > MAXH2.29, IIF(MAXC25.1 < H28, H28, C), IIF(MAXH2.27 < H29 AND H29 > MAXH2.30, IIF(MAXC26.1 < H29, H29, C), IIF(MAXH2.28 < H30 AND H30 > MAXH2.31, IIF(MAXC27.1 < H30, H30, C), IIF(MAXH2.29 < H31 AND H31 > MAXH2.32, IIF(MAXC28.1 < H31, H31, C), IIF(MAXH2.30 < H32 AND H32 > MAXH2.33, IIF(MAXC29.1 < H32, H32, C), IIF(MAXH2.31 < H33 AND H33 > MAXH2.34, IIF(MAXC30.1 < H33, H33, C), IIF(MAXH2.32 < H34 AND H34 > MAXH2.35, IIF(MAXC31.1 < H34, H34, C), IIF(MAXH2.33 < H35 AND H35 > MAXH2.36, IIF(MAXC32.1 < H35, H35, C), IIF(MAXH2.34 < H36 AND H36 > MAXH2.37, IIF(MAXC33.1 < H36, H36, C), IIF(MAXH2.35 < H37 AND H37 > MAXH2.38, IIF(MAXC34.1 < H37, H37, C), IIF(MAXH2.36 < H38 AND H38 > MAXH2.39, IIF(MAXC35.1 < H38, H38, C), IIF(MAXH2.37 < H39 AND H39 > MAXH2.40, IIF(MAXC36.1 < H39, H39, C), IIF(MAXH2.38 < H40 AND H40 > MAXH2.41, IIF(MAXC37.1 < H40, H40, C), IIF(MAXH2.39 < H41 AND H41 > MAXH2.42, IIF(MAXC38.1 < H41, H41, C), IIF(MAXH2.40 < H42 AND H42 > MAXH2.43, IIF(MAXC39.1 < H42, H42, C), IIF(MAXH2.41 < H43 AND H43 > MAXH2.44, IIF(MAXC40.1 < H43, H43, C), IIF(MAXH2.42 < H44 AND H44 > MAXH2.45, IIF(MAXC41.1 < H44, H44, C), IIF(MAXH2.43 < H45 AND H45 > MAXH2.46, IIF(MAXC42.1 < H45, H45, C), IIF(MAXH2.44 < H46 AND H46 > MAXH2.47, IIF(MAXC43.1 < H46, H46, C), IIF(MAXH2.45 < H47 AND H47 > MAXH2.48, IIF(MAXC44.1 < H47, H47, C), IIF(MAXH2.46 < H48 AND H48 > MAXH2.49, IIF(MAXC45.1 < H48, H48, C), IIF(MAXH2.47 < H49 AND H49 > MAXH2.50, IIF(MAXC46.1 < H49, H49, C), IIF(MAXH2.48 < H50 AND H50 > MAXH2.51, IIF(MAXC47.1 < H50, H50, C), IIF(MAXH2.49 < H51 AND H51 > MAXH2.52, IIF(MAXC48.1 < H51, H51, C), IIF(MAXH2.50 < H52 AND H52 > MAXH2.53, IIF(MAXC49.1 < H52, H52, C), IIF(MAXH2.51 < H53 AND H53 > MAXH2.54, IIF(MAXC50.1 < H53, H53, C), IIF(MAXH2.52 < H54 AND H54 > MAXH2.55, IIF(MAXC51.1 < H54, H54, C), IIF(MAXH2.53 < H55 AND H55 > MAXH2.56, IIF(MAXC52.1 < H55, H55, C), IIF(MAXH2.54 < H56 AND H56 > MAXH2.57, IIF(MAXC53.1 < H56, H56, C), IIF(MAXH2.55 < H57 AND H57 > MAXH2.58, IIF(MAXC54.1 < H57, H57, C), IIF(MAXH2.56 < H58 AND H58 > MAXH2.59, IIF(MAXC55.1 < H58, H58, C), IIF(MAXH2.57 < H59 AND H59 > MAXH2.60, IIF(MAXC56.1 < H59, H59, C), IIF(MAXH2.58 < H60 AND H60 > MAXH2.61, IIF(MAXC57.1 < H60, H60, C), IIF(MAXH2.59 < H61 AND H61 > MAXH2.62, IIF(MAXC58.1 < H61, H61, C), IIF(MAXH2.60 < H62 AND H62 > MAXH2.63, IIF(MAXC59.1 < H62, H62, C), IIF(MAXH2.61 < H63 AND H63 > MAXH2.64, IIF(MAXC60.1 < H63, H63, C), IIF(MAXH2.62 < H64 AND H64 > MAXH2.65, IIF(MAXC61.1 < H64, H64, C), IIF(MAXH2.63 < H65 AND H65 > MAXH2.66, IIF(MAXC62.1 < H65, H65, C), IIF(MAXH2.64 < H66 AND H66 > MAXH2.67, IIF(MAXC63.1 < H66, H66, C), IIF(MAXH2.65 < H67 AND H67 > MAXH2.68, IIF(MAXC64.1 < H67, H67, C), IIF(MAXH2.66 < H68 AND H68 > MAXH2.69, IIF(MAXC65.1 < H68, H68, C), IIF(MAXH2.67 < H69 AND H69 > MAXH2.70, IIF(MAXC66.1 < H69, H69, C), IIF(MAXH2.68 < H70 AND H70 > MAXH2.71, IIF(MAXC67.1 < H70, H70, C), IIF(MAXH2.69 < H71 AND H71 > MAXH2.72, IIF(MAXC68.1 < H71, H71, C), IIF(MAXH2.70 < H72 AND H72 > MAXH2.73, IIF(MAXC69.1 < H72, H72, C), IIF(MAXH2.71 < H73 AND H73 > MAXH2.74, IIF(MAXC70.1 < H73, H73, C), IIF(MAXH2.72 < H74 AND H74 > MAXH2.75, IIF(MAXC71.1 < H74, H74, C), IIF(MAXH2.73 < H75 AND H75 > MAXH2.76, IIF(MAXC72.1 < H75, H75, C), IIF(MAXH2.74 < H76 AND H76 > MAXH2.77, IIF(MAXC73.1 < H76, H76, C), IIF(MAXH2.75 < H77 AND H77 > MAXH2.78, IIF(MAXC74.1 < H77, H77, C), IIF(MAXH2.76 < H78 AND H78 > MAXH2.79, IIF(MAXC75.1 < H78, H78, C), IIF(MAXH2.77 < H79 AND H79 > MAXH2.80, IIF(MAXC76.1 < H79, H79, C), IIF(MAXH2.78 < H80 AND H80 > MAXH2.81, IIF(MAXC77.1 < H80, H80, C), IIF(MAXH2.79 < H81 AND H81 > MAXH2.82, IIF(MAXC78.1 < H81, H81, C), IIF(MAXH2.80 < H82 AND H82 > MAXH2.83, IIF(MAXC79.1 < H82, H82, C), IIF(MAXH2.81 < H83 AND H83 > MAXH2.84, IIF(MAXC80.1 < H83, H83, C), IIF(MAXH2.82 < H84 AND H84 > MAXH2.85, IIF(MAXC81.1 < H84, H84, C), IIF(MAXH2.83 < H85 AND H85 > MAXH2.86, IIF(MAXC82.1 < H85, H85, C), IIF(MAXH2.84 < H86 AND H86 > MAXH2.87, IIF(MAXC83.1 < H86, H86, C), IIF(MAXH2.85 < H87 AND H87 > MAXH2.88, IIF(MAXC84.1 < H87, H87, C), IIF(MAXH2.86 < H88 AND H88 > MAXH2.89, IIF(MAXC85.1 < H88, H88, C), IIF(MAXH2.87 < H89 AND H89 > MAXH2.90, IIF(MAXC86.1 < H89, H89, C), IIF(MAXH2.88 < H90 AND H90 > MAXH2.91, IIF(MAXC87.1 < H90, H90, C), IIF(MAXH2.89 < H91 AND H91 > MAXH2.92, IIF(MAXC88.1 < H91, H91, C), IIF(MAXH2.90 < H92 AND H92 > MAXH2.93, IIF(MAXC89.1 < H92, H92, C), IIF(MAXH2.91 < H93 AND H93 > MAXH2.94, IIF(MAXC90.1 < H93, H93, C), IIF(MAXH2.92 < H94 AND H94 > MAXH2.95, IIF(MAXC91.1 < H94, H94, C), IIF(MAXH2.93 < H95 AND H95 > MAXH2.96, IIF(MAXC92.1 < H95, H95, C), IIF(MAXH2.94 < H96 AND H96 > MAXH2.97, IIF(MAXC93.1 < H96, H96, C), IIF(MAXH2.95 < H97 AND H97 > MAXH2.98, IIF(MAXC94.1 < H97, H97, C), IIF(MAXH2.96 < H98 AND H98 > MAXH2.99, IIF(MAXC95.1 < H98, H98, C), IIF(MAXH2.97 < H99 AND H99 > MAXH2.100, IIF(MAXC96.1 < H99, H99, C), IIF(MAXH2.98 < H100 AND H100 > MAXH2.101, IIF(MAXC97.1 < H100, H100, C), IIF(MAXH2.99 < H101 AND H101 > MAXH2.102, IIF(MAXC98.1 < H101, H101, C), C))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))

And the following for the swing low?

C < IIF(MINL2 > L2 AND L2 < MINL2.3, C, IIF(MINL2.1 > L3 AND L3 < MINL2.4, L3, IIF(MINL2.2 > L4 AND L4 < MINL2.5, IIF(C1 > L4, L4, C), IIF(MINL2.3 > L5 AND L5 < MINL2.6, IIF(MINC2.1 > L5, L5, C), IIF(MINL2.4 > L6 AND L6 < MINL2.7, IIF(MINC3.1 > L6, L6, C), IIF(MINL2.5 > L7 AND L7 < MINL2.8, IIF(MINC4.1 > L7, L7, C), IIF(MINL2.6 > L8 AND L8 < MINL2.9, IIF(MINC5.1 > L8, L8, C), IIF(MINL2.7 > L9 AND L9 < MINL2.10, IIF(MINC6.1 > L9, L9, C), IIF(MINL2.8 > L10 AND L10 < MINL2.11, IIF(MINC7.1 > L10, L10, C), IIF(MINL2.9 > L11 AND L11 < MINL2.12, IIF(MINC8.1 > L11, L11, C), IIF(MINL2.10 > L12 AND L12 < MINL2.13, IIF(MINC9.1 > L12, L12, C), IIF(MINL2.11 > L13 AND L13 < MINL2.14, IIF(MINC10.1 > L13, L13, C), IIF(MINL2.12 > L14 AND L14 < MINL2.15, IIF(MINC11.1 > L14, L14, C), IIF(MINL2.13 > L15 AND L15 < MINL2.16, IIF(MINC12.1 > L15, L15, C), IIF(MINL2.14 > L16 AND L16 < MINL2.17, IIF(MINC13.1 > L16, L16, C), IIF(MINL2.15 > L17 AND L17 < MINL2.18, IIF(MINC14.1 > L17, L17, C), IIF(MINL2.16 > L18 AND L18 < MINL2.19, IIF(MINC15.1 > L18, L18, C), IIF(MINL2.17 > L19 AND L19 < MINL2.20, IIF(MINC16.1 > L19, L19, C), IIF(MINL2.18 > L20 AND L20 < MINL2.21, IIF(MINC17.1 > L20, L20, C), IIF(MINL2.19 > L21 AND L21 < MINL2.22, IIF(MINC18.1 > L21, L21, C), IIF(MINL2.20 > L22 AND L22 < MINL2.23, IIF(MINC19.1 > L22, L22, C), IIF(MINL2.21 > L23 AND L23 < MINL2.24, IIF(MINC20.1 > L23, L23, C), IIF(MINL2.22 > L24 AND L24 < MINL2.25, IIF(MINC21.1 > L24, L24, C), IIF(MINL2.23 > L25 AND L25 < MINL2.26, IIF(MINC22.1 > L25, L25, C), IIF(MINL2.24 > L26 AND L26 < MINL2.27, IIF(MINC23.1 > L26, L26, C), IIF(MINL2.25 > L27 AND L27 < MINL2.28, IIF(MINC24.1 > L27, L27, C), IIF(MINL2.26 > L28 AND L28 < MINL2.29, IIF(MINC25.1 > L28, L28, C), IIF(MINL2.27 > L29 AND L29 < MINL2.30, IIF(MINC26.1 > L29, L29, C), IIF(MINL2.28 > L30 AND L30 < MINL2.31, IIF(MINC27.1 > L30, L30, C), IIF(MINL2.29 > L31 AND L31 < MINL2.32, IIF(MINC28.1 > L31, L31, C), IIF(MINL2.30 > L32 AND L32 < MINL2.33, IIF(MINC29.1 > L32, L32, C), IIF(MINL2.31 > L33 AND L33 < MINL2.34, IIF(MINC30.1 > L33, L33, C), IIF(MINL2.32 > L34 AND L34 < MINL2.35, IIF(MINC31.1 > L34, L34, C), IIF(MINL2.33 > L35 AND L35 < MINL2.36, IIF(MINC32.1 > L35, L35, C), IIF(MINL2.34 > L36 AND L36 < MINL2.37, IIF(MINC33.1 > L36, L36, C), IIF(MINL2.35 > L37 AND L37 < MINL2.38, IIF(MINC34.1 > L37, L37, C), IIF(MINL2.36 > L38 AND L38 < MINL2.39, IIF(MINC35.1 > L38, L38, C), IIF(MINL2.37 > L39 AND L39 < MINL2.40, IIF(MINC36.1 > L39, L39, C), IIF(MINL2.38 > L40 AND L40 < MINL2.41, IIF(MINC37.1 > L40, L40, C), IIF(MINL2.39 > L41 AND L41 < MINL2.42, IIF(MINC38.1 > L41, L41, C), IIF(MINL2.40 > L42 AND L42 < MINL2.43, IIF(MINC39.1 > L42, L42, C), IIF(MINL2.41 > L43 AND L43 < MINL2.44, IIF(MINC40.1 > L43, L43, C), IIF(MINL2.42 > L44 AND L44 < MINL2.45, IIF(MINC41.1 > L44, L44, C), IIF(MINL2.43 > L45 AND L45 < MINL2.46, IIF(MINC42.1 > L45, L45, C), IIF(MINL2.44 > L46 AND L46 < MINL2.47, IIF(MINC43.1 > L46, L46, C), IIF(MINL2.45 > L47 AND L47 < MINL2.48, IIF(MINC44.1 > L47, L47, C), IIF(MINL2.46 > L48 AND L48 < MINL2.49, IIF(MINC45.1 > L48, L48, C), IIF(MINL2.47 > L49 AND L49 < MINL2.50, IIF(MINC46.1 > L49, L49, C), IIF(MINL2.48 > L50 AND L50 < MINL2.51, IIF(MINC47.1 > L50, L50, C), IIF(MINL2.49 > L51 AND L51 < MINL2.52, IIF(MINC48.1 > L51, L51, C), IIF(MINL2.50 > L52 AND L52 < MINL2.53, IIF(MINC49.1 > L52, L52, C), IIF(MINL2.51 > L53 AND L53 < MINL2.54, IIF(MINC50.1 > L53, L53, C), IIF(MINL2.52 > L54 AND L54 < MINL2.55, IIF(MINC51.1 > L54, L54, C), IIF(MINL2.53 > L55 AND L55 < MINL2.56, IIF(MINC52.1 > L55, L55, C), IIF(MINL2.54 > L56 AND L56 < MINL2.57, IIF(MINC53.1 > L56, L56, C), IIF(MINL2.55 > L57 AND L57 < MINL2.58, IIF(MINC54.1 > L57, L57, C), IIF(MINL2.56 > L58 AND L58 < MINL2.59, IIF(MINC55.1 > L58, L58, C), IIF(MINL2.57 > L59 AND L59 < MINL2.60, IIF(MINC56.1 > L59, L59, C), IIF(MINL2.58 > L60 AND L60 < MINL2.61, IIF(MINC57.1 > L60, L60, C), IIF(MINL2.59 > L61 AND L61 < MINL2.62, IIF(MINC58.1 > L61, L61, C), IIF(MINL2.60 > L62 AND L62 < MINL2.63, IIF(MINC59.1 > L62, L62, C), IIF(MINL2.61 > L63 AND L63 < MINL2.64, IIF(MINC60.1 > L63, L63, C), IIF(MINL2.62 > L64 AND L64 < MINL2.65, IIF(MINC61.1 > L64, L64, C), IIF(MINL2.63 > L65 AND L65 < MINL2.66, IIF(MINC62.1 > L65, L65, C), IIF(MINL2.64 > L66 AND L66 < MINL2.67, IIF(MINC63.1 > L66, L66, C), IIF(MINL2.65 > L67 AND L67 < MINL2.68, IIF(MINC64.1 > L67, L67, C), IIF(MINL2.66 > L68 AND L68 < MINL2.69, IIF(MINC65.1 > L68, L68, C), IIF(MINL2.67 > L69 AND L69 < MINL2.70, IIF(MINC66.1 > L69, L69, C), IIF(MINL2.68 > L70 AND L70 < MINL2.71, IIF(MINC67.1 > L70, L70, C), IIF(MINL2.69 > L71 AND L71 < MINL2.72, IIF(MINC68.1 > L71, L71, C), IIF(MINL2.70 > L72 AND L72 < MINL2.73, IIF(MINC69.1 > L72, L72, C), IIF(MINL2.71 > L73 AND L73 < MINL2.74, IIF(MINC70.1 > L73, L73, C), IIF(MINL2.72 > L74 AND L74 < MINL2.75, IIF(MINC71.1 > L74, L74, C), IIF(MINL2.73 > L75 AND L75 < MINL2.76, IIF(MINC72.1 > L75, L75, C), IIF(MINL2.74 > L76 AND L76 < MINL2.77, IIF(MINC73.1 > L76, L76, C), IIF(MINL2.75 > L77 AND L77 < MINL2.78, IIF(MINC74.1 > L77, L77, C), IIF(MINL2.76 > L78 AND L78 < MINL2.79, IIF(MINC75.1 > L78, L78, C), IIF(MINL2.77 > L79 AND L79 < MINL2.80, IIF(MINC76.1 > L79, L79, C), IIF(MINL2.78 > L80 AND L80 < MINL2.81, IIF(MINC77.1 > L80, L80, C), IIF(MINL2.79 > L81 AND L81 < MINL2.82, IIF(MINC78.1 > L81, L81, C), IIF(MINL2.80 > L82 AND L82 < MINL2.83, IIF(MINC79.1 > L82, L82, C), IIF(MINL2.81 > L83 AND L83 < MINL2.84, IIF(MINC80.1 > L83, L83, C), IIF(MINL2.82 > L84 AND L84 < MINL2.85, IIF(MINC81.1 > L84, L84, C), IIF(MINL2.83 > L85 AND L85 < MINL2.86, IIF(MINC82.1 > L85, L85, C), IIF(MINL2.84 > L86 AND L86 < MINL2.87, IIF(MINC83.1 > L86, L86, C), IIF(MINL2.85 > L87 AND L87 < MINL2.88, IIF(MINC84.1 > L87, L87, C), IIF(MINL2.86 > L88 AND L88 < MINL2.89, IIF(MINC85.1 > L88, L88, C), IIF(MINL2.87 > L89 AND L89 < MINL2.90, IIF(MINC86.1 > L89, L89, C), IIF(MINL2.88 > L90 AND L90 < MINL2.91, IIF(MINC87.1 > L90, L90, C), IIF(MINL2.89 > L91 AND L91 < MINL2.92, IIF(MINC88.1 > L91, L91, C), IIF(MINL2.90 > L92 AND L92 < MINL2.93, IIF(MINC89.1 > L92, L92, C), IIF(MINL2.91 > L93 AND L93 < MINL2.94, IIF(MINC90.1 > L93, L93, C), IIF(MINL2.92 > L94 AND L94 < MINL2.95, IIF(MINC91.1 > L94, L94, C), IIF(MINL2.93 > L95 AND L95 < MINL2.96, IIF(MINC92.1 > L95, L95, C), IIF(MINL2.94 > L96 AND L96 < MINL2.97, IIF(MINC93.1 > L96, L96, C), IIF(MINL2.95 > L97 AND L97 < MINL2.98, IIF(MINC94.1 > L97, L97, C), IIF(MINL2.96 > L98 AND L98 < MINL2.99, IIF(MINC95.1 > L98, L98, C), IIF(MINL2.97 > L99 AND L99 < MINL2.100, IIF(MINC96.1 > L99, L99, C), IIF(MINL2.98 > L100 AND L100 < MINL2.101, IIF(MINC97.1 > L100, L100, C), IIF(MINL2.99 > L101 AND L101 < MINL2.102, IIF(MINC98.1 > L101, L101, C), C))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))



-Bruce
Personal Criteria Formulas
TC2000 Support Articles
dhirenshah
Posted : Monday, July 31, 2017 3:46:00 PM
Registered User
Joined: 3/10/2012
Posts: 465

Bruce thanks but after testing it.. Swing High works perfect but Swing low seems having loose ends.. 

what i mean is i wanted once the swing low is established and the current price bar must be crossing and closing below that swing low thats where PCF will be True and PCF seeems loose on the same.. 

example FDX on 195 min chart has most recent swing low is July 21,2017 12.45 pm the bar that and confirm true by pCF should have been July 27,2017 12.45 pm so i don't see that happening ...

Trying to keep sentence shorter  :)

 

Bruce_L
Posted : Monday, July 31, 2017 3:53:47 PM


Worden Trainer

Joined: 10/7/2004
Posts: 65,138

I think some of the > and < signs were going the wrong way. Please try it again.



-Bruce
Personal Criteria Formulas
TC2000 Support Articles
dhirenshah
Posted : Monday, July 31, 2017 4:08:36 PM
Registered User
Joined: 3/10/2012
Posts: 465

Yes thanks a lot Bruce that works appreciate your patience and making it work

One question have u done any work on Market Faciliation Index in V12 or V17 i know u have in stock finder , so just checking

 

Regards

Bruce_L
Posted : Monday, July 31, 2017 4:31:36 PM


Worden Trainer

Joined: 10/7/2004
Posts: 65,138

The Market Facilitation Index (MFI) itself is just:

(H - L) / V

Although if you wanted to plot it different colors for green, fade, fake, and squat, then things could get a little more interesting.

Green:

IIF(V > V1 AND (H - L) / V > (H1 - L1) / V1, (H - L) / V, 1 / 0)

Fade:

IIF(V < V1 AND (H - L) / V < (H1 - L1) / V1, (H - L) / V, 1 / 0)

Fake:

IIF(V < V1 AND (H - L) / V > (H1 - L1) / V1, (H - L) / V, 1 / 0)

Squat:

IIF(V > V1 AND (H - L) / V < (H1 - L1) / V1, (H - L) / V, 1 / 0)



-Bruce
Personal Criteria Formulas
TC2000 Support Articles
dhirenshah
Posted : Monday, July 31, 2017 4:42:16 PM
Registered User
Joined: 3/10/2012
Posts: 465

Excellent Thankyou

Rock1
Posted : Friday, February 16, 2018 6:22:10 PM
Registered User
Joined: 3/16/2016
Posts: 57

Hi Bruce, I am looking at your first reply in this topic form from-Wednesday, May 17, 2017 4:45:31 PM. 

I have tried some of the other formulas but they don't seem to work.  Saying "Is true is not valid for a value formula" So do I need to change it to -Formula value -is my retracement value-say 50. IF I want a 50% retracement. 

Looking at your first formula in your 1st reply- your saying- (both the swing high and swing low need to have been identified with the most recent 50 bars). Which sounds like a good start. there were other requests in this topic form for only 13 bars? But I would rather look at as many bars -both the swing high and swing low need to have been identified with the most recent 50 bars-sounds Good to me.

Your formula starts off like this.

ABS(L - .298 * IIF(MAXH13 < H13 AND H13 > MAXH13.14, H13, IIF(MAXH13.1 < H14 AND H14 > MAXH13.15, H14, IIF(MAXH13.2 < H15 AND H15 > MAXH13.16, H15, IIF(MAXH13.3 < H16 AND H16 > MAXH13.17, H16, IIF(MAXH13.4 < H17 AND H17 > MAXH13.18, H17, IIF(MAXH13.5 < H18 AND H18 > MAXH13.19, H18, IIF(MAXH13.6 < H19 AND H19 > MAXH13.20, H19, IIF(MAXH13.7 < H20 AND H20 > MAXH13.21, H20, IIF(MAXH13.8 < H21 AND H21 > MAXH13.22, H21, IIF(MAXH13.9 < H22 AND H22 > MAXH13.23, H22, IIF(MAXH13.10 < H23 AND H23 > MAXH13.24, H23, IIF(MAXH13.11 < H24 AND H24 > MAXH13.25, H24, IIF(MAXH13.12 < H25 AND H25 > MAXH13.26, H25, IIF(MAXH13.13 < H26 AND H26 > 

 

Is this where I need to change my retracement number- in the first line-ABS(L - .298

to ABS(L - .500      If I want my retracement value-to be 50%?

So, again-from a previous post, I am looking for a 50% (or what ever%) retracement from the most recent Major piviot high and Major piviot Low.

I guess this may also be like a,  A-B-C pattern, B to C is "50%" of A to B. 

Right now the Major piviot high and Major piviot Low. In your formula you are looking back at the last 50 bars to pick up the High and the Low.

thanks

Rock1
Posted : Friday, February 16, 2018 6:26:29 PM
Registered User
Joined: 3/16/2016
Posts: 57

*From my second sentence-"Formula value" In the Edit Conditions Box. I have the options to choose from Greater than, Less than, Is between. If that is where I need to change my retracement value. Or if I can just change the value from the PCF and leave Formula value as-Is true.

thanks

Bruce_L
Posted : Tuesday, February 20, 2018 2:45:59 PM


Worden Trainer

Joined: 10/7/2004
Posts: 65,138

The original formula you are trying to adapt is more complicated than that and is designed to check for the retracement being within a specific range (in this case between .214 and .382). 

The .298 is the midpoint of the range, .702 is one minus the midpoint of the range, and .084 is half the range.

It seems like you want something a lot simpler. So for example if the pivot high 13 happened after the pivot low 13, then the retracment back down as a percentage of the range between the two would be the following (this is the formula from my Thursday, May 18, 2017 12:57:20 PM ET post).

100 * (IIF(MAXH13 < H13 AND H13 > MAXH13.14, H13, IIF(MAXH13.1 < H14 AND H14 > MAXH13.15, H14, IIF(MAXH13.2 < H15 AND H15 > MAXH13.16, H15, IIF(MAXH13.3 < H16 AND H16 > MAXH13.17, H16, IIF(MAXH13.4 < H17 AND H17 > MAXH13.18, H17, IIF(MAXH13.5 < H18 AND H18 > MAXH13.19, H18, IIF(MAXH13.6 < H19 AND H19 > MAXH13.20, H19, IIF(MAXH13.7 < H20 AND H20 > MAXH13.21, H20, IIF(MAXH13.8 < H21 AND H21 > MAXH13.22, H21, IIF(MAXH13.9 < H22 AND H22 > MAXH13.23, H22, IIF(MAXH13.10 < H23 AND H23 > MAXH13.24, H23, IIF(MAXH13.11 < H24 AND H24 > MAXH13.25, H24, IIF(MAXH13.12 < H25 AND H25 > MAXH13.26, H25, IIF(MAXH13.13 < H26 AND H26 > MAXH13.27, H26, IIF(MAXH13.14 < H27 AND H27 > MAXH13.28, H27, IIF(MAXH13.15 < H28 AND H28 > MAXH13.29, H28, IIF(MAXH13.16 < H29 AND H29 > MAXH13.30, H29, IIF(MAXH13.17 < H30 AND H30 > MAXH13.31, H30, IIF(MAXH13.18 < H31 AND H31 > MAXH13.32, H31, IIF(MAXH13.19 < H32 AND H32 > MAXH13.33, H32, IIF(MAXH13.20 < H33 AND H33 > MAXH13.34, H33, IIF(MAXH13.21 < H34 AND H34 > MAXH13.35, H34, IIF(MAXH13.22 < H35 AND H35 > MAXH13.36, H35, IIF(MAXH13.23 < H36 AND H36 > MAXH13.37, H36, IIF(MAXH13.24 < H37 AND H37 > MAXH13.38, H37, IIF(MAXH13.25 < H38 AND H38 > MAXH13.39, H38, IIF(MAXH13.26 < H39 AND H39 > MAXH13.40, H39, IIF(MAXH13.27 < H40 AND H40 > MAXH13.41, H40, IIF(MAXH13.28 < H41 AND H41 > MAXH13.42, H41, IIF(MAXH13.29 < H42 AND H42 > MAXH13.43, H42, IIF(MAXH13.30 < H43 AND H43 > MAXH13.44, H43, IIF(MAXH13.31 < H44 AND H44 > MAXH13.45, H44, IIF(MAXH13.32 < H45 AND H45 > MAXH13.46, H45, IIF(MAXH13.33 < H46 AND H46 > MAXH13.47, H46, IIF(MAXH13.34 < H47 AND H47 > MAXH13.48, H47, IIF(MAXH13.35 < H48 AND H48 > MAXH13.49, H48, IIF(MAXH13.36 < H49 AND H49 > MAXH13.50, H49, IIF(MAXH13.37 < H50 AND H50 > MAXH13.51, H50, IIF(MAXH13.38 < H51 AND H51 > MAXH13.52, H51, IIF(MAXH13.39 < H52 AND H52 > MAXH13.53, H52, IIF(MAXH13.40 < H53 AND H53 > MAXH13.54, H53, IIF(MAXH13.41 < H54 AND H54 > MAXH13.55, H54, IIF(MAXH13.42 < H55 AND H55 > MAXH13.56, H55, IIF(MAXH13.43 < H56 AND H56 > MAXH13.57, H56, IIF(MAXH13.44 < H57 AND H57 > MAXH13.58, H57, IIF(MAXH13.45 < H58 AND H58 > MAXH13.59, H58, IIF(MAXH13.46 < H59 AND H59 > MAXH13.60, H59, IIF(MAXH13.47 < H60 AND H60 > MAXH13.61, H60, IIF(MAXH13.48 < H61 AND H61 > MAXH13.62, H61, IIF(MAXH13.49 < H62 AND H62 > MAXH13.63, H62, 1/0)))))))))))))))))))))))))))))))))))))))))))))))))) - L) / (IIF(MAXH13 < H13 AND H13 > MAXH13.14, H13, IIF(MAXH13.1 < H14 AND H14 > MAXH13.15, H14, IIF(MAXH13.2 < H15 AND H15 > MAXH13.16, H15, IIF(MAXH13.3 < H16 AND H16 > MAXH13.17, H16, IIF(MAXH13.4 < H17 AND H17 > MAXH13.18, H17, IIF(MAXH13.5 < H18 AND H18 > MAXH13.19, H18, IIF(MAXH13.6 < H19 AND H19 > MAXH13.20, H19, IIF(MAXH13.7 < H20 AND H20 > MAXH13.21, H20, IIF(MAXH13.8 < H21 AND H21 > MAXH13.22, H21, IIF(MAXH13.9 < H22 AND H22 > MAXH13.23, H22, IIF(MAXH13.10 < H23 AND H23 > MAXH13.24, H23, IIF(MAXH13.11 < H24 AND H24 > MAXH13.25, H24, IIF(MAXH13.12 < H25 AND H25 > MAXH13.26, H25, IIF(MAXH13.13 < H26 AND H26 > MAXH13.27, H26, IIF(MAXH13.14 < H27 AND H27 > MAXH13.28, H27, IIF(MAXH13.15 < H28 AND H28 > MAXH13.29, H28, IIF(MAXH13.16 < H29 AND H29 > MAXH13.30, H29, IIF(MAXH13.17 < H30 AND H30 > MAXH13.31, H30, IIF(MAXH13.18 < H31 AND H31 > MAXH13.32, H31, IIF(MAXH13.19 < H32 AND H32 > MAXH13.33, H32, IIF(MAXH13.20 < H33 AND H33 > MAXH13.34, H33, IIF(MAXH13.21 < H34 AND H34 > MAXH13.35, H34, IIF(MAXH13.22 < H35 AND H35 > MAXH13.36, H35, IIF(MAXH13.23 < H36 AND H36 > MAXH13.37, H36, IIF(MAXH13.24 < H37 AND H37 > MAXH13.38, H37, IIF(MAXH13.25 < H38 AND H38 > MAXH13.39, H38, IIF(MAXH13.26 < H39 AND H39 > MAXH13.40, H39, IIF(MAXH13.27 < H40 AND H40 > MAXH13.41, H40, IIF(MAXH13.28 < H41 AND H41 > MAXH13.42, H41, IIF(MAXH13.29 < H42 AND H42 > MAXH13.43, H42, IIF(MAXH13.30 < H43 AND H43 > MAXH13.44, H43, IIF(MAXH13.31 < H44 AND H44 > MAXH13.45, H44, IIF(MAXH13.32 < H45 AND H45 > MAXH13.46, H45, IIF(MAXH13.33 < H46 AND H46 > MAXH13.47, H46, IIF(MAXH13.34 < H47 AND H47 > MAXH13.48, H47, IIF(MAXH13.35 < H48 AND H48 > MAXH13.49, H48, IIF(MAXH13.36 < H49 AND H49 > MAXH13.50, H49, IIF(MAXH13.37 < H50 AND H50 > MAXH13.51, H50, IIF(MAXH13.38 < H51 AND H51 > MAXH13.52, H51, IIF(MAXH13.39 < H52 AND H52 > MAXH13.53, H52, IIF(MAXH13.40 < H53 AND H53 > MAXH13.54, H53, IIF(MAXH13.41 < H54 AND H54 > MAXH13.55, H54, IIF(MAXH13.42 < H55 AND H55 > MAXH13.56, H55, IIF(MAXH13.43 < H56 AND H56 > MAXH13.57, H56, IIF(MAXH13.44 < H57 AND H57 > MAXH13.58, H57, IIF(MAXH13.45 < H58 AND H58 > MAXH13.59, H58, IIF(MAXH13.46 < H59 AND H59 > MAXH13.60, H59, IIF(MAXH13.47 < H60 AND H60 > MAXH13.61, H60, IIF(MAXH13.48 < H61 AND H61 > MAXH13.62, H61, IIF(MAXH13.49 < H62 AND H62 > MAXH13.63, H62, 1/0)))))))))))))))))))))))))))))))))))))))))))))))))) - IIF(MINL13 > L13 AND L13 < MINL13.14, L13, IIF(MINL13.1 > L14 AND L14 < MINL13.15, L14, IIF(MINL13.2 > L15 AND L15 < MINL13.16, L15, IIF(MINL13.3 > L16 AND L16 < MINL13.17, L16, IIF(MINL13.4 > L17 AND L17 < MINL13.18, L17, IIF(MINL13.5 > L18 AND L18 < MINL13.19, L18, IIF(MINL13.6 > L19 AND L19 < MINL13.20, L19, IIF(MINL13.7 > L20 AND L20 < MINL13.21, L20, IIF(MINL13.8 > L21 AND L21 < MINL13.22, L21, IIF(MINL13.9 > L22 AND L22 < MINL13.23, L22, IIF(MINL13.10 > L23 AND L23 < MINL13.24, L23, IIF(MINL13.11 > L24 AND L24 < MINL13.25, L24, IIF(MINL13.12 > L25 AND L25 < MINL13.26, L25, IIF(MINL13.13 > L26 AND L26 < MINL13.27, L26, IIF(MINL13.14 > L27 AND L27 < MINL13.28, L27, IIF(MINL13.15 > L28 AND L28 < MINL13.29, L28, IIF(MINL13.16 > L29 AND L29 < MINL13.30, L29, IIF(MINL13.17 > L30 AND L30 < MINL13.31, L30, IIF(MINL13.18 > L31 AND L31 < MINL13.32, L31, IIF(MINL13.19 > L32 AND L32 < MINL13.33, L32, IIF(MINL13.20 > L33 AND L33 < MINL13.34, L33, IIF(MINL13.21 > L34 AND L34 < MINL13.35, L34, IIF(MINL13.22 > L35 AND L35 < MINL13.36, L35, IIF(MINL13.23 > L36 AND L36 < MINL13.37, L36, IIF(MINL13.24 > L37 AND L37 < MINL13.38, L37, IIF(MINL13.25 > L38 AND L38 < MINL13.39, L38, IIF(MINL13.26 > L39 AND L39 < MINL13.40, L39, IIF(MINL13.27 > L40 AND L40 < MINL13.41, L40, IIF(MINL13.28 > L41 AND L41 < MINL13.42, L41, IIF(MINL13.29 > L42 AND L42 < MINL13.43, L42, IIF(MINL13.30 > L43 AND L43 < MINL13.44, L43, IIF(MINL13.31 > L44 AND L44 < MINL13.45, L44, IIF(MINL13.32 > L45 AND L45 < MINL13.46, L45, IIF(MINL13.33 > L46 AND L46 < MINL13.47, L46, IIF(MINL13.34 > L47 AND L47 < MINL13.48, L47, IIF(MINL13.35 > L48 AND L48 < MINL13.49, L48, IIF(MINL13.36 > L49 AND L49 < MINL13.50, L49, IIF(MINL13.37 > L50 AND L50 < MINL13.51, L50, IIF(MINL13.38 > L51 AND L51 < MINL13.52, L51, IIF(MINL13.39 > L52 AND L52 < MINL13.53, L52, IIF(MINL13.40 > L53 AND L53 < MINL13.54, L53, IIF(MINL13.41 > L54 AND L54 < MINL13.55, L54, IIF(MINL13.42 > L55 AND L55 < MINL13.56, L55, IIF(MINL13.43 > L56 AND L56 < MINL13.57, L56, IIF(MINL13.44 > L57 AND L57 < MINL13.58, L57, IIF(MINL13.45 > L58 AND L58 < MINL13.59, L58, IIF(MINL13.46 > L59 AND L59 < MINL13.60, L59, IIF(MINL13.47 > L60 AND L60 < MINL13.61, L60, IIF(MINL13.48 > L61 AND L61 < MINL13.62, L61, IIF(MINL13.49 > L62 AND L62 < MINL13.63, L62, 1/0)))))))))))))))))))))))))))))))))))))))))))))))))))

You could add > 50 to the end to check for it being at least a 50% retracement back down from the high.



-Bruce
Personal Criteria Formulas
TC2000 Support Articles
Rock1
Posted : Thursday, February 22, 2018 2:56:40 PM
Registered User
Joined: 3/16/2016
Posts: 57

Thanks Bruce, When I paste the first part in, it says, IS TRUE IS NOT VAILD FOR A FORMULA VALUE-CHANGE IT TO A VALID CHOICE? is that formula suppose to work on its own? When I put in >50 it was working, But now it works when I put in <50.

thanks

Bruce_L
Posted : Thursday, February 22, 2018 3:00:26 PM


Worden Trainer

Joined: 10/7/2004
Posts: 65,138

The formula returns a numeric value. So yes, it works on its own if you want a numeric value.

If you want it to be a condition, then it doesn't work on its own. You need to compare it to something such as another numeric value. For example, by adding > 50 or < 50 to the end of the formula.



-Bruce
Personal Criteria Formulas
TC2000 Support Articles
Rock1
Posted : Thursday, February 22, 2018 3:21:05 PM
Registered User
Joined: 3/16/2016
Posts: 57

Okay, I got it. when I add the formula to my Library as a condition or indicator then, I can add that colume to the easy scan and see the numbers and sort from high to low ex. 

So, does this formula Look at the last 13 bars for the Pivot high and Pivot low?  Would all of the 13 in the formula have to be changed to 50.  to see the Major (or last) Pivot high and Low within the last 50days?

And this sounds like, when you say add >50 would be coming from the pivot high. (Formula for a up trend and retracment)

would <50 be coming from the pivot Low? (Formula for a down trend and retracment)

Or would all of the < > in the formula need to be reversed?

thanks

Rock1
Posted : Thursday, February 22, 2018 3:22:35 PM
Registered User
Joined: 3/16/2016
Posts: 57

Or would all of the < > in the formula need to be reversed? ---To get results for a (Formula for a Down trend and retracment)?

Bruce_L
Posted : Thursday, February 22, 2018 3:50:22 PM


Worden Trainer

Joined: 10/7/2004
Posts: 65,138

The formula doesn't check to see if the pivot high or pivot low came first. It looks back 50 bars for both the pivot high and pivot low.

The pivot highs and pivot lows are "major" in that the pivot high requires 13 lower highs on both sides and the pivot low requires 13 higher lows on both sides.

The formula in my Tuesday, February 20, 2018 2:45:59 PM ET post assumes the pivot high happened after the pivot low and is measuring the retracement back from the pivot high back down using the low of the current bar to determine the retracement percentage.

If you the pivot low happened after the pivot high, then you would want to use the following formula instead.

100 * (H - IIF(MINL13 > L13 AND L13 < MINL13.14, L13, IIF(MINL13.1 > L14 AND L14 < MINL13.15, L14, IIF(MINL13.2 > L15 AND L15 < MINL13.16, L15, IIF(MINL13.3 > L16 AND L16 < MINL13.17, L16, IIF(MINL13.4 > L17 AND L17 < MINL13.18, L17, IIF(MINL13.5 > L18 AND L18 < MINL13.19, L18, IIF(MINL13.6 > L19 AND L19 < MINL13.20, L19, IIF(MINL13.7 > L20 AND L20 < MINL13.21, L20, IIF(MINL13.8 > L21 AND L21 < MINL13.22, L21, IIF(MINL13.9 > L22 AND L22 < MINL13.23, L22, IIF(MINL13.10 > L23 AND L23 < MINL13.24, L23, IIF(MINL13.11 > L24 AND L24 < MINL13.25, L24, IIF(MINL13.12 > L25 AND L25 < MINL13.26, L25, IIF(MINL13.13 > L26 AND L26 < MINL13.27, L26, IIF(MINL13.14 > L27 AND L27 < MINL13.28, L27, IIF(MINL13.15 > L28 AND L28 < MINL13.29, L28, IIF(MINL13.16 > L29 AND L29 < MINL13.30, L29, IIF(MINL13.17 > L30 AND L30 < MINL13.31, L30, IIF(MINL13.18 > L31 AND L31 < MINL13.32, L31, IIF(MINL13.19 > L32 AND L32 < MINL13.33, L32, IIF(MINL13.20 > L33 AND L33 < MINL13.34, L33, IIF(MINL13.21 > L34 AND L34 < MINL13.35, L34, IIF(MINL13.22 > L35 AND L35 < MINL13.36, L35, IIF(MINL13.23 > L36 AND L36 < MINL13.37, L36, IIF(MINL13.24 > L37 AND L37 < MINL13.38, L37, IIF(MINL13.25 > L38 AND L38 < MINL13.39, L38, IIF(MINL13.26 > L39 AND L39 < MINL13.40, L39, IIF(MINL13.27 > L40 AND L40 < MINL13.41, L40, IIF(MINL13.28 > L41 AND L41 < MINL13.42, L41, IIF(MINL13.29 > L42 AND L42 < MINL13.43, L42, IIF(MINL13.30 > L43 AND L43 < MINL13.44, L43, IIF(MINL13.31 > L44 AND L44 < MINL13.45, L44, IIF(MINL13.32 > L45 AND L45 < MINL13.46, L45, IIF(MINL13.33 > L46 AND L46 < MINL13.47, L46, IIF(MINL13.34 > L47 AND L47 < MINL13.48, L47, IIF(MINL13.35 > L48 AND L48 < MINL13.49, L48, IIF(MINL13.36 > L49 AND L49 < MINL13.50, L49, IIF(MINL13.37 > L50 AND L50 < MINL13.51, L50, IIF(MINL13.38 > L51 AND L51 < MINL13.52, L51, IIF(MINL13.39 > L52 AND L52 < MINL13.53, L52, IIF(MINL13.40 > L53 AND L53 < MINL13.54, L53, IIF(MINL13.41 > L54 AND L54 < MINL13.55, L54, IIF(MINL13.42 > L55 AND L55 < MINL13.56, L55, IIF(MINL13.43 > L56 AND L56 < MINL13.57, L56, IIF(MINL13.44 > L57 AND L57 < MINL13.58, L57, IIF(MINL13.45 > L58 AND L58 < MINL13.59, L58, IIF(MINL13.46 > L59 AND L59 < MINL13.60, L59, IIF(MINL13.47 > L60 AND L60 < MINL13.61, L60, IIF(MINL13.48 > L61 AND L61 < MINL13.62, L61, IIF(MINL13.49 > L62 AND L62 < MINL13.63, L62, 1/0))))))))))))))))))))))))))))))))))))))))))))))))))) / (IIF(MAXH13 < H13 AND H13 > MAXH13.14, H13, IIF(MAXH13.1 < H14 AND H14 > MAXH13.15, H14, IIF(MAXH13.2 < H15 AND H15 > MAXH13.16, H15, IIF(MAXH13.3 < H16 AND H16 > MAXH13.17, H16, IIF(MAXH13.4 < H17 AND H17 > MAXH13.18, H17, IIF(MAXH13.5 < H18 AND H18 > MAXH13.19, H18, IIF(MAXH13.6 < H19 AND H19 > MAXH13.20, H19, IIF(MAXH13.7 < H20 AND H20 > MAXH13.21, H20, IIF(MAXH13.8 < H21 AND H21 > MAXH13.22, H21, IIF(MAXH13.9 < H22 AND H22 > MAXH13.23, H22, IIF(MAXH13.10 < H23 AND H23 > MAXH13.24, H23, IIF(MAXH13.11 < H24 AND H24 > MAXH13.25, H24, IIF(MAXH13.12 < H25 AND H25 > MAXH13.26, H25, IIF(MAXH13.13 < H26 AND H26 > MAXH13.27, H26, IIF(MAXH13.14 < H27 AND H27 > MAXH13.28, H27, IIF(MAXH13.15 < H28 AND H28 > MAXH13.29, H28, IIF(MAXH13.16 < H29 AND H29 > MAXH13.30, H29, IIF(MAXH13.17 < H30 AND H30 > MAXH13.31, H30, IIF(MAXH13.18 < H31 AND H31 > MAXH13.32, H31, IIF(MAXH13.19 < H32 AND H32 > MAXH13.33, H32, IIF(MAXH13.20 < H33 AND H33 > MAXH13.34, H33, IIF(MAXH13.21 < H34 AND H34 > MAXH13.35, H34, IIF(MAXH13.22 < H35 AND H35 > MAXH13.36, H35, IIF(MAXH13.23 < H36 AND H36 > MAXH13.37, H36, IIF(MAXH13.24 < H37 AND H37 > MAXH13.38, H37, IIF(MAXH13.25 < H38 AND H38 > MAXH13.39, H38, IIF(MAXH13.26 < H39 AND H39 > MAXH13.40, H39, IIF(MAXH13.27 < H40 AND H40 > MAXH13.41, H40, IIF(MAXH13.28 < H41 AND H41 > MAXH13.42, H41, IIF(MAXH13.29 < H42 AND H42 > MAXH13.43, H42, IIF(MAXH13.30 < H43 AND H43 > MAXH13.44, H43, IIF(MAXH13.31 < H44 AND H44 > MAXH13.45, H44, IIF(MAXH13.32 < H45 AND H45 > MAXH13.46, H45, IIF(MAXH13.33 < H46 AND H46 > MAXH13.47, H46, IIF(MAXH13.34 < H47 AND H47 > MAXH13.48, H47, IIF(MAXH13.35 < H48 AND H48 > MAXH13.49, H48, IIF(MAXH13.36 < H49 AND H49 > MAXH13.50, H49, IIF(MAXH13.37 < H50 AND H50 > MAXH13.51, H50, IIF(MAXH13.38 < H51 AND H51 > MAXH13.52, H51, IIF(MAXH13.39 < H52 AND H52 > MAXH13.53, H52, IIF(MAXH13.40 < H53 AND H53 > MAXH13.54, H53, IIF(MAXH13.41 < H54 AND H54 > MAXH13.55, H54, IIF(MAXH13.42 < H55 AND H55 > MAXH13.56, H55, IIF(MAXH13.43 < H56 AND H56 > MAXH13.57, H56, IIF(MAXH13.44 < H57 AND H57 > MAXH13.58, H57, IIF(MAXH13.45 < H58 AND H58 > MAXH13.59, H58, IIF(MAXH13.46 < H59 AND H59 > MAXH13.60, H59, IIF(MAXH13.47 < H60 AND H60 > MAXH13.61, H60, IIF(MAXH13.48 < H61 AND H61 > MAXH13.62, H61, IIF(MAXH13.49 < H62 AND H62 > MAXH13.63, H62, 1/0)))))))))))))))))))))))))))))))))))))))))))))))))) - IIF(MINL13 > L13 AND L13 < MINL13.14, L13, IIF(MINL13.1 > L14 AND L14 < MINL13.15, L14, IIF(MINL13.2 > L15 AND L15 < MINL13.16, L15, IIF(MINL13.3 > L16 AND L16 < MINL13.17, L16, IIF(MINL13.4 > L17 AND L17 < MINL13.18, L17, IIF(MINL13.5 > L18 AND L18 < MINL13.19, L18, IIF(MINL13.6 > L19 AND L19 < MINL13.20, L19, IIF(MINL13.7 > L20 AND L20 < MINL13.21, L20, IIF(MINL13.8 > L21 AND L21 < MINL13.22, L21, IIF(MINL13.9 > L22 AND L22 < MINL13.23, L22, IIF(MINL13.10 > L23 AND L23 < MINL13.24, L23, IIF(MINL13.11 > L24 AND L24 < MINL13.25, L24, IIF(MINL13.12 > L25 AND L25 < MINL13.26, L25, IIF(MINL13.13 > L26 AND L26 < MINL13.27, L26, IIF(MINL13.14 > L27 AND L27 < MINL13.28, L27, IIF(MINL13.15 > L28 AND L28 < MINL13.29, L28, IIF(MINL13.16 > L29 AND L29 < MINL13.30, L29, IIF(MINL13.17 > L30 AND L30 < MINL13.31, L30, IIF(MINL13.18 > L31 AND L31 < MINL13.32, L31, IIF(MINL13.19 > L32 AND L32 < MINL13.33, L32, IIF(MINL13.20 > L33 AND L33 < MINL13.34, L33, IIF(MINL13.21 > L34 AND L34 < MINL13.35, L34, IIF(MINL13.22 > L35 AND L35 < MINL13.36, L35, IIF(MINL13.23 > L36 AND L36 < MINL13.37, L36, IIF(MINL13.24 > L37 AND L37 < MINL13.38, L37, IIF(MINL13.25 > L38 AND L38 < MINL13.39, L38, IIF(MINL13.26 > L39 AND L39 < MINL13.40, L39, IIF(MINL13.27 > L40 AND L40 < MINL13.41, L40, IIF(MINL13.28 > L41 AND L41 < MINL13.42, L41, IIF(MINL13.29 > L42 AND L42 < MINL13.43, L42, IIF(MINL13.30 > L43 AND L43 < MINL13.44, L43, IIF(MINL13.31 > L44 AND L44 < MINL13.45, L44, IIF(MINL13.32 > L45 AND L45 < MINL13.46, L45, IIF(MINL13.33 > L46 AND L46 < MINL13.47, L46, IIF(MINL13.34 > L47 AND L47 < MINL13.48, L47, IIF(MINL13.35 > L48 AND L48 < MINL13.49, L48, IIF(MINL13.36 > L49 AND L49 < MINL13.50, L49, IIF(MINL13.37 > L50 AND L50 < MINL13.51, L50, IIF(MINL13.38 > L51 AND L51 < MINL13.52, L51, IIF(MINL13.39 > L52 AND L52 < MINL13.53, L52, IIF(MINL13.40 > L53 AND L53 < MINL13.54, L53, IIF(MINL13.41 > L54 AND L54 < MINL13.55, L54, IIF(MINL13.42 > L55 AND L55 < MINL13.56, L55, IIF(MINL13.43 > L56 AND L56 < MINL13.57, L56, IIF(MINL13.44 > L57 AND L57 < MINL13.58, L57, IIF(MINL13.45 > L58 AND L58 < MINL13.59, L58, IIF(MINL13.46 > L59 AND L59 < MINL13.60, L59, IIF(MINL13.47 > L60 AND L60 < MINL13.61, L60, IIF(MINL13.48 > L61 AND L61 < MINL13.62, L61, IIF(MINL13.49 > L62 AND L62 < MINL13.63, L62, 1/0)))))))))))))))))))))))))))))))))))))))))))))))))))



-Bruce
Personal Criteria Formulas
TC2000 Support Articles
Rock1
Posted : Thursday, February 22, 2018 7:07:32 PM
Registered User
Joined: 3/16/2016
Posts: 57

Users browsing this topic
Guest-1

Forum Jump
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.