I think you need to do this on a custom backtest level, something like (see
below). You need to process the backtest per bar, regards Ed
SetCustomBacktestProc("");
if( Status("action") == actionPortfolio ) {
bo = GetBacktesterObject();
bo.PreProcess();
for( bar = 0; bar < BarCount; bar++ ) {
bo.ProcessTradeSignals( bar );
// in here you need to do your calculations using
bo.Equity;
}
}
bo.PostProcess();
}
----- Original Message -----
From: Ara Kaloustian
To: AB-Main
Sent: Saturday, September 20, 2008 3:11 AM
Subject: [amibroker] Backtest - Portfolio Equity
Trying to use feedback from portfolio equity to control position size.
Portfolio level equity obtaines its value after backtest is complete. I tried
to use add to composite to accumulate portfolio equity, but it gets reset with
each new ewquity ... so value is same as individual equity.
How would one get portfolio equity before the end of backtest .... or am I
missing something?
Ara