Who wants a strategy? Lots and for free) - page 62

 
Miroslav_Popov >> :

if you use "Use previous bar value" parameter correctly you don't need the current bar value of the indicator.....


:) the only language I know is Russian, but in two dialects: the common and the command one:......

Miroslav, I don't use your FSB, it doesn't really suit me in terms of ideology and selection principles..... all my comments only on MQL coding questions

 
rider >> :

My mistake.

I meant to say "if you use the 'Use previous bar value' principle when baktesting". It has nothing to do with the FSC. It's like "Open position to the next bar after the signal".


**Miroslav, I don't use your FSB, it doesn't fit my ideology and selection principles**.

Thanks for the frankness.

Luck!

 
Stellarator, please write an analogue of the Hourly High Low indicator, I'm exhausted from lack of understanding:)
 

Good day, everyone!

Sorry for the long absence. As already mentioned, it has been a rather busy week in terms of the main work, I've had very little time to get around to it. Nevertheless, yesterday I started my version of the Expert Advisor dummy (with BarClosing/BarOpening stuff). Initial outline is there (idea), but prefer a little more "to the mind" before putting it out (I'll try to demonstrate it by Monday).


Exlermillenium - to be honest, I'm not quite sure about this indicator, I guess it should be used only with TF less than daily(?), because FSB cannot deal with TF different from the tested one (this supposition comes from the brief analysis of the source). Conceptually I don't see any problems - except for weekend and trying to rest from everything that was accumulated during the week :). But I'll try also before tomorrow evening to "add" here :).


Prof. Terry - I have a fundamental question about the tester operation (in the global sense, without concerning the indicators). I can write to the mail, you Russian there understand (read)? Not to stir up the public here again/better :)...

(info a-t forexsb.com ?)

 
Miroslav_Popov >> :

>> Luck!

>>)). )))

 
Stellarator >> :


exlermillenium - frankly speaking, I'm not quite sure of the nuance of this indicator, as far as I understand its use is appropriate only with TF less than daily(?), because FSB cannot operate with TF different from the one being tested (this supposition comes from the cursory analysis of the source code). Conceptually I don't see any problems - except for weekend and trying to rest from everything that was accumulated during the week :). But I shall try also till tomorrow evening to "throw" here :).


Yes it is simply High and Low for a specific time interval from x1 hour y1 minutes to x2 hour y2 minutes. The value is taken from the completed last interval.

 
zfs >> :

Yes it is simply High and Low for a certain period of time from x1 hour y1 minutes to x2 hour y2 minutes. The value is taken from the completed last interval.

You're probably right:)
 

Good morning/afternoon to all!


exlermillenium actually in the archive the current (latest) versions of the converted indicators, including "Hourly High Low".

It needs to be checked on a moving market for "correct" zero bar values. I hope I have not "made a mistake" :), but it will be seen tomorrow (if I want, I can try to run it on history). If something goes wrong I'll tweak it tomorrow...


zfs: Yes it's just High and Low for a certain time interval from x1 hour y1 minutes to x2 hour y2 minutes.The value is taken from the completed last interval.

I understood how the indicator works from the source code before I started rewriting it. I simply meant in my post (assumed) that the use of the indicator makes sense only for TF less than PERIOD_D1 (which was confirmed after the "rewrite")).


In other words, in general, you should not use the indicator when TF >= PERIOD_D1, and also when the values of tsFromTime and tsUntilTime are the same (the period of all days).

The indicator contains a "non-functional" parameter (basePrice), whose value is not checked for logical correctness. In the same way I changed "Heiken Ashi"! If someone begins to use the indicator in the code, please take it into account (I also improved logic of its operation on the distant bars - when calculating history values at the very end (of the history) it is not quite correct)...

It's all done for full FSB compatibility in number of parameters!


The whole current code as a whole is "cleaned up", but it shouldn't affect the functionality. At the same time I completely finished writing the functionality of these structures:

                    case "The position opens above the MA value":
                        component[0]. PosPriceDependence = PositionPriceDependence. BuyHigherSellLower;
                        component[0]. UsePreviousBar     = iPrvs;
                        component[1]. DataType           = IndComponentType. Other;
                        component[1]. ShowInDynInfo      = false;
                        component[2]. DataType           = IndComponentType. Other;
                        component[2]. ShowInDynInfo      = false;
                        break;

FSB seems to rely on PosPriceDependence while calculating logical condition (i.e. "something inside" :)), which is not suitable for our case, since it contradicts the thesis that logical conditions must explicitly return either 1.0 (Signal) or 0.0 (or EMPTY_VALUE) - as no signal. Such constructs are rewritten as follows (using this particular example):

            for ( iBar = iFirstBar; iBar >= 0; iBar--) {
               LPIndBuffer[ iBar] = Close[ iBar] > adMA[ iBar];
               SPIndBuffer[ iBar] = Close[ iBar] < adMA[ iBar];
            }

AND RECOMMEND indicator calculation on every incoming tick(!) As they usually appear in Open Position Logic. Because the Close of the current bar may change back and forth in time, the logical condition will (probably) also change (as in this case, when the last available price crosses the MA level).

Let me remind you that Bar Opening and Bar Closing - Point of the Position are not limited to, there may well be used values of common indicators. And so a position can be opened "in the middle" of a bar (easily!). (so to speak, about calculation of indicator values ONLY at intersection of bars... as I said before - this condition is "not always" feasible ;))


I will try to show an example of an EA with an example of indicator usage :) (just as an example :D)... Of course, with Bar Opening and Bar Closing there are too many difficulties... But it looks more or less worked out... :)

Files:
 
Hourly High Low

The "Hourly High Low" indicator finds the highest price and the lowest price of the underlined instrument during a predefined time interval.




We set three parameters:
Start Time - determined by the Start hour and Start minutes figures. As it's shown on the picture - the starting hour is 08:17 H.
End Time - determined by the End hour and End minutes parameters. On the picture is shown end time 13:24 H.

Vertical shift - this number allows us to move the Upper and the Lower prices by a defined number of pips.


Application

The indicator checks all the bars which opening prices are between Start Time and End Time:

Start Time <= Bar Open time < End Time


If you apply this indicator on an hourly chart, the indicator will select the High / Low prices of bars that start at: 09:00, 10:00, 11:00, 12:00 and 13:00.

08:17 < 09:00 ... 13:00 < 13:24


The same applied on a 4H chart will return the High and Low of the bars that starts at 12:00.
08:17 < 12:00 < 13:24

The found High / Low prices during the chosen time interval are valid till the end of the time interval on the next day.


The vertical shift expands or contracts the price limits:


1. Positive Vertical Shift - it raises the High price and lowers the Low price by the selected number of pips;

2. Negative Vertical Shift - it lowers the high price and raises the low price by the selected number of pips.




We can apply this indicator on 4H or lower time frame.

 

Oh, Miroslav showed up :), I'll repeat the question:


Miroslav - there is a very fundamental question on tester operation (in a global sense, without reference to indicators). I can write you an email, will you understand Russian there (read it)? Not to stir up the public here again/better :)...

(info a-t forexsb.com ?)