I try whit this code, nevertheless it keeps throwing me 6 parameters
Could you help me correcting the fragment and sending it to me?

function run()
{
set(LOGFILE);
set(PARAMETERS);

StartDate=2018;
NumYears=1;

BarPeriod = 60;
LookBack = 100*5;

var TimeFactor = optimize(3,1,5,1);
var Coef = optimize(3,1,10,1);

while( asset( loop("EUR/USD","GBP/USD","AUD/USD") ) )
{
vars Price = series(price(0));
vars MA1 = series(SMA(Price,30));
vars MA2 = series(SMA(Price,30*TimeFactor));

Stop = Coef*ATR(10);

if(crossOver(MA1,MA2))
enterLong();
else if(crossUnder(MA1,MA2))
enterShort();
}
}

Thanks a lot for your time, I hope to reward you