Вы находитесь на странице: 1из 58

1

2004 22

FOREX MAGAZINE 2004

2004 22

" " 18 2004 . ................................... 3


........................................................................... 5
................................................................................................... 7
FIBO ................................................................................................................................. 8
FOREX .............................................................................. 11
? ................................................................................................................................. 18
VIAC.RU " " .............................. 20
GBPUSD 21.06.2004 ................................................................................................................. 23
............................................................................................. 29
. . .......................................................................................................... 33
: ............................................................................................. 35
.......................................................................................................... 38
(PVO) ................................................................................................. 40
.................................................................................................. 44
...................................................................................................................................... 45
MQL 4: . .............................................................................................. 51
MetaTrader. 20 ............................................................................ 54
FOREX MAGAZINE

www.alpari-idc.ru
(095) 29-111-29

FOREX MAGAZINE 2004

" " 18 2004 .

2004 22

" " 18 2004 .


, "" . .
!
18 2004 "
".


.

, 16 . .
-

, ,
, ,
.
,
, ,
,
. .
,
,
, "" , . , 2007 .

.
10 000
, ,
3 000 ,
.
"".


. ,
-
, "" . , (
,
) .
, 18 2004 .
FOREX . 75 ,
, FATF ( ).
, , . 19 2005 -

FOREX MAGAZINE 2004

" " 18 2004 .

2004 22

, .
. 2007
. ,
,
( 25%
,
).
. ,
18 2004 , 115 ,
,
- , .
, - . ,
" ",
4
,
. , . :
, , , .
:

,
.
, .
"" "" ., , .
"" www.alpari.org , "" ,
.

FOREX MAGAZINE 2004

2004 22

FOREX Review

(GMT)

21.06.2004

19:30

Mexico

April Retail Sales

N/A

3.70%

N/A

1.50%

N/A

3.80%

N/A

0.20%

N/A

1.60%

N/A

0.20%

N/A

1.80%

N/A

0.60%

N/A

3.58%

N/A

1.10%

N/A

1.00%

N/A

-0.10%

N/A

0.20%

N/A

-M$483M

2.00%

-2.90%

.
22.06.2004

6:45

France

May Construction Spendings M/M

.
22.06.2004

6:45

France

May Construction Spendings Y/Y

.
22.06.2004

11:00

Canada

May CPI M/M

.
22.06.2004

11:00

Canada

22.06.2004

11:00

Canada

May CPI Y/Y

.
May CPI Ex Core 8 M/M

.
22.06.2004

11:00

Canada

May CPI Ex Core 8 Y/Y

.
22.06.2004

12:30

Canada

May Leading Indicators

.
22.06.2004

19:30

Mexico

May Unemployment

.
22.06.2004

23:50

Japan

May All Industry Index

.
22.06.2004

23:50

Japan

May Tertiary Index

.
23.06.2004

7:30

Italy

April Retail Sales M/M

.
23.06.2004

7:30

Italy

April Retail Sales Y/Y

.
23.06.2004

19:30

Mexico

May Trade Balance

.
24.06.2004

12:30

US

May Durable Orders

, ,
.
.
24.06.2004

14:00

US

May Help-Wanted Index

N/A

38

N/A

1093K

N/A

-0.10%

N/A

-0.30%

.
24.06.2004

14:00

US

May New Home Sales

.
24.06.2004

23:30

Japan

June Tokyo CPI (M/M)

.
24.06.2004

23:30

Japan

June Tokyo CPI (Y/Y)

www.forexreview.ru

FOREX MAGAZINE 2004

2004 22

24.06.2004

23:30

Japan

May CPI (M/M)

N/A

-0.30%

N/A

-0.40%

N/A

0.20%

N/A

2.80%

N/A

96.1

N/A

94.4

N/A

97.8

2.60%

2.60%

+4.5%A

4.40%

.
24.06.2004

23:30

Japan

May CPI (Y/Y)

.
25.06.2004

7:30

Italy

May Hourly Wages M/M

.
25.06.2004

7:30

Italy

May Hourly Wages Y/Y

.
25.06.2004

8:00

Germany

June IFO Business Climate

.
25.06.2004

8:00

Germany

June IFO Current Cond.

.
25.06.2004

8:00

Germany

