[R-SIG-Finance] ibrokers - problems retrieving Indices/ETFs

Matti Zemack matti.zemack at gmail.com
Tue Mar 19 22:47:44 CET 2013


Hi all,


First of all; Thanks Jeff for the ibrokers package. It's amazing.

My simple first code looks like Jeffs demo;

library(IBrokers)
tws <- twsConnect()
spy.csv <- file("SPY.csv", open="w")
reqMktData(tws, twsEquity("SPY", exch="ARCA"), eventWrapper=eWrapper.MktData.CSV(1), file=spy.csv)

Working perfectly fine.

Now I try to read an Index/ETF from ibrokers to file. I get "2 1 300 Can't find EId with tickerId:1"
reqMktData(tws, ttwsEquity("SPX", exch="CBOE"), eventWrapper=eWrapper.MktData.CSV(1), file=spy.csv)
I had this problem also previously for the first request, and then simply subscribing to correct data feed at IB helped me out. Newbie fault.
This time I suspect I don't receive data is because twsEquity/twsSTK isn't made for Indices/ETFs. If this is so; could someone please nudge me some pointers to where in iBrokers package I could start trying to fix this.


Thanks and Regards,
Matti Zemack

-----
Matti Zemack, Broadcast Technology, Stockholm, Sweden
matti.zemack at gmail.com



More information about the R-SIG-Finance mailing list