読み取り専用

フォーラムは現在、読み取り専用のアーカイブとなっています。.

バグ報告やプラットフォームに関する質問はこちら → [email protected]

私たちのコミュニティはDiscordとYouTubeで活動しています。ぜひ参加してください!

ご参加ください Discord YouTube

Adding new candle pattern block

6件の返信

ティモ

カスタマー、bbp_participant、コミュニティ、0件の返信。.

プロフィールを表示

7年前 #247385

こんにちは

 

I’d like to add new version Of the engulfing cande pattern blocks to SQX. I find the BearishEngulfing.java file and, I guess, I can make clone of that one for my modification. Something tells me that it’s not quite that easy. Maybe there is other files else where that needs to be created? Maybe something for the pseudo code? Maybe comething for MQL code itself? The examples of extending SQ looked a bit different cases.

Any help would be appreciated

ティモ

0

Tomas Matejka

管理者、sq-ultimate、2件の返信.

プロフィールを表示

7年前 #247424

こんにちは,

we have a step-by-step guide on how to add a new indicator you can follow the same steps with your candle pattern https://strategyquant.com/codebase/adding-envelopes-indicator-step-by-step/

0

ティモ

カスタマー、bbp_participant、コミュニティ、0件の返信。.

プロフィールを表示

7年前 #247632

こんにちは

I cloned the bearishEngulfing snippet and it’s *.tpl files. Modified the .java And the new candle pattern works in SQX backtesting. When I try to export it to mt5 format it complains that it cannot find such a new function.

I didn’t quite understand from the above example how I would do the .mql code block of my candle patter to presumably .tpl file? It’s a bit confusing since I guess the standard bearishEngulfing pattern is hard coded in sq and thus the mt4 code block is not seen in any files?

If you could give an example of adding bearish engulfing pattern code in .tpl format. Or did I miss something here?

乾杯

ティモ

 

 

0

Tomas Matejka

管理者、sq-ultimate、2件の返信.

プロフィールを表示

7年前 #247693

If you look into Editor -> Code -> MetaTrader 4 -> Blocks you can see the existing BearishEngulfing.tpl template file. It will be the same template for your candle pattern I guess so if you already created the template file for your new snippet make sure the content is the same

0

ティモ

カスタマー、bbp_participant、コミュニティ、0件の返信。.

プロフィールを表示

7年前 #248250

In short when I try to compile the mql file, it doesn’t find the function of my candle block. It makes the function call in mql code, but the function body is missing. I don’t undertand how the funtion body code is generated in mql language. My new candle block works in SQX fine, but when I try to export it to the mql the function body is missing. And I don’t understand how to handle it by looking the BearishEngulfing block as a example.

I used the brearishEngulfing as my example to extend my version, so I try to make everything the same. In bearishEngulfing the mql template file body is:

sqBearishEngulfing(<@printInput block />, <@printShift block shift />)

I don’t know why the function now is called sqBearishEngulfing instead of just BearishEngulfing, or does it matter? Neverthe less I don’t see any mql code in .tpl file itself, so where the mql code comes from? Is it copied/translated from SQ block .java file?

0

マーク・フリック

管理者、sq-ultimate、2件の返信.

プロフィールを表示

7年前 #248302

the template *.tpl file cotains only a call of the function to recognize candle pattern. The function (sqBearishEngulfing in this case) is itself defined in file SQ.mqh in the main language folder (MetaTrader4 or 5).

The easiest thing to do is to create your own funciton in this file, and then call it from the *.tpl file.

The only problem is that file SQ.mqh will be overwritten in the new update.

We will add support forcustom funcitons definitions for MT4/MT5 code generation.

マーク
StrategyQuantアーキテクト

0

ティモ

カスタマー、bbp_participant、コミュニティ、0件の返信。.

プロフィールを表示

7年前 #248370

Thank you Mark – makes sense now

I probably try to customize the SQ.mqh file for now as you suggested.

ティモ

0

6件の返信を表示中 - 1 - 6件目 (全6件中)