June IFO Expectations

.
25.06.2004

12:30

US

Q1 Chain Deflator-Final

.
25.06.2004

12:30

US

Q1 GDP-Final

. " " .
, .
25.06.2004

12:30

Canada

April Retail Sales

N/A

1.20%

N/A

6.64M

.
25.06.2004

14:00

US

May Existing Home Sales

www.forexreview.ru

FOREX MAGAZINE 2004

:
,
, , , .


, . ,
,
.


,
- . ,
,
, .
, .
, .
.
. ,
6 .
.
25 ,
, .

2004 22

, ,
,
.

,
144.9 . . , . /
1.2100, / 109.00.
21 25
, ,

. , ,
, , .


ZEW () Ifo (). ,

(), ..
.
, . ,
/ 108.55, .
.

ForexMagazine
http://www.fxclub.org


. ,

FOREX MAGAZINE 2004

2004 22

FIBO

FOREX FIBO

.

. , , . , ,

.
(ISM)
. ISM 62.8
62.4 , ISM
65.2 68.4. 50.0 . ,
.

, , 25 .
, ,
.
.
1.0%, 45 ,
.
200,000 ,

.
, 90.00 88.80/00. ,
88.40 -

84.50 92.35,
.

.
87.00 .
, ,
1.2140-1.2300.
2.0%. ,

.
, (PMI)
54.7 53.8
54.0 53.3 , ,
, .
0.6%
1.3%
.
-

9.0%. , . ,

.


. . ,
,
, 1.2400/
20. 1.2500/50

FOREX MAGAZINE 2004

FIBO

2004 22

,

.

1.2140 1.2000/30 .


.
,
. 1.8490, 1.8290-1.8450. 55.6 55.2
. 56.3 57.6,
57.4 59.0.

, ,
1.0 . ,
985 . , .

.
127,000 124,000.
.
,
,
, . ,
.
. 1.8600 1.8090/115.
1.8400/30.

, , -

FOREX MAGAZINE 2004

2004 22

FIBO

. 109.00
, -
111.50 .
, .
- 233.7 . .
4.6% . , ,
.
. , Morgan
Stanley, , - . , .
. .
, .

112.40/60 113.00 ,
/ 111.30.
,
.
, / 109.00
108.30.


FIBO
Forex Magazine
http://www.fibo-forex.ru

10

FOREX MAGAZINE 2004

2004 22

FOREX

FOREX
-
-
(www.forextrader.ru), ,

. -
, Forex.

, , ,
. - , ,
- ,
, .


(14 - 18 2004)

EUR
CHF
GBP
JPY
CAD
AUD

FOREX
21-25.06.2004


FOREX, MSK

12:00-14:30
16:00-22:00


- .

10:00-14:30
16:00-22:00

03:00-09:30
10:00-14:30
16:00-22:00

"" .

( ),
. , , CHF, .

16-30 ,
, .
.
3

11

BoJ, . 10
12 - , 16-30 18-00
.

FOREX MAGAZINE 2004

2004 22

FOREX

EUR

1.2131. 1.2179-82.

- 1.2166-70,
.
- 1.1950.

CHF

,
1.2429.

12

, , , 1.2473.
- 1.2700.

FOREX MAGAZINE 2004

2004 22

FOREX

GBP

.

. - 1.8483-88.
- 1.7478.

,
1.8380. 1.8468-73, - 1.8033.

JPY

, 108,71. -
103,37, - 114,89-93.

13


108,62,
.

FOREX MAGAZINE 2004

2004 22

FOREX

- . :
- ,

. ,
, 4
: 1.1215-1.0289. 4
, 5 . , ! ,
- 5 - 1.39341.5580. ,
, - .

1.1396-1.0815.
, 4-
.

14

. ,
1.1700 - 1.1065, ,
. - .
1.0445-0,9264.

,
3
1.2190, 1.21111.2058. 4 ,
1.2194-1,2245. - , , , 1.10651.0445.

FOREX MAGAZINE 2004

FOREX

2004 22

. CHF
0,5109 - 5 -
, 3
1,0475, - 0,6270,
- 4 1.3296-1.4043 , 1.4900.

, 5
, , CHF 1.0830-0,8792.
- 4 - 1.3296-1.4900.


