File tree Expand file tree Collapse file tree 2 files changed +16
-13
lines changed
examples_of_expert_advisor/fimathe Expand file tree Collapse file tree 2 files changed +16
-13
lines changed Original file line number Diff line number Diff line change 1
- """
2
- EURUSD FiMathe Expert Advisor for MetaTrader 5.
1
+ """EURUSD FiMathe Expert Advisor for MetaTrader 5.
3
2
4
3
This Expert Advisor uses Fibonacci retracement levels to determine entry and exit points.
5
4
"""
5
+
6
6
import MetaTrader5 as Mt5
7
7
import numpy as np
8
8
from include .rates import Rates
74
74
75
75
if len (Mt5 .positions_get (symbol = trade .symbol )) == 1 and (
76
76
(
77
- Mt5 .positions_get (symbol = trade .symbol )[0 ].type == 0 and
78
- tick .last > Mt5 .positions_get (symbol = trade .symbol )[0 ].price_open + zone_236
79
- ) or (
80
- Mt5 .positions_get (symbol = trade .symbol )[0 ].type == 1 and
81
- tick .last < Mt5 .positions_get (symbol = trade .symbol )[0 ].price_open - zone_236
77
+ Mt5 .positions_get (symbol = trade .symbol )[0 ].type == 0
78
+ and tick .last > Mt5 .positions_get (symbol = trade .symbol )[0 ].price_open + zone_236
79
+ )
80
+ or (
81
+ Mt5 .positions_get (symbol = trade .symbol )[0 ].type == 1
82
+ and tick .last < Mt5 .positions_get (symbol = trade .symbol )[0 ].price_open - zone_236
82
83
)
83
84
):
84
85
trade .stop_loss = trade .sl_tp_steps
Original file line number Diff line number Diff line change 1
1
"""WIN FiMathe Expert Advisor for MetaTrader 5.
2
2
3
- This Expert Advisor is designed for WING21 futures, using Fibonacci retracement levels to
3
+ This Expert Advisor is designed for WING21 futures, using Fibonacci retracement levels to
4
4
determine entry and exit points.
5
5
"""
6
+
6
7
import MetaTrader5 as Mt5
7
8
import numpy as np
8
9
from include .rates import Rates
83
84
84
85
if len (Mt5 .positions_get (symbol = trade .symbol )) == 1 and (
85
86
(
86
- Mt5 .positions_get (symbol = trade .symbol )[0 ].type == 0 and
87
- tick .last > Mt5 .positions_get (symbol = trade .symbol )[0 ].price_open + zone_236
88
- ) or (
89
- Mt5 .positions_get (symbol = trade .symbol )[0 ].type == 1 and
90
- tick .last < Mt5 .positions_get (symbol = trade .symbol )[0 ].price_open - zone_236
87
+ Mt5 .positions_get (symbol = trade .symbol )[0 ].type == 0
88
+ and tick .last > Mt5 .positions_get (symbol = trade .symbol )[0 ].price_open + zone_236
89
+ )
90
+ or (
91
+ Mt5 .positions_get (symbol = trade .symbol )[0 ].type == 1
92
+ and tick .last < Mt5 .positions_get (symbol = trade .symbol )[0 ].price_open - zone_236
91
93
)
92
94
):
93
95
trade .stop_loss = trade .sl_tp_steps
You can’t perform that action at this time.
0 commit comments