public override void Plot VS multiple dataseries - NinjaTrader Programming | futures io social day trading
futures io futures trading


public override void Plot VS multiple dataseries
Updated: Views / Replies:1,179 / 6
Created: by AkLio Attachments:3

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
 

public override void Plot VS multiple dataseries

  #1 (permalink)
Elite Member
Canada
 
Futures Experience: Intermediate
Platform: ninja 7
Broker/Data: IB
Favorite Futures: 6E ES
 
AkLio's Avatar
 
Posts: 38 since Jun 2009
Thanks: 28 given, 65 received

public override void Plot VS multiple dataseries

Hi every1,

If some1 could help, would be much appreciated
I've written a few indicators using "public override void Plot"
... like many you'll found in the futures.io (formerly BMT) download section

My problem is that when I call 2 dataseries on the same chart of NT, the "drawing" part of the indicator freeze on the chart and, moving my scrollbar right or left have totally no effect on it... but I see everrything else moving ....

See pic attached ot try to make myself clearer... in this exemple, I redraw the candles over those of NT ... but totally frozen on the chart when I insert a second dataserie for the 5 min candles.

I guess NT dont like the "public" part of "public override void Plot", and "private" does not work ...

Thanks

Attached Thumbnails
public override void Plot VS multiple dataseries-2013-11-02-13-27-47.png  
Reply With Quote
 
  #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
Birmingham UK
 
Futures Experience: Intermediate
Platform: NinjaTrader
Broker/Data: IG/eSignal
Favorite Futures: Dax
 
ratfink's Avatar
 
Posts: 3,340 since Dec 2012
Thanks: 11,282 given, 7,092 received


It should not be any issue with 'public' - more likely the code in the Plot method is not actually doing what you expect (e.g. lock up in the 'while' statement, or not using bar offsets correctly, or attaching to the wrong data series?. Given the glimpse of ChartControl I assume you are using direct draw graphics for a specific overlay requirement which require a full redraw on every call, otherwise could you simplify the indicator to just use Ninja Draw methods?

Without seeing more of the code it is hard to suggest much else, except maybe never underestimate the usefulness of simple 'Print' calls with the Ninja Output Window opened up, frequently overlooked and often still the best spanner in the box.

Travel Well
Reply With Quote
The following user says Thank You to ratfink for this post:
 
  #4 (permalink)
Elite Member
Canada
 
Futures Experience: Intermediate
Platform: ninja 7
Broker/Data: IB
Favorite Futures: 6E ES
 
AkLio's Avatar
 
Posts: 38 since Jun 2009
Thanks: 28 given, 65 received

Thank you for your reply Ratfink

If you want to give it a try, here's a little indicator with the same kind of bug that use the

"public override void Plot(Graphics graphics, Rectangle bounds, double min, double max)"

It's a simple stochastic indicator that fills the space between the K and the D ... color is different if K > D or D > k ...

Everything work fine until you insert a second dataserie in the chart

Thanks




ratfink View Post
It should not be any issue with 'public' - more likely the code in the Plot method is not actually doing what you expect (e.g. lock up in the 'while' statement, or not using bar offsets correctly, or attaching to the wrong data series?. Given the glimpse of ChartControl I assume you are using direct draw graphics for a specific overlay requirement which require a full redraw on every call, otherwise could you simplify the indicator to just use Ninja Draw methods?

Without seeing more of the code it is hard to suggest much else, except maybe never underestimate the usefulness of simple 'Print' calls with the Ninja Output Window opened up, frequently overlooked and often still the best spanner in the box.


Attached Thumbnails
public override void Plot VS multiple dataseries-2013-11-03-15-57-28.png  
Attached Files
Register to download File Type: cs LioStochBand2.cs (15.8 KB, 19 views)
Reply With Quote
 
  #5 (permalink)
Elite Member
Birmingham UK
 
Futures Experience: Intermediate
Platform: NinjaTrader
Broker/Data: IG/eSignal
Favorite Futures: Dax
 
ratfink's Avatar
 
Posts: 3,340 since Dec 2012
Thanks: 11,282 given, 7,092 received

Hi,

I'm not able to test anything now, but it should be ok if you just add:

 
Code
if (BarsInProgress != 0)
    return;
at the beginning of the Plot method (and for most also in OnBarUpdate), that will stop the second (or more) data series getting involved.

Cheers

Travel Well
Reply With Quote
 
  #6 (permalink)
Elite Member
Canada
 
Futures Experience: Intermediate
Platform: ninja 7
Broker/Data: IB
Favorite Futures: 6E ES
 
AkLio's Avatar
 
Posts: 38 since Jun 2009
Thanks: 28 given, 65 received

I tried without success ...
Thanks anyway for your help !
Lio


ratfink View Post
Hi,

I'm not able to test anything now, but it should be ok if you just add:

 
Code
if (BarsInProgress != 0)
    return;
at the beginning of the Plot method (and for most also in OnBarUpdate), that will stop the second (or more) data series getting involved.

Cheers


Reply With Quote
 
  #7 (permalink)
Elite Member
Birmingham UK
 
Futures Experience: Intermediate
Platform: NinjaTrader
Broker/Data: IG/eSignal
Favorite Futures: Dax
 
ratfink's Avatar
 
Posts: 3,340 since Dec 2012
Thanks: 11,282 given, 7,092 received


AkLio View Post
I tried without success ...
Thanks anyway for your help !
Lio

Yes, sorry, was just turning in for sleep and realised what I posted is for multi-instrument series using the 'Add()' method and not multi-dataseries added from the GUI, I will have a look when I can test tomorrow unless one of the other serious C#'ers solves it before then.

Travel Well
Reply With Quote
The following user says Thank You to ratfink for this post:

Reply



futures io > > > > > public override void Plot VS multiple dataseries

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
Multiple dataseries Breakout NinjaTrader 28 March 30th, 2015 01:14 PM
Setting multiple dataseries using a for loop Xav1029 NinjaTrader Programming 3 August 28th, 2012 09:05 AM
Combining multiple instruments to a single plot Big Mike MultiCharts 5 April 22nd, 2012 04:53 AM
Multiple dataseries intrabarpersist ohlc Big Mike EasyLanguage Programming 17 December 27th, 2011 01:14 AM
Need help with order entry on multiple dataseries bobbakerr EasyLanguage Programming 20 August 29th, 2010 10:03 AM


All times are GMT -4. The time now is 05:45 AM.

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.10 seconds with 20 queries on phoenix via your IP 54.82.81.154