, - 2,0335-2.2232.
4 , -
1.7157-1.5878.

GBP ,
4 1.66251.5790, , 5
2,0585-2.2554 ( , ).

15

FOREX MAGAZINE 2004

FOREX

2004 22

, 3
96,00, 118,42,
- 84,65-65,91.

" " 118,42-124,60. ,


,
.


. -
3 1.1000, 4- 1.43041.4729, - 5- 1.0971-0,8870.
, , 3 , 1.1000 5 .

, 3
. 4 1.4345-1.4945,
5 1.1920-1.0617.

16

FOREX MAGAZINE 2004

FOREX

CAD "" - 5 1.4343-1.4945.

2004 22

: CAD "" 1.3235.

http://www.forextrader.ru/ .
- http://www.forextrader.ru/TradingSignals/ELW/DELWaves100604.htm
, 10.06.04 . 2004 - http://www.forextrader.ru/DTarchive/ClientReportServlet.htm
2004 300%.
,
FOREXTRADER.RU
E-mail: trader_karlo@mail.ru

17

FOREX MAGAZINE 2004

2004 22

?
AUD/USD. ?

2001. 2004.,
, . , ,
. , , .. A-B-C.

99%
, ,
. ,
, 0.6450.
, ,
0.6794,
.
.

, .
, .
- , ,

, , .
, , .

18

OBV , ,

.

.
, - .
, , ,
, , 0.6450. , . ,

, .
, .. . .
, ,
. , ,
, ,
,
, .. . ,

,
, ,
.

FOREX MAGAZINE 2004

2004 22

OBV .
, .
, ,
, ,
, ,
. "" 0.69
" ",
.
.
,
114.9 . , .
,
0.6996( 0.70), .
( , ,
)
.
, , 0.7010. , ..
100%
0.7150, .
, : .
Sell AUD/USD - .
, ,
,
..
0.7010. - 0.6510.
, 200-250
, .


Forex Magazine
www.alpari-idc.ru

19

FOREX MAGAZINE 2004

VIAC.RU " "

2004 22

C 28 23 VIAC.RU
" "
, , , .
. VIAC.RU. , , " " " ".
:
FOREX. .
.
.
.
: , , , , ...
, , .
. .
. .
, , .
, .
. . .
, .
.
.
.
.
.
.
, , .
.
.
, FOREX: , , , .
.
.
. .
;
;
;
"".
: .
.
MACD ( -).
(+/- DM).
(ADX).
:
;
.

20

FOREX MAGAZINE 2004

VIAC.RU " "

2004 22

.
(Candlestick);
;
"-";
. ;
;
" ".
:
" " . ;
..
Silver-channel.
:
.
.
.
, .
, .
. .

:
" , .
VIAC (.. ). ,
, . .
40 600 , , - 3 .
, , 2-3 . . , , - . -
.
.
- , - , - - . - 5%,
.
- .
. , , . VIAC . , , , . VIAC, .
, , . , "
" , . (.. , ..), - "0". ,
(), , .
, , .
, .
, : - ,
. , , - , .
, , !
, . , - , ICQ. , .
: , - ! , "

21

FOREX MAGAZINE 2004

VIAC.RU " "

2004 22

" " ". , .


4 . , , , ,
. , .
.
. ,
.
:
. .
, . , .. .
, ,
.
. , . , ,
. , , .
: .
, , . ,
, ."

C 28 23 VIAC.RU -
" "
, , , . , , , , . ,
.
-:
1.
.
2.

.
3.
. .
4.
.
5.
, , . .
6.
( ) .
.
7.
-.
-.
8.
. .
. , .

!
AlexSilver
www.viac.ru

22

FOREX MAGAZINE 2004

2004 22

GBPUSD 21.06.2004

21 2004


