Welcome to NexusFi: the best trading community on the planet, with over 150,000 members Sign Up Now for 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
(If you already have an account, login at the top of the page)
You are right, I have not answered your original question.
So let us assume that you have a Bollinger indicator BollingerIND that uses a moving average and you want to call this moving average from within your standard deviation indicator StdDevIND. That is pretty simple, just call it:
I had to modify the original Bollinger Band indicator, because for unknown reasons for each of the properties there is a line preventing serialization, so the StdDevIND indicator could not be exported.
Indicators and chart attached.
Can you help answer these questions from other members on NexusFi?
[The XmlIgnore()] has an impact on exporting indicators. If you leave this command in front of a property, the indicator will not be automatically called, when it is exported.
Example: The Bollinger indicator has the [XmlIgnore()] command set for all its DataSeries, as shown below
If another indicator calls Bollinger.Middle, this indicator cannot be exported via File -> Utilities -> Export NinjaScript,
unless
you select Bollinger manually and add it to the file list to be exported.
This behaviour is caused by [XmlIgnore()] for whatever reasons. Referencing of other indicators that do not contain this command is no problem, NinjaTrader will add them automatically when exporting.
File below could be exported by adding Bollinger manually.
Hallo Fat Tails
thanks again for your last .cs - files.
this thread become more and more interesting for me....
checking your files gives me some new ideas and questions about visability and accessibility of DataSeries
Your last Indicator (StdDevIND) would be perfect, if I could put the desired Moving-Average-Dataseries in the Statement, which calls the modified StdDev. Something like:
double StdDevValue = StdDevInd(maseries, period);
For my customized Bollinger-Band I use a special Method for that purpose:
Unfortunaly the StdDev shows unexpected behavior:
The Chart shows the "StdDev-Bands" for a SMA (the orange-one) and a "faster" MA (the yellow-one).
I suppose, that the differences between Datas and the MA becomes smaller, by using a faster MA. The opposite is true!
It is nice to playing around with that new anaBollinger - but I personaly think, that the SMA is more or less the best choice for playing with the Bands.