Also for the non programmers...the applications can be made public so non programmers can use the public of applications.. Also the app developers like in opensocial can throw ads on the screeners.
here is some example backtester code:
var hasTrade = false;
function Init() { }
function Tick() { //5-day exponential moving average var ma5=analysis.Technical.ema('AAPL', 1 , 1 , 5 );
//10-day exponential moving average var ma10=analysis.Technical.ema('AAPL', 1 , 1 , 10 );
//invalid time data because of weekend if (ma5.length == 0 || ma10.length == 0) return;
if (ma5[0].value > ma10[0].value) { //open a trade if we dont have one if (hasTrade == false) {
api.Broker.OpenTrade('AAPL',
100,
'open trade on cross');
hasTrade = true;
}
}
else if (ma5[0].value < ma10[0].value)
{
//close a trade since we have one
if (hasTrade == true)
{
api.Broker.OpenTrade('AAPL',
-1100,
'close trade on cross'); hasTrade = false;
}
}}
function Destroy() { }
Sorry Edit its tickmarkt not tickmark