1.8387 195 ,
+1,07% . 14.06.04 18.06.2004.
14.06.2004
1. $48.33 . $46.60 .
2. 1,2% -0,6%
3. +0,3% ,+2,4%
4. . , +0,1%
+1,4%
5. +1,6% 5,3% .
15.06.2004
1. (HICP) 1,5%
2. RPI-X +2,3% .
3. (Retail Price) +0,4% , +2,8% .
4. (CPI) +0,6%, 0,2%
5. +0,2%
6. - 30,2, 30,2
7. 95,2/90,2
8. , .
9. ()
16.06.2004
1. (Average earnings) , 4,3%
2. (Claimant count) +2,8% (. . 2,9 2,8)
3.
.
4. +1,1% ( 0,8%)
17.06.2004
1. 0,25%
2. 15 336
3. (Retail sales) +0.8% , +7.4% ( +0.6%
, +8.6% , +0.3%, +6.1% +5.8%).
4. (PPI) +0.8% ( +0.6%, +0.7%).
(PPI excluding food and energy)
+0.3% ( +0.2%, +0.2%).
5. (Leading indicators) +0.5% ( +0.4%, . +0.1%).
6. (Philadelphia Fed index) 28.9 ( 26.0,
23.8).
18.06.2004
1. 4 +1.2% , +7.9%
2. (PSNCR) +3.06 .
3. (Current account) 2004 -144.9 .

23

FOREX MAGAZINE 2004

GBPUSD 21.06.2004

2004 22

()

, :
I, II, III, IV, V, A, B, C
- [1], [2], [3], [4], [5], [a], [b], [c]
(1), (2), (3), (4), (5), (a), (b), (c)
1, 2, 3, 4, 5, a, b, c,

1,2,3,4,5,a,b,
.
, , 1,8240 -1,8380.
.
, , 1,8634
. 21 . ,
, ,
29-30 .
, .
1. 1,8400 1,8634
2. , 1,8156 ( 0-4)
3. 0-4 1,7900
, .

24

FOREX MAGAZINE 2004

GBPUSD 21.06.2004

2004 22

(3 ) .
1.7702 1.7693-1,7561.
4 (0)-(3)-(4?) Price sorting 4 ,
. , 1,9657.
5 (2)-(3)-(4?) Price sorting 5 ,
. 1,9071 1,9773.
(5), , (4)
1.7480. C 17 2004 .

25

FOREX MAGAZINE 2004

GBPUSD 21.06.2004

2004 22

1.8055-1.8719 (664 )
weekly Res: 1.8498 / 1.8582 / 1.8634 / 1.8719
weekly Sup: 1.8276 / 1.8192 / 1.8140 / 1.8055
weekly NZ 1.8361-1.8413 (52)
------------------------------------------------------------------------------------------------------------------------------------------------------------------- 1.8163-1.8611 (448 )
intraday Res:...1.8462 / 1.8518 / 1.8554 / 1.8611
intraday Sup: ..1.8312 / 1.8256 / 1.8220 / 1.8163
day NZ 1.8369-1.8405 (36 )
NZ,
.
, .
, .
3 .
1
.
1 24 .

26

FOREX MAGAZINE 2004

GBPUSD 21.06.2004

2004 22

, , - 20,3
.
, - ,
11, 21,41, 12, 14.
1. 11 19.02.2004 1.9139.
2. 11 02.04.2004 1.8601.
3. 12 02.04.2004 1.8601.
4. 12 04.09.2003 1.5609.
5. 11 16.04.2004 1.7761.
6. 12 15.05.2004 1.7480. .
, .
, , . , 21 22
.
. ,
, $ -144,9 .,
1,8400 , , . ,
. 18 21, 21.06.04
1,8458. ,
.

27

FOREX MAGAZINE 2004

GBPUSD 21.06.2004

2004 22

Time Ellipse

? -
07.06.04 (1,8476) 11.06.04.(1,8441).
, 1,8500, -
( ) 1,8262.
,
.

:
E-mail: a_vlad@viac.ru
www.viac.ru

28

FOREX MAGAZINE 2004

2004 22

" "
" " - "Forex Magazine"
www.fxmoney.ru



. - 1965 .
.
-
. 1984 . ,
-
. 1993 . 2002 .
. 2002 .
.

?
- 80- . .

,
, " ",
. .


,
, .
.
.
,
, ,
?


. , .
. .
.
, . - .

, . , 1990 .
.
. , , . .


.
.
,
.
5 - 10%
.

1991 . .

. , , .

. .

29

FOREX MAGAZINE 2004

2004 22

15
1991 . "
". . , ,
,

.

, , - .

, .

?
. ,
, . ,
.
.
1992 .
. .
,
.

