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 |

accel Rate this Topic:
Previous Topic · Next Topic Watch this topic · Print this topic ·
0002ct
Posted : Tuesday, May 9, 2017 1:27:43 PM
Registered User
Joined: 11/19/2015
Posts: 459

Hello.

Yesterday you helped me create a calcuation for absolute price change averaged over a lookback:

100 * GREATEST(ABS((C / L3) ^ (1 / 3) - 1), ABS((C / H3) ^ (1 / 3) - 1))
|
100 * GREATEST(ABS((C / MINL4) ^ (1 / 3) - 1), ABS((C / MAXH4) ^ (1 / 3) - 1))

I'm looking for a way to use the above to lay the groundwork for defining a state change. The above could be thought of as the "absolute velocity" of the stock over n (3 above) bars. Using it, I'd like to scan for issues that:

on last close, have an absolute velocity x% greater than the prior 3-period-averaged "absolute velocity".  X in this case would be configurable by me in the formula, but just use 20% as an example.

I would call this change of state comparing the most recent price change to the "3-period average absolute price velocity" acceleration.
 
Thank you for any thoughts on how to calcuate this.
 
Bruce_L
Posted : Tuesday, May 9, 2017 1:38:33 PM


Worden Trainer

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

I am not sure if "on last close" includes the current bar or not. If it does, then the net change (which is already expressed in as a %) in the first formula would be:

100 * (GREATEST(ABS((C / L3) ^ (1 / 3) - 1), ABS((C / H3) ^ (1 / 3) - 1)) - GREATEST(ABS((C1 / L4) ^ (1 / 3) - 1), ABS((C1 / H4) ^ (1 / 3) - 1)))

The 1 bar ago version of this would be (if you want to wait for the bar to complete):

100 * (GREATEST(ABS((C1 / L4) ^ (1 / 3) - 1), ABS((C1 / H4) ^ (1 / 3) - 1)) - GREATEST(ABS((C2 / L5) ^ (1 / 3) - 1), ABS((C2 / H5) ^ (1 / 3) - 1)))

And the net change in the second formula would be:

100 * (GREATEST(ABS((C / MINL4) ^ (1 / 3) - 1), ABS((C / MAXH4) ^ (1 / 3) - 1)) - GREATEST(ABS((C1 / MINL4.1) ^ (1 / 3) - 1), ABS((C1 / MAXH4.1) ^ (1 / 3) - 1)))

With the 1 bar ago version of that being the following.

100 * (GREATEST(ABS((C1 / MINL4.1) ^ (1 / 3) - 1), ABS((C1 / MAXH4.1) ^ (1 / 3) - 1)) - GREATEST(ABS((C2 / MINL4.2) ^ (1 / 3) - 1), ABS((C2 / MAXH4.2) ^ (1 / 3) - 1)))

Just add a > 20 to the end to check for the acceleration to be greater than 20. So as an example, the first formula would become:

100 * (GREATEST(ABS((C / L3) ^ (1 / 3) - 1), ABS((C / H3) ^ (1 / 3) - 1)) - GREATEST(ABS((C1 / L4) ^ (1 / 3) - 1), ABS((C1 / H4) ^ (1 / 3) - 1))) > 20



-Bruce
Personal Criteria Formulas
TC2000 Support Articles
0002ct
Posted : Tuesday, May 9, 2017 1:43:45 PM
Registered User
Joined: 11/19/2015
Posts: 459

I have no idea how you do this so fast. Well, I have half an idea.  ;)  I'll test these over a couple of days.

As always, your help and expertise are deeply appreciated.

Thanks again, Bruce. 

Bruce_L
Posted : Tuesday, May 9, 2017 2:14:57 PM


Worden Trainer

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

You're welcome.



-Bruce
Personal Criteria Formulas
TC2000 Support Articles
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.