Welcome Guest, please sign in to participate in a discussion. Search | Active Topics |

speed Rate this Topic:
Previous Topic · Next Topic Watch this topic · Print this topic ·
caution
Posted : Monday, January 9, 2017 2:48:20 PM
Registered User
Joined: 5/5/2010
Posts: 185

Bruce,

Can you assist me in writing a code (Speed = Distance / Time) that can be used with any indicator.

If the indicator is moving up the result should be positive speed, if the indicator is moving down then negative speed.  The output should be numerical values.

Bruce_L
Posted : Monday, January 9, 2017 2:58:16 PM


Worden Trainer

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

How do you want this to differ from the Rate of Change (Net) of Indicator, Rate of Change (Percent) of Indicator or Linear Regression Slope of Indicator indicators.



-Bruce
Personal Criteria Formulas
TC2000 Support Articles
caution
Posted : Monday, January 9, 2017 3:10:44 PM
Registered User
Joined: 5/5/2010
Posts: 185

The issue with above child indicators are the numbers itself, if the indictor pivots then moves up i would prefer the value to be a positive number reather than a negative number that is increasing. 

Bruce_L
Posted : Monday, January 9, 2017 3:17:46 PM


Worden Trainer

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

If you set the period of the ROC indicators to 1 or the linear regression slope to 2, then they will always be positive when moving up and negative when moving down right after it changes direction.

So if you are only interested in one bar to the next, you should be able to use any one of those three indicators.

However if you want to cover more than one bar, I need to know exactly how you want to calculate "speed" an a way that you would get what you want.



-Bruce
Personal Criteria Formulas
TC2000 Support Articles
caution
Posted : Thursday, January 12, 2017 3:02:55 PM
Registered User
Joined: 5/5/2010
Posts: 185

Is it possible write the code using this formula for any indicator of choice? (+/-)

 

acceleration = ((final velocity) - (initial velocity)) = (change in velocity)

                                            time                                   time

 

 

Bruce_L
Posted : Thursday, January 12, 2017 3:10:17 PM


Worden Trainer

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

Unless I'm misunderstanding (which I obviously did the first time), you should be able to just apply a Rate of Change (Net) of Indicator, Rate of Change (Percent) of Indicator or Linear Regression Slope of Indicator to your chosen indicator. Then apply a Rate of Change (Net) of Indicator (but not the % version) or Linear Regression Slope of Indicator to the first indicator you used to measure speed or velocity.



-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.