,
, , .
, ,
. , , !

30

FOREX MAGAZINE 2004

,
, ,
. ,
, .
. .
. : . - . ""
. ,

. ,
. .
(
) , .
- ", !". . , ,
,
.


.

.
, , ?
,
. -,
.

31

2004 22

. , .
.


. " " 1994
., 1998 ., .
, - . . . .
,
. .
-, . .
.
, .
50%, - 30%, .
-, .
- ,
, , ,
. ,
. , - ,
- . . .
, .
.
.
, -

FOREX MAGAZINE 2004


..
.. .

?
, . ,
.
.
-, , , , , , . ,
. , . ,
, .
, , . ,
.
.
?

2004 22

,
.

. ,
.
, , , , , ,
.

, ,
,
.
, ,
- ,
, . ,
,
,
, .
" "
www.fxmoney.ru

.
, ,
.
.

- .

. ,
, . -

32

FOREX MAGAZINE 2004

. .

2004 22



,
,
- ,
.
15 ,
,
, "
, ,
".
,
,
25 29-30
,
"" .

"-" ,
"" ,
, "" .

15 , 18
, ,
.
, , -
. , ,
,
, , - .

,

33

. -
"Bloomberg News"

.
, .
, , : "
, ,
, , ", .

, ,
(FOMC)
, , , . , , , , 25
.
FOMC
. ,
, .
, ,
, . -
.
FOMC ,
.

-
,
.
, , , , .

FOREX MAGAZINE 2004

. .

2004 22

,
,
, , , , . , .
,
,
.


" ". ,
, , ,
,
. , , .
15 , ",
- ,
".
,
1.7% 12 -
, , FOMC . , - . ,
, ""
.
, , "
1.8%". 12-
.
, "-",
, , .
Forex Magazine
bloomberg.com

34

FOREX MAGAZINE 2004

2004 22

:
, ,
. , ,
, ,
.
7 ,
, 300 .
"Drexal-Burnham-Lambert",
"C.M.E.",
.
, " " , , , -

. ,
- , , ,
.
,
, .
,
, , , , S&P. .
2 . ,
,
, ( ) , . , ,
.
,
- .
,

35


www.ensignsoftware.com
, , ,
, "" ( . " " 17). , ,
. 0.618, 0.786, 1.00, 1.272, 1.618. 5 5
"" , .
, 2- , - , , .
.
,
.
, ,
, .

. , , . ,
. , ,
. , ,
,
, , .
, 2 : , , .
, , . ,
.
- , .

FOREX MAGAZINE 2004

,
.
, , -. 7 , 5
2 , . ,
20.000$.
3 .
, ,
, ,
. . , ,
15
, , . ,
. ,

2- .
,
, 5 "" , , .
S&P, -
, 1.27.
, S&P 1.27 -
. S&P , ,
, , . ,
, , .
, .
35 , , 35
. , -
.

.

36

2004 22

"Ensign",
DOS, "Ensign Software" 10
. "QCharts", , ,
.
.
.
2- .
, , ,
. 0.618, .
,
. ,
, , , .
, , , , ,
. . ,
,
:
1. -, , "" - 0.618, 0.786, 1.00,
1.272, 1.618.
2. " ", .
. ( . " " 18)
3. ,


. ( . " "
21)
4. ,
. , .. ( . " " 19)

FOREX MAGAZINE 2004

2004 22

( ). .
30 12.00
127% 9.45. ,
20 $ . ,
.
, ,
.
. - ,
, .
Forex Magazine
www.ensignsoftware.com

37

FOREX MAGAZINE 2004

2004 22


,
, .
, , . , ,
,
. , .
, .

. .
, . , , .
,
.
, - , ,
.

www.hardrightedge.com

. , , , .
. , , .
,
,
.
,

,
, - .


. .
- ,
.

.

.

38

FOREX MAGAZINE 2004

2004 22

, , .

,
,
. ,

.

.
.

" ". ,
, , .
, .
,
. ,
. , , .

39

,
, , , , . .
, .
, , , .
.
, . , . , .
, ,
, .
,
. ,
.
,
, , .
Forex Magazine
www.hardrightedge.com

FOREX MAGAZINE 2004

2004 22

(PVO)

(PVO)
(PVO)

