'ProjectHigh' and 'ProjectLow': grabbing them - NinjaTrader Programming | futures io social day trading
futures io futures trading


'ProjectHigh' and 'ProjectLow': grabbing them
Updated: Views / Replies:775 / 5
Created: by Trader.Jon Attachments:1

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 100,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
 

'ProjectHigh' and 'ProjectLow': grabbing them

  #1 (permalink)
Elite Member
Near the BEuTiFULL Horse Shoe
 
Futures Experience: Beginner
Platform: NinjaTrader
Broker/Data: MBTrading Dukascopy ZenFire
Favorite Futures: $EURUSD when it is trending
 
Trader.Jon's Avatar
 
Posts: 500 since Jul 2009
Thanks: 401 given, 178 received

'ProjectHigh' and 'ProjectLow': grabbing them

The Donchian Channel indicator was created by Richard Donchian. It uses the highest high and the lowest low of a period of time to plot the channel. The Donchian Channel Expansion/Contraction Ratio indie was written by cclsys (who hasnt been on the forums lately: I miss his posts) and does a projection of the channel which are ouputted as 'ProjectHigh' and 'ProjectLow'. What I would like to do is 'capture' those two values to use them in a strategy. Unfortunately I am lacking in insight into the correct way to do it efficiently.

First off, I dont want the values of 'ProjectHigh' and 'ProjectLow' as at a # of 'barsago' : I need the last few 'ProjectHigh' and 'ProjectLow' values which might have been spread out over 20 or more bars: one use would be a chop tool to see how much the values are 'stepping' from the second previous value of 'ProjectHigh' or 'ProjectLow' to the most recent value of 'ProjectHigh' and 'ProjectLow' etc: on the image are the values of three 'ProjectLow' that are representing 4 range bars of travel.

Can any kind soul at least 'notepad' what code would be best to use. I thanks much in advance for code contributions.

Image attached as it easier to show than tell lol

Trader.Jon

Attached Thumbnails
'ProjectHigh' and 'ProjectLow': grabbing them-projecthigh-projectlow-.jpg  
Reply With Quote
The following user says Thank You to Trader.Jon 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
las vegas
 
Futures Experience: Intermediate
Platform: Sierra Chart
Broker/Data: Velocity/IB
Favorite Futures: 6E
 
Posts: 1,147 since Feb 2010
Thanks: 304 given, 835 received


I am not a very good programmer, but I think you want the following,

High[HighestBar(High, 20)] or

Low[LowestBar(Low, 20)]

Someone correct me if that is wrong.

Reply With Quote
 
  #4 (permalink)
Elite Member
Near the BEuTiFULL Horse Shoe
 
Futures Experience: Beginner
Platform: NinjaTrader
Broker/Data: MBTrading Dukascopy ZenFire
Favorite Futures: $EURUSD when it is trending
 
Trader.Jon's Avatar
 
Posts: 500 since Jul 2009
Thanks: 401 given, 178 received

Is there a betterest solution that this?

Thanks for the input. I did manage to find a way to do it, but I feel that there has to be a more efficient way.

protected override void OnBarUpdate()
{
double _phibk0 = DRC(200, true, dRC_period).ProjectHigh[0];
double _phibk1 = DRC(200, true, dRC_period).ProjectHigh[1];
double _phibk2 = DRC(200, true, dRC_period).ProjectHigh[2];
double _plobk0 = DRC(200, true, dRC_period).ProjectLow[0];
double _plobk1 = DRC(200, true, dRC_period).ProjectLow[1];
double _plobk2 = DRC(200, true, dRC_period).ProjectLow[2];


// LONG Entry Condition 1:
if ( entryOrder1 == null && entryOrder2 == null
// Enters long limit order when DRC projecthigh has two steps up
&& _phibk0 > _phibk1 && _phibk1 > _phibk2

Jon


vegasfoster View Post
I am not a very good programmer, but I think you want the following,

High[HighestBar(High, 20)] or

Low[LowestBar(Low, 20)]

Someone correct me if that is wrong.


Reply With Quote
 
  #5 (permalink)
Elite Member
Near the BEuTiFULL Horse Shoe
 
Futures Experience: Beginner
Platform: NinjaTrader
Broker/Data: MBTrading Dukascopy ZenFire
Favorite Futures: $EURUSD when it is trending
 
Trader.Jon's Avatar
 
Posts: 500 since Jul 2009
Thanks: 401 given, 178 received

aahhh .. got this far ... how do I plot this?

So I did manage to get my calculations from the data but I cant figure how to plot a double value that I ended up with:

double _sUM_diff = (_sUM_diff12 - _sUM_diff7)(0);

Getting method name errors when this is tried
Add(new Plot(Color.Orange, "_sUM_diff"));

and also tried variations of this with errors in 'variables' and 'method' from the NT6.5 help files
Add(_sUM_diff(0));

Obviously I am not seeing what I should.

Any input is appreciated,
Jon

Reply With Quote
 
  #6 (permalink)
Elite Member
Near the BEuTiFULL Horse Shoe
 
Futures Experience: Beginner
Platform: NinjaTrader
Broker/Data: MBTrading Dukascopy ZenFire
Favorite Futures: $EURUSD when it is trending
 
Trader.Jon's Avatar
 
Posts: 500 since Jul 2009
Thanks: 401 given, 178 received

I thought I had something working , but when I tried to run the compiled strategy it wont show any trades... when I take out all the 'double's I put in the strategy runs and shows trades.. back to the drawing board with no idea how to make it work ... any code gurus able to take a stab at this please?

Jon

Reply With Quote

Reply



futures io > > > > > 'ProjectHigh' and 'ProjectLow': grabbing them

Thread Tools Search this Thread
Search this Thread:

Advanced Search



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

July Journal Challenge - $500 in Amazon Gift Cards!

July

Battlestations: $750 in prizes - Show us your trading desk!

August

TBA: FuturesTrader71 w/Morad Askar

Elite only
     


All times are GMT -4. The time now is 09:18 PM. (this page content is cached, log in for real-time version)

Copyright © 2018 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 2018-07-21 in 0.10 seconds with 14 queries on phoenix