![]() |
|
|||||||
| Strategy Development Support for the development of custom automated trading strategies using NinjaScript. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Junior Member
Join Date: May 2009
Posts: 22
Thanks: 0
Thanked 0 times in 0 posts
|
Is there a way to determine whether an instrument is dealable or not? Something like Instrument.MasterInstrument.IsDealable? If there's no such property, what's the best practice to determine this value?
Regards, Daniel |
|
|
|
|
|
#2 |
|
NinjaTrader Customer Service
Join Date: Sep 2008
Location: Germany
Posts: 22,377
Thanks: 252
Thanked 966 times in 949 posts
|
Daniel, are you referring to tradable on the current connection you use? Generally you could check for the type of instrument and excludes indices then - http://www.ninjatrader-support.com/H...umentType.html
Bertrand
NinjaTrader Customer Service |
|
|
|
|
|
#3 |
|
Junior Member
Join Date: May 2009
Posts: 22
Thanks: 0
Thanked 0 times in 0 posts
|
Hello Bertrand,
yes I mean tradable on the current connection. I have a multi instrument strategy that analyzes several currency pairs, but some of them are not tradeable, so I get wrong results. For example: The last bar for $SGDJPY appeared today 06:00am; obviously this pair will not be tradable until next week. Regards, Daniel |
|
|
|
|
|
#4 |
|
NinjaTrader Customer Service
Join Date: Sep 2008
Location: Germany
Posts: 22,377
Thanks: 252
Thanked 966 times in 949 posts
|
Daniel, unfortunately there's no property returning this - I would limit the strategy via time filters for each symbol you intend trading with it.
Bertrand
NinjaTrader Customer Service |
|
|
|
|
|
#5 |
|
Junior Member
Join Date: May 2009
Posts: 22
Thanks: 0
Thanked 0 times in 0 posts
|
Ok, thanks. Maybe for future Versions of NT: There's a flag in Gains API "D=Status, Dealable or Referred". It would be great if this flag will become available in NinjaScripts.
Regards, Daniel |
|
|
|
|
|
#6 |
|
NinjaTrader Customer Service
Join Date: Sep 2008
Location: Germany
Posts: 22,377
Thanks: 252
Thanked 966 times in 949 posts
|
Daniel, thanks for this suggestion, appreciated.
Bertrand
NinjaTrader Customer Service |
|
|
|
|
|
#7 |
|
Junior Member
Join Date: May 2009
Posts: 22
Thanks: 0
Thanked 0 times in 0 posts
|
It's me again.
I've contacted Gain to ask them for a time table. The short answer: "There is no such table". The problem was that I was not subscribed to this pair, so NT loaded the historical data, but got no updates from the rates service. Isn't it possible to change the subscriptions at runtime depending on which pairs are used (in charts, strategies and whatever)? Regards, Daniel |
|
|
|
|
|
#8 |
|
NinjaTrader Customer Service
Join Date: Sep 2008
Location: Germany
Posts: 22,377
Thanks: 252
Thanked 966 times in 949 posts
|
Unfortunately not Daniel, those would be managed at Gain directly for your login.
Bertrand
NinjaTrader Customer Service |
|
|
|
![]() |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| How to programatically determine if I am in a trade? | DancesWithBears | Indicator Development | 2 | 08-20-2009 03:50 PM |
| Easy way to determine last bar? | terenyi | General Programming | 2 | 09-08-2008 03:44 PM |
| Determine Woodies LSMA color | Koffie | Strategy Development | 3 | 05-04-2008 11:43 PM |
| Need help to determine fastest integration method | Slimbeaux | Automated Trading | 1 | 01-08-2008 07:49 AM |
| How to determine if a bracket order completed gracefully. | mkundi | Automated Trading | 4 | 06-27-2005 08:09 AM |