.
:
(%) PVO = ((12- EMA
- 26- EMA )/ 12- EMA ) x 100
12-
(EMA) 26-
. , ,
.
, PVO +100, . : 12- EMA 2000, 26-
EMA 8000, PVO
-300: ((2000 - 8000)/2000) x 100 = -300. , .

2.



. PVO , ,
PVO , .
3.



. :
PVO (12,26,9) 9- EMA PVO,
9- EMA.
, , , .
-



:
1.


, .
PVO , EMA , EMA . PVO , EMA ,
EMA . PVO , , ,
. PVO
, , ,
.

40

FOREX MAGAZINE 2004

(PVO)

, , ,
.

. , PVO
,
.
,
PVO
. PVO ,
,
,
.
, ,
"FILE" , :
PVO (12,26,9) PVO
(5,60,1) . 1, PVO (5,60,1),

. , 15 21, PVO , , .
,
.
, PVO ( ).
, .
.

2004 22

,

(PPO). ,
, - (12,26,9):
(EMA) , - , - .
PVO .
( ) PVO . ,
,
1.

, PVO
, (12,26,9) (5,60,1). ,
PVO
,
.

41

FOREX MAGAZINE 2004

(PVO)

2004 22

PVO (12,26,9) +20 , PVO (5,60,1) +50.


( 1), PVO
(5,60,1) , PVO
(12,26,9) .
( 2), PVO
(5,60,1) ,
PVO (12,26,9).

EMA
PVO. 5- EMA , 12- EMA .

.
,
, 60 EMA ( ). , PVO
,
60m .
Forex Magazine
stockcharts.com

42

FOREX MAGAZINE 2004

2004 22


, , .
,
.
, , , .
.
, ,
. ,
, ,
.
15 :
1. , , .
, ,

.
.
2. , ,
. , , ,
.
3. ,
.
,
. , , ,
.
4. . , - ,
,
.
, .

43

www.hardrightedge.com
5. .
" ". ,
, .
6.
. ,

. ,
.
7. ,
. , .
- , , ,
, .
8. ,
. .
9. . . , . , ,
.
10. , , . , , .
, .

FOREX MAGAZINE 2004

2004 22

11. . ,
, ,
. ,
.
, .
12. ,
. ,
.
, . , ,
.
13. ,
.
, ,
, , .
.
14. . , ,
. , , .
15. , - .
.
, ,
.
Forex Magazine
www.hardrightedge.com

44

FOREX MAGAZINE 2004

2004 22


,
.
10% ; - . , .
,

.
,
.


www.lbrgroup.com

, . ,
,
,
.
- ,
- .

.
, ,
. ,
,
.
/
,
. ,
, , .

, /. , , , .

- . . ,
. ,
- .


, - . ,

-

45

,

.
, . , ""
, , .
, , -

FOREX MAGAZINE 2004

2004 22

.
,
. , , , " " - , .
, .

,
,
. ,
. , , , , . , -

!

, ,
.

, .

, . - , !

46

-
-
, - . , / , ,
.



:
NR7 - 7 (
"-
");
2 3 ;
,
;
"-" - / / - ; ,
, , , -

FOREX MAGAZINE 2004

2004 22

- ;
,
,
;
,
;
( , ,
, ,
. , . ,

!)
/ - 3-

/ .
, .

, .
. , ,
.
.
, .
- , -
, .


-
, ,
. , -

47

.
, 45-120 . ,
- . ,
:
1). 2).
.
-
,
.

FOREX MAGAZINE 2004

.
15
. . 5- 15 , ,
"",
. ,
, , . ,
, , .
.
. ,
, .
,
1-3 .
, ,
. , , , -

2004 22

. ,
, , . ,
.
. , , 13 , . ,

. ,
, .

.
.
. , - 4- . ,
" ", 20- /. ,

. ( 2-
.)

,
- . ,
. , ,
.

48




.

.
,
. , ,
,

FOREX MAGAZINE 2004

. ,
.
, ,
,
. ,
. ,
.
, "-" "", . ,

.

, ,
-, . ,
, .
, - , . , - ,
. - , ,
.
,
, .
, ,
. , : , .


. , , ,

.

49

2004 22


, ! , ,
. ,
, .
, , ! , , 5% .

