What is the difference? - page 2

 
ggekko:

No.

"in your first code you are giving TP_Day the datetime value" WHY???

TimeDayOfYear(TimeCurrent())

 Is this datetime?! I think this is integer.

TimeDayOfYear(TimeCurrent())
Does not appear in your first block of code it is in the second block
 
GumRai:
Does not appear in your first block of code it is in the second block
TimeDayOfYear(TimeCurrent())

There are a "wrong" and a "good" block. This code appers in both of them. Please, see again.

 
TP_Day=(int) GlobalVariableGet(Glob_Var_Name);
Do you know what it does (highlighted) ? If you can answer correctly, GumRai will answer you. If not, he will not answer you.
 
deysmacro:
Do you know what it does (highlighted) ? If you can answer correctly, GumRai will answer you. If not, he will not answer you.

What do you think, why did I ask this:

"What does "(int)" actually do?"

So, do I know what it does?

I do answer: no.

Again, I ask: "What does "(int)" actually do?"

And again:

In this formule:

TP_Day=(int) GlobalVariableSet(Glob_Var_Name,TimeDayOfYear(TimeCurrent()));

what does (int) do? Why do I get a datetime instead of an integer for TP_Day?

Am I wrong that TimeDayOfYear has to return an INTEGER value?

 
Ok. Let me ask you. What type GV store its value ? If you got it wrong, this will be the end from me.
 

I see, my fail. I'm a bit tired. Sorry, thanks.

Another issue:

Backtesting.

Same instruments, same lot sizes, same TP and SL. No swaps. Different result in money. How can it be?


 
Spread ? Gap between Ask - Bid.
 
deysmacro:
Spread ? Gap between Ask - Bid.

I don't think it is spread. I think spread is included in those values.

Anyway, spread was standard 3 pips (30 points).

 
Ok. You are the smart one here.
 
deysmacro:
Ok. You are the smart one here.

You are wrong. If it were the spread, the different would be 3USD because of the 0.1 lot. The different isn't 3, but 1.62.

What about commission? Is it possible to modelling the commission in the backtest?

Reason: