Quick and Easy Script - with user inputs

MQL4 스크립트

명시

Hi i know this will be quick and easy for some people.

I need a script that does tthe following:

User Inputs:
Pair = user can input pairs , separated by "/" or a separator of your choosing
TimeFrame = WEEKLY
Breakout %
Stop Loss %
Account Risk per Trade (based on SL)

very simply,

For each PAIR in the PAIR range (user input)
Take Previous Week Candle (Candle[1]) High and Low Range
Place Buy Stop at Current Price + Breakout%(user input) x Candle[1] High Low Range, with SL of Stoploss%(user input) x Candle[1] High Low Range
Place Sell Stop at Current Price -  Breakout%(user input) x Candle[1] High Low Range, with SL of Stoploss%(user input) x Candle[1] High Low Range

Order Size will be based off Account Size and the risk per trade (user input) 

thats it...   

 for example
if GBPUSD was in the pair range

GBPUSD Weekly Candle [1] (previous candle) High Low Range is 200 pips
Breakout %(user input) is 30%
Stop Loss %(user input) is 20%
Account Risk % is 1%, assume current account size is $5000

then

Buystop will be CurrentPrice + 0.30x200, with a StopLoss of 0.20x200
Sellstop will be CurrentPrice - 0.30x200, with a StopLoss of 0.20x200

Order Size will be 1% of $5000 = $50 = the StopLoss (0.20x200) = 40 pips

easy? 

응답함

1
개발자 1
등급
(190)
프로젝트
233
56%
중재
13
15% / 54%
기한 초과
43
18%
무료
2
개발자 2
등급
(328)
프로젝트
538
66%
중재
53
21% / 40%
기한 초과
169
31%
무료
게재됨: 1 코드
3
개발자 3
등급
(106)
프로젝트
314
49%
중재
42
52% / 19%
기한 초과
22
7%
무료
4
개발자 4
등급
(64)
프로젝트
144
46%
중재
19
42% / 16%
기한 초과
32
22%
무료

프로젝트 정보

예산
10 USD
기한
에서 1  2 일