,
. , , ,
. ,
,
.
:
,
-;
,
;
;
.


( ,
"");
;
( );
;

( ).

FOREX MAGAZINE 2004

2004 22

- ,
. ,
.
.

-


. ,
. ,
, .

Forex Magazine
www.lbrgroup.com

50

FOREX MAGAZINE 2004

2004 22

MQL 4: .

MQL 4: .
(AKA HORN)
http://forex.tomsk.ru
MQL 4
Forex Magazine
- MQL 4, MQL II. -, MQL II
, , , .
,
MQL 4, , .
, -
"" .
MQL 4, .
.
( MQL II),
, .
, .
.

MQL II, .
"script". -
,
.
Script'
Meta Editor 4
"Script program".
,
script'.

, .
MQL 4 , , init, deinit start. . ,
, .
.
.
double SomeFunction(color LineColor, string LineName, int Range)


,
. (
) . ,
, ,
. . ,
- , - .


SomeFunction :
LineColor color, LineName - string
Range - int.

MQL 4 .
-

,
- , , -

51

, , ,
. , - ,
.
.

FOREX MAGAZINE 2004

MQL 4: .

. , SomeFunction - ,
.
" ", .
, -,
, :
1. ,
;
2. , ;
3. , ;
4. double, .
:
// - double,
//
double fHighestClose;
// -
...
// ""
// SomeFunction .
fHighestClose = SomeFunction(Yellow,Line subscript,50);
// fHighestClose
// SomeFunction

, ,
""
. ,
.
, .
void. , , OtherFunction
:
void OtherFunction(int Param1)

, ,
,
,

52

2004 22

. , MQL4 .
, , ,
,
, .
,
o, , .
- -
,
, , . ,
, " ". :
//
// Param2
int SomeFunction1(int Param1, int Param2=10, int Param3=123)
{
// do something
}
//
// Param2
int SomeFunction2(int Param1, int Param2=10, int Param3)
{
// do something else
}

, SomeFunction1 ,
;
.
// - int,
// ,
// SomeFunction1
int nSomeResult = 0;
// SomeFunction1
// . Param2 Param3
// 10 123
nSomeResult = SomeFunction1(10);
// SomeFunction1 .
// Param3 123
nSomeResult = SomeFunction1(10, 20);
// SomeFunction1
//
nSomeResult = SomeFunction1(10, 20, 30);

, , , ,
- .
,
int. , ,

FOREX MAGAZINE 2004

MQL 4: .

,
- . ,
:
int SmartFunction()
{
bool bReturn = false;
// do something
...
if(bReturn) {
return(1);
}
// do something else
...
if(bReturn) {
return(2);
}
return(0);
}

,
, .

. , MQL 4
,
,
, - , . ""

?

2004 22

,
- ,
:
AnalyzeIt(SmartFunction(),"MyFileName.mq4","Wrong SmartFunction
termination");


"WARNING: Wrong SmartFunction termination in
MyFileName.mq4".
. ,
,
MQL 4. ,

Meta Trader 4.

Forex Magazine

AnalyzeIt(bool bCondition, string sModuleName, string sDescription =


"Something is wrong")
{
if(bCondition){
Alert("WARNING: " + sDescription + " in " + sModuleName);
}
}

, ,
, .
:
AnalyzeIt(SmartFunction(),"MyFileName.mq4");

SmartFunction , ,
bCondition AnalyzeIt.
, ,
"WARNING: Something is wrong
in MyFileName.mq4".

53

FOREX MAGAZINE 2004

2004 22

MetaTrader. 20

MQL II. 20
Fxtest


artur@fxtest.ru

, . .
, Simca, . . .

signal.
:
signal=abs(c[shift]-c[shift+n-1]);
:
signal=abs(c[shift]-c[shift+n]);
signal 1 .
, , . , ,
, . .
, . . , ()
. .
()= ()+.
, Simca.
< :
AMA1=c[Nbars];
For shift=Nbars Downto 0 Begin
...
AMA=(c[shift]*ssc*ssc)+GetIndexValue(shift+1)*(1-ssc*ssc);
if shift=Nbars then AMA=(c[shift]*ssc*ssc)+AMA1*(1-ssc*ssc);
SetIndexValue(shift,AMA);
End;

54

FOREX MAGAZINE 2004

2004 22

MetaTrader. 19

:
AMA=c[Nbars];
For shift=Nbars Downto 0 Begin
...
AMA=(c[shift]*ssc*ssc)+AMA*(1-ssc*ssc);
SetIndexValue(shift,AMA);
End;
. :) AMA ,
. ,
AMA1 ,
AMA. ,
. AMA1
. :) .>
Simca , .
< ,
:
--Inputs: Range(10), FastMA(2), SlowMA(30);
Variables: cb(0), i(0), Noise(0), ER(0), SSC(0), AMA(0);
SetLoopCount(0);
AMA=Close[Bars-Range];
for cb=Bars-Range-1 downto 0 begin
Noise=0;
for i=cb to cb+Range-1 begin
Noise=Noise+Abs(Close[i]-Close[i+1]);
end;
ER=Abs(Close[cb]-Close[cb+Range])/Noise;
SSC=ER*(2/(FastMA+1)-2/(SlowMA+1))+2/(SlowMA+1);
AMA=Close[cb]*SSC*SSC+AMA*(1-SSC*SSC);
SetIndexValue(cb,AMA);
end;
-- , "
" (Nbars) .
, .
. :)
shift cb ( CurrentBar). :)
(Bars-Range-1)
. AMA
(Bars-Range). signal

