NexusFi: Find Your Edge


Home Menu

 




price type code for indicatos


Discussion in NinjaTrader

Updated
      Top Posters
    1. looks_one traderTX with 6 posts (0 thanks)
    2. looks_two eDanny with 1 posts (2 thanks)
    3. looks_3 traderwerks with 1 posts (0 thanks)
    4. looks_4 Quick Summary with 1 posts (0 thanks)
    1. trending_up 3,487 views
    2. thumb_up 2 thanks given
    3. group 2 followers
    1. forum 7 posts
    2. attach_file 2 attachments




Welcome to NexusFi: the best trading community on the planet, with over 150,000 members Sign Up Now, It is Free
  • Genuine reviews from real traders, not fake reviews from stealth vendors
  • Quality education from leading professional traders
  • We are a friendly, helpful, and positive community
  • We do not tolerate rude behavior, trolling, or vendors advertising in posts
  • We are here to help, just let us know what you need
You'll need to register in order to view the content of the threads and start contributing to our community.  It's free for basic access, or support us by becoming an Elite Member -- see if you qualify for a discount below.

-- Big Mike, Site Administrator

Available coupon codes for premium Elite Membership:
  • If you are a researcher and pay attention to details, you qualify for our 10% discount - "CHARTIST"
  • If you are a veteran or in public/community service, you qualify for 15% discount - "PURPLECHART"
  • If you are 60+ years old, you qualify for our 20% discount - "WISDOM"
  • Discounts are based on the honor system. If we can't trust you to do the right thing, please move along.

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

 
Search this Thread

price type code for indicatos

(login for full post details)
  #1 (permalink)
 
traderTX's Avatar
 traderTX 
pittsburgh, pa
 
Experience: Intermediate
Platform: Ninjatrader, ensign, wave59
Broker: IB , AMP/ cqg
Trading: ES, CL
Posts: 154 since Mar 2010
Thanks Given: 54
Thanks Received: 47

hi,
most of my programming experience was back in engineering school doing fortran.
so i have heard programming got alot easier since those days.

so is it possibel to explain step by step in detail to a newbie like me how to put the price type parameter in an indicator like the stochastics that comes with ninja or the stochastics_with smoothing which is available for download on the ninja_support site?

is it as simple as going to the editor in the ninja control center and opening the indicator and sticking some code in there OR could it be done with the ninja indicator wizard?

thanks

Started this thread Reply With Quote

Can you help answer these questions
from other members on NexusFi?
Actual code for RSI using Wilders average, not the canne …
ThinkOrSwim
Strategy: second data series for using correct entry tim …
NinjaTrader
Gabriel Grammatidis
Trading Reviews and Vendors
BollingerPro discussion
The Elite Circle
ninzaco snow eagle trading
NinjaTrader
 

(login for full post details)
  #3 (permalink)
 
eDanny's Avatar
 eDanny 
East Rochester, NY
 
Experience: Intermediate
Platform: NT
Posts: 329 since Jul 2009
Thanks Given: 18
Thanks Received: 425


Try this. Open the Stochastics indicator for editing. Right click and Save As a different name. Add this in the Initialize section:

PriceTypeSupported = true;

Then look for this line:

nom.Set(Close[0] - MIN(Low, PeriodK)[0]);

and change the Close[0] to Input[0] so it looks like this:

nom.Set(Input[0] - MIN(Low, PeriodK)[0]);

Then right click, select compile, click OK and close the editor. Load the indicator on your chart and test it. Dan

Reply With Quote
The following 2 users say Thank You to eDanny for this post:
(login for full post details)
  #4 (permalink)
 
traderTX's Avatar
 traderTX 
pittsburgh, pa
 
Experience: Intermediate
Platform: Ninjatrader, ensign, wave59
Broker: IB , AMP/ cqg
Trading: ES, CL
Posts: 154 since Mar 2010
Thanks Given: 54
Thanks Received: 47

