This is the main callback function where all calculations for a trading system are performed and its results are updated. This callback gets called every time when one of the time series changes its data.
start();
When ActiveTick detects data change in one of TimeSeries objects, it calls this callback function to process the new data changes.
The following example demonstrates start() callback function.
function start()
{
//get current account
var account = getAccount();
//check buying power and return if it's at or below 0
if(account.getBalances().getBuyingPower() <= 0)
return;
//calculate values...
...
...
}
init(), TimeSeries Class, Account Class
Copyright © 2006-2009 ActiveTick LLC