55

FOREX MAGAZINE 2004

2004 22

ER
. . :)
. :)
.
SSC.
.
.
, .
2/(SlowMA+1) - "SlowSC" (
).
2/(FastMA+1) - "FastSC".
"FastSC" ,
FastSC-SlowSC, (
) :
k1=2/(SlowMA+1);
k2=2/(FastMA+1)-k1;
SSC (
:) ):
SSC=ER*k2+k1;
. AMA
( ). :)
( ).
, , :
Price - Close[cb].
AMA1 - AMA ( - :)
AMA ).
AMA=Price*SSC^2+AMA1*(1-SSC^2);

AMA=Price*SSC^2+AMA1-AMA1*SSC^2;

AMA=AMA1+Price*SSC^2-AMA1*SSC^2;
SSC^2
AMA=AMA1+SSC^2*(Price-AMA1)

56

FOREX MAGAZINE 2004

2004 22

AMA :
AMA=AMA+SSC*SSC*(Close[cb]-AMA);
, :) . :)
.
.
.
:
--Inputs: Range(10), FastMA(2), SlowMA(30);
Variables: cb(0), i(0), k1(0), k2(0), Noise(0), ER(0), SSC(0), AMA(0);
SetLoopCount(0);
k1=2/(SlowMA+1);
k2=2/(FastMA+1)-k1;
AMA=Close[Bars-Range];
for cb=Bars-Range-1 downto 0 begin
Noise=0;
for i=cb to cb+Range-1 begin
Noise=Noise+Abs(Close[i]-Close[i+1]);
end;
ER=Abs(Close[cb]-Close[cb+Range])/Noise;
SSC=ER*k2+k1;
AMA=AMA+SSC*SSC*(Close[cb]-AMA);
SetIndexValue(cb,AMA);
end;
-- (
)
. .
. :) . >
!
.
()= ()+. . .. , , , .

57

FOREX MAGAZINE 2004

2004 22


.
< (
)
. >
<>, - . . .
, 1. , ,
.
if Minute=59 then {
if TotalTrades>0 then
{
for cnt=1 to TotalTrades
{
if OrderValue(cnt,VAL_TYPE)<=OP_SELL and
OrderValue(cnt,VAL_SYMBOL)=Symbol then
{
If OrderValue(cnt,VAL_TYPE)=OP_BUY then
{
CloseOrder(OrderValue(cnt,VAL_TICKET),OrderValue(cnt,VAL_LOTS),Bid,3,Violet);
exit;
};
If OrderValue(cnt,VAL_TYPE)=OP_SELL then
{
CloseOrder(OrderValue(cnt,VAL_TICKET),OrderValue(cnt,VAL_LOTS),ask,3,Violet);
Exit;
};
};
};};
};
D1 : if Hour=23 then {

, Simca.
, , .
- , .

artur@fxtest.ru

58

FOREX MAGAZINE 2004