ADXVMA arrows in Strategy - NinjaTrader Programming | futures io social day trading
futures io futures trading


ADXVMA arrows in Strategy
Updated: Views / Replies:2,515 / 7
Created: by hawks67 Attachments:0

Welcome to futures io.

(If you already have an account, login at the top of the page)

futures io is the largest futures trading community on the planet, with over 90,000 members. At futures io, our goal has always been and always will be to create a friendly, positive, forward-thinking community where members can openly share and discuss everything the world of trading has to offer. The community is one of the friendliest you will find on any subject, with members going out of their way to help others. Some of the primary differences between futures io and other trading sites revolve around the standards of our community. Those standards include a code of conduct for our members, as well as extremely high standards that govern which partners we do business with, and which products or services we recommend to our members.

At futures io, our focus is on quality education. No hype, gimmicks, or secret sauce. The truth is: trading is hard. To succeed, you need to surround yourself with the right support system, educational content, and trading mentors – all of which you can find on futures io, utilizing our social trading environment.

With futures io, you can find honest trading reviews on brokers, trading rooms, indicator packages, trading strategies, and much more. Our trading review process is highly moderated to ensure that only genuine users are allowed, so you don’t need to worry about fake reviews.

We are fundamentally different than most other trading sites:
  • We are here to help. Just let us know what you need.
  • We work extremely hard to keep things positive in our community.
  • We do not tolerate rude behavior, trolling, or vendors advertising in posts.
  • We firmly believe in and encourage sharing. The holy grail is within you, we can help you find it.
  • We expect our members to participate and become a part of the community. Help yourself by helping others.

You'll need to register in order to view the content of the threads and start contributing to our community.  It's free and simple.

-- Big Mike, Site Administrator

Reply
 
Thread Tools Search this Thread
 

ADXVMA arrows in Strategy

  #1 (permalink)
Elite Member
Chicago, IL
 
Futures Experience: Intermediate
Platform: NinjaTrader
Broker/Data: AGN/Rithmic
Favorite Futures: CL
 
Posts: 22 since Apr 2010
Thanks: 14 given, 1 received

ADXVMA arrows in Strategy

Revisiting the ADXVMA (the _ADXVMA_v01_5_2, to be precise) ...I regret that I'm just experienced enough of a programmer to have this make my head hurt...apologies to all if I can't see the forest for the trees...

I've been playing around with the ADXVMA, and want to incorporate certain (but not all) ADXVMA-generated arrows into my strategy, based on other conditions and such.

After looking carefully at the ADXVMA indicator code, I see that it plots an arrow on Bar[1] the instant the first tick of Bar[0] occurs (FirstTickOfBar).
if(FirstTickOfBar) DrawArrowUp(CurrentBar.ToString(), 1, val, _barColorUp);

I suppose my first question would be, what would be the point of using FirstTickOfBar (FTOB) when CalculateOnBarClose (COBC) is set to true up in the Initialize section? The ADXVMA code that does the signal calculation seems to be in the CalculateOnBarClose segment, but the code that does the arrow plotting is occurring within that conditional FirstTickOfBar statement. Why would the logic take place at the close of a bar but the plotting/drawing take place on the opening tick? Aren't the calculations that are made on past closed bars at the open of a new bar the same as calculations made on the same past closed bars at the close of the most recently-closed bar? I suppose where the next bar opens can be different from the previous close and may, in some cases, have an impact on the calculations, but is that the case here?

But more importantly, if a Strategy refers to values assigned in the indicator, how can it be coded to access those values that only exist at FTOB, when the indicator itself is set to COBC? Even if I have the Strategy set to COBC = false, those values just don't make it through. The usual way to do this would be to instantiate the indicators like this:
ADXVMA myADXVMA = ADXVMA(BarsArray[0], 5, true);

and then refer to the indicator's signals using myADXVMA.Signal[0], etc. But this just returns zeroes. The value in Signal[0] at the time the Strategy references it (and it doesn't matter if the Strategy is COBC or not) is not the value assigned at the time of the indicator's FTOB variable-assignments, a fact which is made clear by the fact that the arrow paints but the variable - pulled directly from the array - stays at 0. It's obvious that the variable pulled from the array is from a point in time after the FTOB assignment, I'm assuming at OnBarClose?