Thank you eDanny, worked on the Stochastics and Stochastics with Smoothing indicators.

i have been trying duplicate the stochastics on another charting software, Ensign, that i use. Ensign has a little different terminology for the stochastics. but i think i have all the parameters set correct. i have them close now but still something is not quite the same...

Started this thread Reply With Quote
(login for full post details)
  #5 (permalink)
 
traderTX's Avatar
 traderTX 
pittsburgh, pa
 
Experience: Intermediate
Platform: Ninjatrader, ensign, wave59
Broker: IB , AMP/ cqg
Trading: ES, CL
Posts: 154 since Mar 2010
Thanks Given: 54
Thanks Received: 47

hi eDanny,
does the code you mention in your post to me work for both Ninja 7 and 6.5 ?
i will give it a try..

ok, it seems to have worked ok with the "stochastics" indicator , that is compiled ok on ninja 7.
but the stochasticswithsmoothing indicator gives an error on compiling. even though i saved the indicator as stochasticswithsmoothing2, and only changed lines in the copy i saved.
neither stochasticswithsmoothing indicator will now compile.
perhaps because it wasnt converted to ninja7?

Trade what you see, not what you think.

"The better the mechanic, the fewer the tools"

"Futures Trading is risky and can cause substantial financial gain"
Started this thread Reply With Quote
(login for full post details)
  #6 (permalink)
 
traderTX's Avatar
 traderTX 
pittsburgh, pa
 
Experience: Intermediate
Platform: Ninjatrader, ensign, wave59
Broker: IB , AMP/ cqg
Trading: ES, CL
Posts: 154 since Mar 2010
Thanks Given: 54
Thanks Received: 47





here is what the error looks like after compiled.
do you know how to fix it ?

Trade what you see, not what you think.

"The better the mechanic, the fewer the tools"

"Futures Trading is risky and can cause substantial financial gain"
Started this thread Reply With Quote
(login for full post details)
  #7 (permalink)
 
traderTX's Avatar
 traderTX 
pittsburgh, pa
 
Experience: Intermediate
Platform: Ninjatrader, ensign, wave59
Broker: IB , AMP/ cqg
Trading: ES, CL
Posts: 154 since Mar 2010
Thanks Given: 54
Thanks Received: 47

here is a snapshot of the indicator with the error message.
i didnt realize the original didnt have an error message.

Trade what you see, not what you think.

"The better the mechanic, the fewer the tools"

"Futures Trading is risky and can cause substantial financial gain"
Attached Thumbnails
Click image for larger version

Name:	stochasticssmoothing2.JPG
Views:	165
Size:	106.2 KB
ID:	121450  
Started this thread Reply With Quote
(login for full post details)
  #8 (permalink)
 
traderTX's Avatar
 traderTX 
pittsburgh, pa
 
Experience: Intermediate
Platform: Ninjatrader, ensign, wave59
Broker: IB , AMP/ cqg
Trading: ES, CL
Posts: 154 since Mar 2010
Thanks Given: 54
Thanks Received: 47

on the line 150, i had to change the MA_Type to MA_Type2
Thanks to Ninja support CAL.
then it compiled,
and i was able to add the two lines so that types of price type , hi, lo, close, open, median could be used to calc the indicator.

Trade what you see, not what you think.

"The better the mechanic, the fewer the tools"

"Futures Trading is risky and can cause substantial financial gain"
Started this thread Reply With Quote





NexusFi Trading Community Platforms and Indicators NinjaTrader > price type code for indicatos


Last Updated on August 22, 2013


© 2023 NexusFi™, s.a., All Rights Reserved.
Av Ricardo J. Alfaro, Century Tower, Panama City, Panama, Ph: +507 833-9432 (Panama and Intl), +1 888-312-3001 (USA and Canada)
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.
About Us - Contact Us - Site Rules, Acceptable Use, and Terms and Conditions - Privacy Policy - Downloads - Top
no new posts