Wysiwyg
Everyone wants money
- Joined
- 8 August 2006
- Posts
- 8,428
- Reactions
- 284
Thanks wysiwyg and stillshort for the post.
I am still looking to automate the strategy as that is my long term objective. I am fully aware of those pitfalls but it is a good reminders nonetheless..
Hi Howard, does your book provides sample on the automated intraday trading?
I am still looking to automate the strategy as that is my long term objective. I am fully aware of those pitfalls but it is a good reminders nonetheless..
For Amibroker, I cannot find any broker arrangement to route limit/market orders etc. other than Interactive Brokers.
Another half true wisdom. The limit can be exceeded by paying a fee. It is called Quote Booster at a cost of $30/mo per pack of 100 quotes, with a maximum of 1100 quotes total. Wait, small peanuts traders and "free" dreamers are gonna cry out loud now. But yeah, IQFeed may be cheaper while having better data.I don't believe IB has accurate data feeds and it is limited to 100 symbols.
Another could be a true data feed from IQFeed or ESignal to your Amibroker and then fire the orders from that data to IB.
But yeah, IQFeed may be cheaper while having better data.
IQFeed said:Just a quick bit of additional information. We have options to get you up to 1800 symbols and the cost would only be $155 per month plus exchange fees. Our sales group can get you information and a trial on this package if you need more than 100 symbols.
It is called Quote Booster at a cost of $30/mo per pack of 100 quotes, with a maximum of 1100 quotes total.
Being a bit of a ning nong when it comes to language beyond english, I have sought assistance from those in the know. Pi Trading work with Amibroker .afl as well as other languages.Not true. AmiBroker is open architecture. You are able to build your own order routing to other brokers via AmiBroker. Besides that AmiBroker have released the source codes of IBcontroller http://www.amibroker.com/devlog/2013/06/03/ibcontroller-1-3-8-source-codes-released/ There is no "This can not be done" or "This is not possible".
So although being a peanut trader (prefer Nobby's premium mixed at $5.20 per 375grams) I do look forward to any future possibilities.On 7/04/2014 9:10 PM, Raghav Bihani wrote:
>> 1) What is possible?
>
> Removing the option of porting the code, you can use a relay application to exchange signals and orders between the client (Amibroker) and the server (IB).
>> 2) How much for a Trading Automation .afl?
>
> Unfortunately, due to current commitments and extended workload, we are not accepting new programming projects until 3rd Quarter 2014.
>
> Any further questions or comments, please do not hesitate to contact us.
>
> Regards,
>
> -- Raghav Bihani
> -- Senior Engineer
> -- Pi Trading Corporation
PS - I understand I can use the applystop function but from what I have read I wont be able to plot this on my charts... now thats no fun...
ApplyStop( stopTypeTrailing, stopModePercent, IIf( indexup, 40, 10), 0, True );
Wrong, you can plot Applystop. Where have you read that you can't? In Multicharts forum? You just have to look in AB help file (AFL function reference for example) or AB Knowledge base.
I didn't read it in the Multicharts Forum.
Hi Guys,
Can anyone help out with some advice on how to program fixed fractional position sizing?
I've been going through the manual and found this code:
TrailStopAmount = 2 * ATR( 20 );
Capital = 100000; /* IMPORTANT: Set it also in the Settings: Initial Equity */
Risk = 0.01*Capital;
PositionSize = (Risk/TrailStopAmount)*BuyPrice;
ApplyStop( 2, 2, TrailStopAmount, 1 )
But from what I can tell, this wouldn't dynamically adjust the risk based on the portfolio equity. I've found a few other posts on using the custom back tester but not sure if this would be the simplest approach as they were quite old.
Thanks for any advice you can offer.
Mike
RiskInPoints = 2.0 * ATR( 20 );
StaticVarSet( "Volatility" + Name(), RiskInPoints );
SetCustomBacktestProc( "" );
if ( Status( "action" ) == actionPortfolio )
{
// retrieve the interface to portfolio backtester
bo = GetBacktesterObject();
bo.PreProcess();
for ( bar = 0; bar < BarCount; bar++ )
{
// this retrieves current value of portfolio-level equity
Eq = bo.Equity;
// this for loop iterates through all trade signals and adjust pos size
for ( sig = bo.GetFirstSignal( bar ); sig; sig = bo.GetNextSignal( bar ) )
{
Risk = 0.01 * Eq;
Vola = StaticVarGet( "Volatility" + sig.Symbol );
sig.PosSize = Risk/Vola[bar] * sig.Price;
}
bo.ProcessTradeSignals( bar );
}
bo.PostProcess();
}
Hi Trash,
Thanks for helping me out. I can't say I entirely understand the code you have provided but I can see you are using the Custom Back Tester (a new concept for me) so I will do some more reading on the hows and whys of using it.
Thanks!
Risk = 1 / 100;
Stop = 2 * ATR( 20 ) / BuyPrice;
SetPositionSize( 100 * Risk / Stop, spsPercentOfEquity );
Well, actually in regards to what you want to achieve you don't need to use CBT.
I was just trying to show that in order to access portfolio equity (to calculate more comprehensive stuff) you need to use CBT.
The following one will do the same as the previous CBT procedure.
Code:Risk = 1 / 100; Stop = 2 * ATR( 20 ) / BuyPrice; SetPositionSize( 100 * Risk / Stop, spsPercentOfEquity );
Multiple roads lead to Rome.
Rome == AmiBroker
Hello and welcome to Aussie Stock Forums!
To gain full access you must register. Registration is free and takes only a few seconds to complete.
Already a member? Log in here.