I know this is a long and rambling post, but I wanted to be clear; the ADXVMA plots an arrow at the FTOB, based on calculations that were made on COBC. How can I have a Strategy (COBC or otherwise) "get wind" of this ADXVMA FTOB value? How can I get a trigger that will fire in my Strategy in synchronization with the painting of the arrow?

Thank you in advance for indulging me,
Gary

Reply With Quote
The following user says Thank You to hawks67 for this post:
 
  #2 (permalink)
Quick Summary
Quick Summary Post

Quick Summary is created and edited by users like you... Add FAQ's, Links and other Relevant Information by clicking the edit button in the lower right hand corner of this message.

 
  #3 (permalink)
Elite Member
Frankfurt
 
Futures Experience: Intermediate
Platform: NinjaTrader
Favorite Futures: FGBL 6E B4
 
max-td's Avatar
 
Posts: 1,754 since Jun 2009
Thanks: 2,309 given, 917 received


hi Gary,
interesting topic - i also wait about some ideas
i have no solution to offer but i push it up again - maybe we get some inputs !

last year we had lots of discussions about ADXVMA here and it never was clear whats up with this thing somehow.
there are diff versions arround etc.

but you Question now belongs to the first-tickof-bar-topic - so thats a bit different i think.

wouldnt it be easier to catch the barclose for your trigger ?
it shouldnt be much different



max-td
Reply With Quote
 
  #4 (permalink)
Elite Member
Bogota, Colombia, South Americ
 
Futures Experience: Intermediate
Platform: NinjaTrader
 
Posts: 12 since Nov 2009
Thanks: 4 given, 1 received

Hi.... I have noticed an issue with the ADXVMA v01.5.2. When the OnBarClose is set to false, sometimes it draws arrows in real time correctly and sometimes the arrows appear after hitting F5 (reloading historical data), obviously after the setup is no longer useful.

Do you know who can address this issue to correct or explain the cause?

Thank you.

Reply With Quote
 
  #5 (permalink)
Elite Member
Des Moines, Iowa
 
Futures Experience: None
Platform: Ninja, TOS
Broker/Data: AMP/CQG, TOS
Favorite Futures: CL, TF, GC
 
madLyfe's Avatar
 
Posts: 1,641 since Feb 2011
Thanks: 9,217 given, 1,011 received

i am also noticing this issue.. any of the pros have any idea?

dont believe anything you hear and only half of what you see

¯\_(ツ)_/¯

(╯°□°)╯︵ ┻━┻
Reply With Quote
 
  #6 (permalink)
Site Administrator
Manta, Ecuador
 
Futures Experience: Advanced
Platform: My own custom solution
Favorite Futures: E-mini ES S&P 500
 
Big Mike's Avatar
 
Posts: 46,240 since Jun 2009
Thanks: 29,355 given, 83,237 received

This may apply -- if you set an indicator COBC = false, then a condition that may have been true during the creation of the bar (intrabar), such as a condition that would cause an arrow to be painted, may no longer be true at the end of the bar.

For example, if a bar has 500 ticks in it (regardless of bar type), then during one of those 500 ticks the condition that triggers drawing the arrow may have been true. But at the end of the bar, it was no longer true.

So when you load an indicator on a chart for the first time, each bar is calculated COBC=true. Even if you set "COBC=false", NT will calculate historical data/indicators as COBC=true. On the same token, if you press F5 to refresh data, you will see the result of COBC=true calculated data only.

Mike

Due to time constraints, please do not PM me if your question can be resolved or answered on the forum.

Need help?
1) Stop changing things. No new indicators, charts, or methods. Be consistent with what is in front of you first.
2) Start a journal and post to it daily with the trades you made to show your strengths and weaknesses.
3) Set goals for yourself to reach daily. Make them about how you trade, not how much money you make.
4) Accept responsibility for your actions. Stop looking elsewhere to explain away poor performance.
5) Where to start as a trader? Watch this webinar and read this thread for hundreds of questions and answers.
6)
Help using the forum? Watch this video to learn general tips on using the site.

If you want
to support our community, become an Elite Member.

Reply With Quote
 
  #7 (permalink)
Elite Member
Des Moines, Iowa
 
Futures Experience: None
Platform: Ninja, TOS
Broker/Data: AMP/CQG, TOS
Favorite Futures: CL, TF, GC
 
madLyfe's Avatar
 
Posts: 1,641 since Feb 2011
Thanks: 9,217 given, 1,011 received


