読み取り専用

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

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

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

ご参加ください Discord YouTube

Coding Questins

4件の返信

ステアノ

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

プロフィールを表示

13年前 #110895

Few questions I have come across:

1. I want to enter when MA is acting as support. So I want to buy when a bullish candle formation occurs within x number of pips of the MA. How can I code this in EA Wizard? I htought about "Close" < MA+ConverttoRealPips(parameter that is 5), but I was did not know if this was correct. Here is the code I have so far:

2. I want to limit trading by a start time and an end time. Am I doing it correctly?

Paremeters:

コード

3. I noticed on the example EA's that the code always included "Is Bar Open is True". Does this need to be in every EA – it is what starts the logic pattern?

Thank you, Mark!

ステアルノ

0

マーク・フリック

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

プロフィールを表示

13年前 #120905

1. I want to enter when MA is acting as support. So I want to buy when a bullish candle formation occurs within x number of pips of the MA. How can I code this in EA Wizard? I htought about “Close” < MA+ConverttoRealPips(parameter that is 5), but I was did not know if this was correct. Here is the code I have so far:

the condition [b]Close < MA+ConverttoRealPips(5)[/b] will be true if Close price is lower than value of MA + 5 pips, it is probably what you want to achieve.

2. I want to limit trading by a start time and an end time. Am I doing it correctly?

no, you have two mistakes there:
– the time parameters cannot be given as a string – like 08:00. You have to split them to hour and minute (or only use hour part if minute will be always 0).
So your parameters shoudl be:
StartTime1 int 8
EndTime1 int 16
StartTime2 int 14
EndTime2 int 17

– then in the condition you can either use Hour[0] > StartTime1
or if you want to use Time[0] then youhave to use function GetTime() on the other side of comparison, like
Time[0] > GetTime(StartTime1, 0, 0)
そして
Time[0] < GetTime(EndTime1, 0, 0)

3. I noticed on the example EA’s that the code always included “Is Bar Open is True”. Does this need to be in every EA – it is what starts the logic pattern?

yes, every EA contains preparation for the use of this variable, but it is not used unless you use it inn your trading rule.

マーク
StrategyQuantアーキテクト

0

ステアノ

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

プロフィールを表示

13年前 #120910

Thanks, Mark! On, the limitation of trading by hour: if I say 6 in the StartTime1 field and say >, then that means it would start trading at 7. So if I want it to start at trading at 0600, then I should use >=, correct?

Lastly, do I use 6 or 06? It appears by your answer above, I use 6 but wanted to be sure.

0

マーク・フリック

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

プロフィールを表示

13年前 #120918

Thanks, Mark! On, the limitation of trading by hour: if I say 6 in the StartTime1 field and say >, then that means it would start trading at 7. So if I want it to start at trading at 0600, then I should use >=, correct?

Lastly, do I use 6 or 06? It appears by your answer above, I use 6 but wanted to be sure.

yes, if you want to start at 6 you should use Hour[0] >= 6

You should use 6, it is a number, not text

マーク

マーク
StrategyQuantアーキテクト

0

ステアノ

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

プロフィールを表示

13年前 #120925

Thanks, Mark.

0

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