Need to build in a very cost-efficient a simple program that can trade two stocks , one long and one short (pairs trading) through the interactive brokers API. To give you an idea please take a look at [url removed, login to view], you can download it to get an idea. [url removed, login to view] is also another free reference point. Must have GUI
Core details version 1.
1. Must be able to enter two symbols and divide one into the other to obtain its ratio. (Stock A / stock B) and enter a mean/moving average and software will track the pair ratio for extreme standard deviations (STD) from the mean. Mean/moving average must be customizable for each pair., mean/average and std. Verson one will trade on daily bars but update in real time through the day. Would like ability to trade via 15 minbars and 60 min bars as well if possible so I can experiment. Also must be able to run multiple versions of itself set to different settings.
2. information/data shown on page will be
stock 1, stock 2, price 1, price 2, delta/std,% from mean, correlation, cointegration, ratioi, volatility, rs or ratio, rs spread between the two stocks.
3...columns must be sortable & lookback period for all must be customizable and settings saved so I dont have to keep entering settings when software loads.
4..Entry- ability to enter when set STD has been breached and ability to layer at least 5 layers. EXAMPLE: set buys to happen STD 2.0 , 3.0 3.8 or whatever I set to. If I only set one layer other not in use.
5. Ability to enter a dollar amount and software will figure out via real time quotes how many shares to buy/short. EXAMPLE. 10,000 to trade. Software will divide by 2 and enter 5000 long, 5000 short and will figure out amount of shares to buy.
6...stop loss. ability to set stop loss by % loss of trade or dollar loss. Remember one trade = 2 stocks.
7. Profit exit: ability to tell software to exit when STD reverts to a certain point. either 0, or .5 or .1.0. must be customizable to any.
8. must keep records reflecting profit/loss, % wiln to loss etc.. for all trades, . the more stats the better.
9. must be able to turn off autotrade and let it run on manual trade.