dynamic loopback period and universal parameters in the EA

The basic idea is to represent the different market phases (bull, bear, sideways) profitably in an EA.

Approach:
The considered "lookback period" (the number of bars from the last bar that has a price or indicator)
to perform momentum calculations.
To set the buy and sell level, the number of review days changes
in relation to changes in market volatility.
This method changes the number of review days every day.
At the end of each day, the current market volatility is based on the standard deviation
(Closing prices of the past 30 days or determined by StrategyBuilder).
Although the look back days are dynamic, they should be limited to an acceptable range
(previously 20 to 60 or determined by strategy builders).

For a purchase setup, the closing price of the previous day must be
above the current high level of the used indicator.
In addition, the ask price must be above the highest high of the last N days.


For a sales setup, the closing price of the previous day must be
lie below the lower low level of the used indicator and
the ask price must be below the lowest low of the last N days.
The length of the indicator period is the same number of lookback days as described above (lookback period).

The indicator resolution may differ per object (currency / security ...).
However, the resolution of the indicator should be equal to or higher than the resolution of the security.
In most cases, this use should be in the Initialize method or to change the day
a universal updating of the parameters of the EA.

The exit signal for an existing position is determined by the calculation
a simple moving average of closing prices for past review days.
That is, we liquidate a long position if the current price during the review
below the moving average of the closing price and vice versa when a short position is sold.

However, volatility in the market means that lookback days go back
thus facilitating entry into a trade.
As market volatility increases, we raise the backlog days to filter the counterfeit signals,
which makes entry into a trade more difficult.
So let's use the standard deviation of the price as a measure of the market volatility to improve the model.
So there may be other measures of volatility
such as the standard deviation of the logarithm return series or other stochastic volatility measures.


Basic Indicator

The indicator is not ready from the ground up.
The learning phase depends on "lookback period".
To retrieve and adjust the numeric value of an indicator, the Current.Value attribute of the indicator could be used.
The updating of the indicator should be automatic (learning curve) or manually possible.

If necessary, the EA needs another library for the calculations.

What do you make of it?
Attachments
No attachments
  • Votes +2
  • Project StrategyQuant X
  • Type Feature
  • Status Refused
  • Priority Normal

History

HH
#1

Hans

10.02.2019 17:26

Task created

HH
#2

Hans

10.02.2019 17:28
Voted for this task.
HH
#3

Hans

10.02.2019 17:29
(currency / CFD ...).
HH
#4

Hans

10.02.2019 17:29
(currency / CFD ...).
Rr
#5

Partizanas

11.02.2019 14:23
Voted for this task.
MF
#6

Mark Fric

28.07.2020 12:40

Status changed from New to Refused

sorry, we'll not implement this

Votes: +2

Drop files to upload

or

choose files

Max size: 5MB

Not allowed: exe, msi, application, reg, php, js, htaccess, htpasswd, gitignore

...
Wait please