Questions tagged [ibrokers]

`IBrokers` is an R package that provides a native `R` interface to Interactive Brokers Trader Workstation trading platform.

IBrokers is an R package that provides a native R interface to Interactive Brokers Trader Workstation trading platform.

75 questions
0
votes
1 answer

IBrokers Put in an Order at the Mid

I'm playing around with some ideas using R and IBrokers with a paper trading account. I'm looking at making orders through R, but was wondering if there's an easy way to make these orders at the mid price, since I'm not expecting to always buy and…
intern
  • 325
  • 1
  • 2
  • 12
0
votes
2 answers

convert triple nested list to dataframe

I'm trying to convert a triple nested list into a dataframe. This question has helped, but I can't get the dataframe I'd like. The list is an options chain obtained from IBrokers, a summary is shown below. I've uploaded the actual chain here which…
Zeus
  • 1,496
  • 2
  • 24
  • 53
0
votes
1 answer

R IBrokers algoStrategy option when submitting twsOrder

I am trying to use an Adaptive Algo from Interactive Brokers. It seems like IBrokers package for R (https://cran.r-project.org/web/packages/IBrokers/IBrokers.pdf - pg37 and 38) was not completed as my order does not go through when I execute the…
0
votes
0 answers

Using reqMktDepth for trading in R

I am trying to test an intraday trading strategy using R, and I found the IBrokers API package that sends orders to Interactive Brokers TWS platrform, which would be perfect for me. Unfortunately my programming skills aren´t good enought to get the…
Augusto
  • 51
  • 1
  • 6
0
votes
1 answer

R IBrokers (Interactive Brokers API)

Anyone has any idea how to use algoStrategy and algoParams in IBrokers package? I tried creating a list for algoParams but in vain. For example: library(IBrokers) twsOrder(reqIds(twsconn), "BUY", "10", "MKT", …
WaiLi
  • 1
  • 1
0
votes
1 answer

IBrokers - reqMktData

Has anyone tried different exchanges on IBrokers? I am trying to get either market data or historical data for stocks listed on ASX(Australian Exchange). I am subscribed to Chi-X Australia. library("IBrokers") tws <- twsConnect() security =…
0
votes
0 answers

option call put purchase with trailing stop order entry JAVA Interactive Brokers

Trying to build a simple system that buys a call if Last trades above prior hour bar high, or buys a put if Last trades below prior hour low. And when the new entry takes place an automatic trailing stop is placed at half the value of the option.…
PlacePrint App
  • 101
  • 1
  • 12
0
votes
1 answer

Parallel request historical options chain prices / Last known price in IBrokers (R)

I am trying to create Current Options Chain (options per strike, per expiration) for a ticker. library(IBrokers) tws <- twsConnect() # Lets say only Call prices AA <- reqContractDetails(tws, twsOption(local="", right="C",…
Jav
  • 2,203
  • 13
  • 22
0
votes
2 answers

How can I close an opened order on Interactive brokers after 5 seconds

I use a code (link is below) to open an order in Interactive Brokers ( I use a paper account) but when I tried to close the opened order after 5 seconds I was not able to do so.What am I doing wrong? library(IBrokers) myconid = 3 twsobj =…
mql4beginner
  • 2,193
  • 5
  • 34
  • 73
0
votes
2 answers

IBrokers reqMktData, how to get out properly?

I am just starting to use the IBrokers package and I would like to know how to get out of the reqMktData function properly once tickGenerics is filled. Thank you for your answers. For instance: library(IBrokers) PATH <- "" # initialize log file…
blueangel
  • 81
  • 4
0
votes
1 answer

R Package IBrokers placeOrder() function fails

I'm using the package: IBrokers. It works well for me when I request historical data. Also the call to reqAccountUpdates() works well. I am having problems with this script: # myscript.r .libPaths("rpackages") library(IBrokers) tws2 =…
user3676943
  • 913
  • 1
  • 13
  • 27
-1
votes
1 answer

Using R and IBrokers, what is the function to call to get the bid and ask prices of given stock symbol?

I have not much else to add other than the title. I simply need the name of the function.
-1
votes
1 answer

How to obtain Real FX Balance via IBroker

This question is related to IBroker package. There is a difference between Virtual FX Position and Real FX Position. One obtains the Virtual positions by twsPortfolioValue or nested in accDetails library(ibrokers) tws <- twsConnect() accDetails <-…
Maximilian
  • 4,177
  • 7
  • 46
  • 85
-1
votes
1 answer

Using lapply correctly

I'm working with the TWS API and it's not working for me. I got it close to doing what I want to do, but I am stuck trying to figure out how to use the lapply function correctly. Here's what I got to work currently: library("IBrokers") tws <-…
Trexion Kameha
  • 3,362
  • 10
  • 34
  • 60
-2
votes
2 answers

Swing high and low from Pine to R

I am trying to translate a Swing High and Low function from Pine to R, and I cannot really get the logic behind the Pine code. Basically, this function loops over a time series database of high and low prices, and yields: A swing high: as the…
Camilo
  • 153
  • 7
1 2 3 4
5