我尝试将TWS(Interactive Broker的交易应用程序)与R中的测试脚本连接起来。
library (IBrokers)
tws <- twsConnect()
aapl.csv <- file("AAPL.csv", open="w")
reqMktData (tws, twsSTK("AAPL"), eventWrapper = eWrapper.MktData.CSV(1), file = aapl.csv)
close(aapl.csv)
close(two)
我收到了错误消息。我可以检索历史数据&#34; AAPL&#34;从TWS成功。请告知该计划有什么问题。
2 -1 2104 Market data farm connection is OK:hfarm
2 -1 2104 Market data farm connection is OK:jfarm
2 -1 2104 Market data farm connection is OK:eufarm
2 -1 2104 Market data farm connection is OK:usfuture
2 -1 2104 Market data farm connection is OK:cashfarm
2 -1 2104 Market data farm connection is OK:usfarm.us
2 -1 2104 Market data farm connection is OK:usfarm
2 -1 2106 HMDS data farm connection is OK:ilhmds
2 -1 2106 HMDS data farm connection is OK:fundfarm
2 -1 2106 HMDS data farm connection is OK:ethmds
2 -1 2106 HMDS data farm connection is OK:ushmds
2 1 354 Requested market data is not subscribed.AAPL NASDAQ.NMS/TOP/ALL
谢谢。
答案 0 :(得分:0)
纸质帐户上的订阅反映了真实帐户的订阅。以下是可能导致该错误的一些事项:
1.您没有在真实账户上支付纳斯达克的订阅费用。
2.您的真实账户目前正在使用订阅,而您正试图在您的纸质账户上请求数据。你不能两者兼顾。