Big Mike View Post
This may apply -- if you set an indicator COBC = false, then a condition that may have been true during the creation of the bar (intrabar), such as a condition that would cause an arrow to be painted, may no longer be true at the end of the bar.

For example, if a bar has 500 ticks in it (regardless of bar type), then during one of those 500 ticks the condition that triggers drawing the arrow may have been true. But at the end of the bar, it was no longer true.

So when you load an indicator on a chart for the first time, each bar is calculated COBC=true. Even if you set "COBC=false", NT will calculate historical data/indicators as COBC=true. On the same token, if you press F5 to refresh data, you will see the result of COBC=true calculated data only.

Mike

ya i kinda understand.. i guess i like the way it works(still testing) while in COBC=false, but is there a way to get the arrows/alerts to signal that change when the bar officially closes? see this indie seems to be two bars behind when COBC=true.. if it wasnt doing that i wouldnt really have a problem using the COBC=true since my strategy works with waiting for bars to complete before entry..

dont believe anything you hear and only half of what you see

¯\_(ツ)_/¯

(╯°□°)╯︵ ┻━┻
Reply With Quote
 
  #8 (permalink)
Site Administrator
Manta, Ecuador
 
Futures Experience: Advanced
Platform: My own custom solution
Favorite Futures: E-mini ES S&P 500
 
Big Mike's Avatar
 
Posts: 46,240 since Jun 2009
Thanks: 29,355 given, 83,237 received


madLyfe View Post
ya i kinda understand.. i guess i like the way it works(still testing) while in COBC=false, but is there a way to get the arrows/alerts to signal that change when the bar officially closes? see this indie seems to be two bars behind when COBC=true.. if it wasnt doing that i wouldnt really have a problem using the COBC=true since my strategy works with waiting for bars to complete before entry..

I can't help much with this any longer beyond what I've said already, will need to find another NT programmer. I'm sure one will come to the rescue soon enough





Mike

Due to time constraints, please do not PM me if your question can be resolved or answered on the forum.

Need help?
1) Stop changing things. No new indicators, charts, or methods. Be consistent with what is in front of you first.
2) Start a journal and post to it daily with the trades you made to show your strengths and weaknesses.
3) Set goals for yourself to reach daily. Make them about how you trade, not how much money you make.
4) Accept responsibility for your actions. Stop looking elsewhere to explain away poor performance.
5) Where to start as a trader? Watch this webinar and read this thread for hundreds of questions and answers.
6)
Help using the forum? Watch this video to learn general tips on using the site.

If you want
to support our community, become an Elite Member.

Reply With Quote
The following user says Thank You to Big Mike for this post:

Reply



futures io > > > > > ADXVMA arrows in Strategy

Thread Tools Search this Thread
Search this Thread:

Advanced Search



Upcoming Webinars and Events (4:30PM ET unless noted)

Jigsaw Trading: TBA

Elite only

FuturesTrader71: TBA

Elite only

NinjaTrader: TBA

Jan 18

RandBots: TBA

Jan 23

GFF Brokers & CME Group: Futures & Bitcoin

Elite only

Adam Grimes: TBA

Elite only

Ran Aroussi: TBA

Elite only
     

Similar Threads
Thread Thread Starter Forum Replies Last Post
need arrows for Multicharts- ADXVMA, SMI, zerolag MACD emini_Holy_Grail EasyLanguage Programming 1 January 17th, 2011 12:16 PM
ADXVMA Alert ver 1_5_1 No arrows in Realtime perryg NinjaTrader Programming 8 March 26th, 2010 10:30 AM
Creating Arrows spinnybobo NinjaTrader Programming 3 October 15th, 2009 10:45 AM
NinjaTrader strategy with wrong ADXVMA values GentleTrader NinjaTrader Programming 1 August 16th, 2009 09:37 PM
Arrows Peter NinjaTrader Programming 6 June 15th, 2009 10:19 AM


All times are GMT -4. The time now is 03:55 PM.

Copyright © 2017 by futures io, s.a., Av Ricardo J. Alfaro, Century Tower, Panama, +507 833-9432, info@futures.io
All information is for educational use only and is not investment advice.
There is a substantial risk of loss in trading commodity futures, stocks, options and foreign exchange products. Past performance is not indicative of future results.
no new posts
Page generated 2017-12-17 in 0.14 seconds with 19 queries on phoenix via your IP 107.20.115.174