SQX 111 - Building blocks Highest and Lowest should be inverted

Hi,



Whilst using the building blocks Highest and Lowest, I noticed the strategies generated were not inverting the Highest and Lowest for the Long / Short Signals. Examples:


//--------------------------------------------------------------------
// Trading rule: Trading signals (On Bar Open)
//--------------------------------------------------------------------                   
LongEntrySignal = (Open above BollingerBands(Main chart,6, 2.5).UpperBand after opened below
   and (CCI(Main chart,30)[1] crosses 0.0 upwards));


ShortEntrySignal = (Open below BollingerBands(Main chart,6, 2.5).LowerBand after opened above
   and (CCI(Main chart,30)[1] crosses 0 down));


LongExitSignal = (Bar opens below Highest(Main chart, 17) after opened above
   and (CCI(Main chart,30)[7] crosses 80.0 upwards));


ShortExitSignal = (Bar opens above Highest(Main chart, 17) after opened below
   and (CCI(Main chart,30)[7] crosses -80 down));




AND




//--------------------------------------------------------------------
// Trading rule: Trading signals (On Bar Open)
//--------------------------------------------------------------------                   
LongEntrySignal = (Bar opens below Highest(Main chart, 44) after opened above
   and Open below BollingerBands(Main chart,21, 2.0).UpperBand after opened above);


ShortEntrySignal = (Bar opens above Highest(Main chart, 44) after opened below
   and Open above BollingerBands(Main chart,21, 2).LowerBand after opened below);


LongExitSignal = (Open below BollingerBands(Main chart,20, 2.0).LowerBand after opened above
   and (CCI(Main chart,50)[10] crosses 60.0 upwards));


ShortExitSignal = (Open above BollingerBands(Main chart,20, 2).UpperBand after opened below
   and (CCI(Main chart,50)[10] crosses -60 down));




Since Hightest / Lowest is a directional block (in the same way as the bollinger band highest and lowest are), the blocks should be inverted (swapped) in opposing rules.




Thanks,


Mike

Attachments
No attachments
  • Votes +2
  • Project StrategyQuant X
  • Type Bug
  • Status Fixed
  • Priority Normal

History

m
#1

mikeyc

04.10.2018 18:53

Task created

g
#2

geektrader

06.10.2018 19:48
Voted for this task.
MF
#3

Mark Fric

08.10.2018 12:28

Status changed from New to Fixed

FD
#4

fdaprile

19.11.2018 04:42
Voted for this task.
FD
#5

fdaprile

19.11.2018 04:43
Please see also task sq4_3022.

HIGHEST(HIGH) should also be inverted to LOWEST(LOW)!

Currently, the calculation price "High" is not mirrored to "Low",

so you get LOWEST(HIGH) instead...


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