![]() |
This website will be down for maintenance from Friday May 24th at 6PM MDT until Saturday May 25th at 11AM MDT. We apologize for the inconvenience. If you need assistance during this time, please email sales@ninjatrader.com
|
|||||||
| Indicator Development Support for the development of custom indicators using NinjaScript. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Senior Member
Join Date: May 2008
Posts: 221
Thanks: 12
Thanked 2 times in 2 posts
|
I'm would like to add bid / ask data to a current indicator. Does anyone know how I can address this data within my existing formula?
Thanks for your time. Safetrading |
|
|
|
|
|
#2 |
|
NinjaTrader Product Manager
Join Date: May 2007
Location: Denver, CO
Posts: 17,458
Thanks: 1
Thanked 106 times in 70 posts
|
Try GetCurrentBid() and GetCurrentAsk(). You may also want to build your own Level II book. Check this reference sample out: http://www.ninjatrader-support.com/v...ead.php?t=3478
Josh
NinjaTrader Customer Service |
|
|
|
|
|
#3 | |
|
Senior Member
Join Date: May 2008
Posts: 221
Thanks: 12
Thanked 2 times in 2 posts
|
Quote:
Thanks for the reply. I tried your suggestion above and also looked at the referenced zip file, but to no avail. Here is the line I edited with your suggestion above; UpperBand.Set(Bollinger(GetCurrentAsk()-GetCurrentBid().Avg, 2, 34).Upper[0]); This line gives me this error; CS0117, which states; 'double' does not contain a definition for 'Avg' Any thoughts? |
|
|
|
|
|
|
#4 |
|
NinjaTrader Product Manager
Join Date: May 2007
Location: Denver, CO
Posts: 17,458
Thanks: 1
Thanked 106 times in 70 posts
|
You can't do it like that because Get() are not DataSeries. You can only call DataSeries objects from that parameter in the Bollinger(). If you wish to still call this spread calculation you will need to make your own DataSeries containing that calculation. Please see the help guide article for DataSeries objects.
Josh
NinjaTrader Customer Service |
|
|
|
|
|
#5 | |
|
Senior Member
Join Date: May 2008
Posts: 221
Thanks: 12
Thanked 2 times in 2 posts
|
Quote:
Thanks Josh, I'll look up the data series. |
|
|
|
|
![]() |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Volume Spike Indicator | RK_trader | Indicator Development | 8 | 12-08-2011 06:10 AM |
| Institutional Volume Indicator | Chicago | Miscellaneous Support | 3 | 08-29-2009 06:33 PM |
| Volume Delta Indicator | Robotman | Charting | 21 | 10-19-2008 10:52 AM |
| Buy/Sell Volume indicator not working properly | Pipqueen | General Programming | 1 | 12-26-2007 06:39 PM |
| Color Volume Bars Indicator (Download) Version 5 Only | awuit | Indicator Development | 3 | 11-29-2007 04:25 PM |