Youtube video: My open source C++ trading platform Shim for Ubuntu Linux with MYSQL and Netbeans IDE demo
Here is my checklist of stuff:x , MYSQL , Netbeans ,IDE ,demo
Optional but required instructions below:
1. Install R onto Ubuntu
sudo apt-get update
sudo apt-get install r-base
Users who need to compile packages should also install the r-base-dev package
We need to make sure some packages are already installed before we try to compile gnuplot
libwxgtk2.8-dev – for the wxt terminal
libpango1.0-dev – for the cairo (pdf, png) and wxt terminals
libreadline5-dev – readline support (editing command lines)
libx11-dev and libxt-dev – X11 terminal
texinfo (optional) – needed for the tutorial
libgd2-xpm-dev (optional) – old png, jpeg and gif terminals based on libgd
This command (run in a terminal) will install all prerequisites if not already installed:
sudo apt-get install libwxgtk2.8-dev libpango1.0-dev libreadline5-dev libx11-dev libxt-dev texinfo libgd2-xpm-dev
Then we download and compile gnuplot (run each command/line in a terminal)
tar xzf gnuplot-4.4.0.tar.gz
mkdir build && cd build
Install Gnuplot 4.4.0 on Ubuntu Linux
Required for my Ubuntu Linux version:
sudo apt-get dist-upgrade:
sudo apt-get install mysql-server mysql-client
sudo mysqladmin -u root -h localhost password ‘mypassword’
sudo mysqladmin -u root -h myhostname password ‘mypassword’
Ruby: apt-get install ruby
To build Trading Shimm, you need the MYSQL developer RPM which is from dev.mysql.com/downloads/mysql/ or
sudo apt-get install libmysqlclient-dev
UPDATE: See below for proper installation for IB TWS in Ubuntu or any Linux/Unix
Install Interactive Brokers TWS for Ubuntu:
1. Make sure that you have a recent version of Java Runtime Environment installed.
2. Go to http://www.interactivebrokers.com/en…&ib_entity=llc and download the standalone app for unix.
3. Create a folder called “TWS” or “IB” or whatever you want in your home directory.
4. Find and right click the downlaoded file called “unixmacosx.jar” and select “Open with Archive Manager”
5. Select the two folders “IBJts” and “META-INF” and select extract
6. Navigate to the folder you just created in step 3 and extract the folders there.
7. Open up a terminal window and change directory to the folder where your IB files reside. e.g. “cd TWS” or “cd IB”
8. Change directory to the IBJts folder, “cd IBJts”
9 Then type
java -cp jts.jar:hsqldb.jar:jcommon-1.0.12.jar:jfreechart-1.0.9.jar:jhall.jar::KSother.jar:rss.jar -Xmx512M jclient.LoginFrame .
including the period at the end and you should get the login page.
10. Henceforth to launch TWS you have to follow steps 7-9
Log into TWS with:
Run TWS and then execute ./shim
Get the Trading Shim manual from http://www.tradingshim.org/pdfs/manual.pdf
Configure TWS as explained in the TradingShim manu 3.2.2 Allow Connections to the IB tws. Go under Global Configurations
Load MYSQL data as described in the manual:
Make change to \etc\mysql\my.cnf (pg 41)
In MYSQL as root, run ‘source setup.sql’ from shim’s sql directory
May need to execute examples in ‘Using the create.sql Script to Recreate the Tables’ pg 44
create.sql under sql/mys
For debugging Trading shim, I would use Netbeans IDE for C++. Coulse markfile as source of Netbeans project when import source.
Update: For MYSQL Isolation level to seriazilable, do in MYSQL shell:
set global transaction isolation level serializable;
Update: (Oct 25/2012)
If you ever see any strange problems trying to run the JAR files for IB TWS, here is a set of references to help out:
I now post my TRADING ALERTS
into my personal FACEBOOK ACCOUNT
. Don't worry as I don't post stupid cat videos or what I eat!