Initial Commit ...
This commit is contained in:
@@ -0,0 +1,31 @@
|
||||
# Stochastic EA
|
||||
|
||||
we want to buy on bottom of stochastic when cross over stock with signal
|
||||
and sell when cross under stock with signall on top ...
|
||||
|
||||
```mql4
|
||||
//
|
||||
int totalBars;
|
||||
|
||||
//
|
||||
int OnInit() {
|
||||
//
|
||||
totalBars = iBars(Symbol, _Period);
|
||||
|
||||
//
|
||||
...
|
||||
};
|
||||
|
||||
//
|
||||
void OnTick() {
|
||||
//
|
||||
int bars = iBars(_Symbol, _Period);
|
||||
if (totlaBars != bars) {
|
||||
//
|
||||
totalBars = bars;
|
||||
|
||||
//
|
||||
// Do Actions here ...
|
||||
}
|
||||
}
|
||||
```
|
||||
Reference in New Issue
Block a user