开云体育

ctrl + shift + ? for shortcuts
© 2025 开云体育

Re: Pulling reqMktData for multiple tickers


 

Victems of Python?
Regarding this discussion, I recalled, how `IB-Ruby` does it:

# define symbos
> symbols = %W( ANW? AEB? AED? AEG? AEH AER? HIVE AJRD AET? AMG? AFL? MITT? AGCO? A? AEM? ADC? AL? APD? AYR )
# put into a file-database
> IB::Symbols.allocate_collection :w20????????????????????????????????????????????
? => IB::Symbols::W20
> symbols.each_with_index{ |s,i| IB::Symbols::W20.add_contract i, IB::Stock.new( symbol: s? ) }
# call threaded market-price method and wait for all threads to finish
> prices = Symbols::W20.map{|x| x.market_price(thread: true )}.each( &:join);

Documentation:
https://ib-ruby.github.io/ib-doc/market_price.html

Join [email protected] to automatically receive all group messages.