Page 1 of 1

DAX (GER30) and CAC40 index

PostPosted: Fri May 10, 2019 1:41 pm
by isamegrelo
Please create trading strategy with this description:

//@version=2
//study(title="True Strength Index Strategy")
strategy("Index Strategy", overlay=true)

fast=input(5)
slow=input(12)
v1=security('DAX',period,close)
v2=security('CAC40',period,close)
dax=(v1)/1
cac=(v2)/1
dax=tsi(dax,fast,slow)
cac=tsi(cac,fast,slow)

Take_Profit = input(200)
Stop_Loss = input(250)

longCondition = crossover(dax, cac)
if (longCondition)
strategy.entry("LongEntry", strategy.long)
strategy.exit("LongExit", "LongEntry", profit = Take_Profit, loss = Stop_Loss)

shortCondition = crossunder(dax, cac)
if (shortCondition)
strategy.entry("ShortEntry", strategy.short)
strategy.exit("ShortExit", "ShortEntry", profit = Take_Profit, loss = Stop_Loss)

Re: DAX (GER30) and CAC40 index

PostPosted: Sat May 11, 2019 5:53 am
by Apprentice
Your request is added to the development list under Id Number 4652

Re: DAX (GER30) and CAC40 index

PostPosted: Sat May 11, 2019 6:48 am
by Apprentice