## New version 18 available now

Subscription & data-feed pricing Class schedule

Margin rates Stock & option commissions

 speed Rate this Topic:
 Previous Topic · Next Topic Watch this topic · Print this topic ·
caution
 Posted : Monday, January 09, 2017 2:48:20 PM
Platinum Customer

Joined: 5/5/2010
Posts: 183

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 09, 2017 2:58:16 PM

Worden Trainer

Joined: 10/7/2004
Posts: 62,474

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 09, 2017 3:10:44 PM
Platinum Customer

Joined: 5/5/2010
Posts: 183

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 09, 2017 3:17:46 PM

Worden Trainer

Joined: 10/7/2004
Posts: 62,474

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
Platinum Customer

Joined: 5/5/2010
Posts: 183

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: 62,474

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 Customer Training & Support - Ask a Trainer - TC2000 version 12/18 - Ask a Trainer - TC2000 version 7 - Ask a Trainer - StockFinder 5.0 - PCFs, EasyScan and Custom Indicators General Discussions - Stock and Market Talk - TC2000 version 12 or 18 - TC2000 version 7 - StockFinder 5.0 - RealCode for StockFinder 5.0 Tutorial Videos - TC2000 version 12 tutorial videos - TC2000 version 7 tutorial videos 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.