Gamestudio Links
Zorro Links
Newest Posts
Is it possible to find robust systems?
by Grant. 10/17/21 16:22
What are you working on?
by rayp. 10/17/21 12:01
Lapsa's very own thread
by Lapsa. 10/17/21 10:58
Orders not found
by dpn. 10/16/21 16:57
Price of entry with OrderDelay
by Zheka. 10/16/21 00:03
Lots and TestTrades.csv
by Mariano. 10/15/21 16:39
AUM Magazine
Latest Screens
Tactics of World War I
Hecknex World
Scheherazade's Journey
Paradox Vector
Who's Online Now
4 registered members (NobbyG, Lapsa, 7th_zorro, dpn), 488 guests, and 5 spiders.
Key: Admin, Global Mod, Mod
Newest Members
KoenC, Cuttyflame, Chiller, Avedon, pounceyzorro
18693 Registered Users
Active Threads | Active Posts | Unanswered Today | Since Yesterday | This Week
Starting with Zorro
Yesterday at 16:22
1. I'm confident you can, but it can be a long road of testing & evaluating certain concepts, rules, models, etc.
2. Not yet!
3. I believe that machine learning is def the way to go. These algos are way more objective & sophisticated than simple trading rules (please forget technical analysis).
4. Create a large data set, train a model (I use R), while preventing over-fitting as much as possible by applying techniques like cross-validation or the AIC or BIC criterion and out-of-sample test this in Zorro. Store all results in an organized way.

Bonus tip: there are esp 3 important concepts about machine learning that you need to understand: sample size determination, variable-selection methods (i.e. variable importance) and the bias-variance tradeoff.
1 28 Read More
Projects
Yesterday at 12:01
In motion its pretty cool too. Of course i will.
Thanks for your interest.
5,523 27,884,926 Read More
Zorro Scripts
Yesterday at 10:58
still around, tuning my indicator soup, slowly scaling up

zero to hero porn:

[Linked Image]
44 2,238 Read More
Starting with Zorro
10/16/21 16:57
Hello,

Is there any mql experienced person that can explain to me why I get this kind of error every time I restart zorro (due to win 10 home edition mandatory update) while a strategy is running?

Example --> "Not found: Order 1227668080 Ticket 227668080 Offset 1000000000"

All real open trades are "not found" with this message (...offset 1000000000), while the phantom trades are correctly resumed.



The error appears to be related to this part of the zmq4.mqh file (row 109)

// handle tickets that exceed the int range

static ulong TicketOffset = 1;
int ticket32 (ulong Order)
{
ulong Ticket = Order% 1000000000;
if (TicketOffset == 1 && Order> 0)
TicketOffset = Order - Ticket;
// Print ("Order", Order, "Ticket", Ticket, "Offset", TicketOffset);
return (int) Ticket;
}




Thank you
0 42 Read More
Automated Trading
10/16/21 00:03
To support the above, this script
Code
int tmf() {
	
	if (TradeIsPending)
   	watch("#time=",tod(0), priceOpen(0), priceHigh(0), priceLow(0),priceClose(0));
	
	return 0;
}

function run() {
	NumYears=1;
	
	set(LOGFILE, TICKS);

	Verbose=3;
	
	Slippage=0;
	RollLong=RollShort=Spread=Commission=0;
	
	LifeTime=5;
	
	Entry=-3*PIP;
	
	OrderDelay=59.9; //119.9, 120.0
	
	if (NumOpenLong==0)
	 if (priceClose(0)>priceClose(20) ) 
		enterLong(tmf); 
}
produces this output at different OrderDelay:
Code
[165: Wed 21-01-13 00:00c] -2.74 0 1/3 1.22061/1.22104\1.22025/1.22094 -0.0
Enter Long EUR/USD  Entry -0.00030000 Delay 59.9 at 00:00:00
(EUR/USD::L) Long 1@1.22064 Entry limit
time= 0 1.22061 1.22104 1.22025 1.22094 
time= 1 1.22094 1.22102 1.22094 [color:#CC0000]1.22102[/color] 
[EUR/USD::L16602] Long 1@[color:#CC0000]1.22094[/color] x at 00:01:00

[151: Tue 21-01-12 10:00] 1.21527/1.21797\1.21509/1.21624 -0.0
Enter Long EUR/USD  Entry -0.00030000 Delay 60.0 at 10:00:00
(EUR/USD::L) Long 1@1.21594 Entry limit
time= 1000 1.21527 1.21797 1.21509 1.21624 
time= 1001 1.21624 1.21636 1.21614 [color:#FF0000]1.21629 [/color]
[EUR/USD::L15202] Long 1@[color:#CC0000]1.21619[/color] x at 10:01:00

[213: Fri 21-01-15 00:00c] -10.75 0 1/7 1.21532/1.21595\1.21507/1.21513 -0.00003
Enter Long EUR/USD  Entry -0.00030000 Delay 118.9 at 00:00:00
(EUR/USD::L) Long 1@1.21483 Entry limit
time= 0 1.21532 1.21595 1.21507 1.21513 
time= 1 1.21513 1.21518 1.21512 [color:#FF0000]1.21515 [/color]
time= 2 1.21513 1.21522 1.21512 [color:#CC0000]1.21522 [/color]
[EUR/USD::L21403] Long 1@[color:#CC0000]1.21510[/color] x at 00:02:00

[448: Fri 21-01-29 01:00c] -14.80 0 14/15 1.21216/1.21226\1.21043/1.21079 -0.0
Enter Long EUR/USD  Entry -0.00030000 Delay 118.9 at 01:00:00
(EUR/USD::L) Long 1@1.21049 Entry limit
time= 100 1.21216 1.21226 1.21043 1.21079 
time= 101 1.21079 1.21087 1.21070 [color:#CC0000]1.21081[/color] 
time= 102 1.21079 1.21091 1.21070 [color:#CC0000]1.21081 [/color]
[EUR/USD::L44905] Long 1@[color:#CC0000]1.21075[/color] x at 01:02:00

[1236: Wed 21-03-17 18:00c] 1.19022/1.19109\1.18983/1.19106 -0.0
Enter Long EUR/USD  Entry -0.00030000 Delay 118.9 at 18:00:00
(EUR/USD::L) Long 1@1.19076 Entry limit
time= 1800 1.19022 1.19109 1.18983 1.19106 
time= 1801 1.19106 1.19457 1.19106 [color:#CC0000]1.19418 [/color]
time= 1802 1.19106 1.19625 1.19106 [color:#CC0000]1.19598 [/color]
[EUR/USD::L23713] Long 1@[color:#FF0000]1.19403[/color] x at 18:02:00

[347: Fri 21-01-22 17:00c] -11.27 0 10/11 1.21727/1.21824\1.21711/1.21782 -0.0
Enter Long EUR/USD  Entry -0.00030000 Delay 120.0 at 17:00:00
(EUR/USD::L) Long 1@1.21752 Entry limit
time= 1700 1.21727 1.21824 1.21711 1.21782 
time= 1701 1.21782 1.21799 1.21782 [color:#990000]1.21787 [/color]
time= 1702 1.21782 1.21799 1.21778 [color:#CC0000]1.21782 [/color]
time= 1703 1.21782 1.21799 1.21773 [color:#990000]1.21785[/color] 
[EUR/USD::L34804] Long 1@[color:#CC0000]1.21778[/color] x at 17:03:00

[646: Wed 21-02-10 13:00] -13.81 0 21/26 1.21249/1.21250\1.21138/1.21173 -0.0
Enter Long EUR/USD  Entry -0.00030000 Delay 120.0 at 13:00:00
(EUR/USD::L) Long 1@1.21143 Entry limit
time= 1300 1.21249 1.21250 1.21138 1.21173 
time= 1301 1.21173 1.21189 1.21151 1.21158 
time= 1302 1.21173 1.21189 1.21150 [color:#CC0000]1.21169 [/color]
time= 1303 1.21173 1.21189 1.21150 [color:#CC0000]1.21173 [/color]
[EUR/USD::L64707] Long 1@[color:#CC0000]1.21162[/color] x at 13:03:00

'Slippage' also works in some interesting ways:
//------------------if Slippage is not 0.--------------
Code
[260: Tue 21-01-19 02:00] -14.97 +1.33 2/9 (1.20939)
time= 201 1.20939 [color:#009900]1.20941[/color] 1.20936 1.20938 
[EUR/USD::L25503] Expired 1@[color:#009900]1.20942:[/color] +1.36 at 02:01:00

[261: Tue 21-01-19 03:00] -13.61 0 2/9 (1.20953)   
(EUR/USD::L) Long 1@1.20923 Entry limit
time= 300 1.20939 1.20987 1.20914 1.20953 
time= 301 1.20953 1.20956 [color:#009900]1.20931 [/color]1.20932 
time= 302 1.20953 1.20956 [color:#009900]1.20930 [/color]1.20935 
[EUR/USD::L26203] Long 1@[color:#009900]1.20928 [/color]x at 03:02:00
1 108 Read More
Starting with Zorro
10/15/21 16:39
Thank you.

I forgot to change the PIPCost accordingly LotAmount.
2 149 Read More
Zorro Future
10/15/21 16:17
jcl,

in 2.42.5, TMFs are now called when a trade is pending, great.

However, there is something wonky going on when TMF returns 4.
Code
int tmf() {
	
      watch("#time=",tod(0));

if (TradeIsEntry) return 4;

	return 0;
}

function run() {
	NumYears=1;
	
	set(LOGFILE, TICKS);
			
	LifeTime=5;
	
	Entry=-3*PIP;
	
	if (NumOpenLong==0)
	 if (priceClose(0)>priceClose(20) ) 
		enterLong(tmf); 	 
}
produces some weird output:
Code
[104: Fri 21-01-08 08:00] 0000 0 0/0 (0.776700)
(AUD/USD::L) Long 1@0.776400 Entry limit
time= 800 
(AUD/USD::L) Missed entry 0.77753 after 1 bar       <---???
(AUD/USD::L) Entry limit 0.776400 hit at 0.776090 08:01:00
time= 801 

[105: Fri 21-01-08 09:00] 0000 0 0/0 (0.776450)
(AUD/USD::L) Long 1@0.776150 Entry limit
time= 900 
(AUD/USD::L) Missed entry 0.77640 after 1 bar    <---???
time= 901 
time= 902 
time= 903 
time= 904 
(AUD/USD::L) Entry limit 0.776150 hit at 0.776080 09:05:00
time= 905 

TMF now does not run once the trade is open!?
9 302 Read More
Jobs Wanted
10/15/21 12:00
16 1,668 Read More
Showcase
10/13/21 12:22
Looking really good!
371 872,294 Read More
Starting with Zorro
10/13/21 07:39
Oh, right! Thank you very much, I didn't consider that!
2 105 Read More
Zorro Future
10/12/21 16:24
Originally Posted by jcl
I believe that can be enforced by setting Slippage to the negative bar period time.
Ah yes, I'm not sure how I missed that, thanks.
2 118 Read More
Starting with Zorro
10/12/21 13:31
I am not sure that I understood the problem, but priceHigh(1) is the high of the last time period, not the high of the last day. Make sure that the bar period is not smaller than your historical data resolution, and that the main asset is selected in your script before any secondary assets.

https://manual.zorro-project.com/asset.htm
1 136 Read More
Starting with Zorro
10/11/21 14:49
Thanks - I'll give it a go.

Perhaps you could consider the ability to save and replay results as a feature?

For slower tests, this would be useful, I think.
4 211 Read More
Blame the Manual
10/11/21 14:34
Thanks, ldate was missing in the index.

The different commission formulae are for different calculations. 1) is the conversion of percentage to amount and 2) the commission of a trade. And I think indeed that LotAmount does not belong in 2) because it's already contained in the pip cost. So it should cancel out. I'll check that and make it more clear in the manual.
1 149 Read More
Starting with Gamestudio
10/11/21 01:35
I have made a bitmap text in Photoshop. Yes, it is a pain.
5 180 Read More
A8 Engine
10/10/21 13:41
Great!
Thank you.
3 132 Read More
Starting with Zorro
10/10/21 00:45
Quick question: so, on each invocation of run(), the series values in, say, series[0] should give the current value that was calculated, independent of how many are being stored via the lookback period default length? Am assuming that the series acts like a queue, with data shifted from [0] to [1]...up through [lookback length -1] and the new data being placed in [0].

TIA for any responses,
Vode
3 118 Read More
Starting with Zorro
10/07/21 15:25
@jcl,

Thanks!

For combining/merging History files, is there a helper script I've missed?

Thanks.
6 283 Read More
Starting with Zorro
10/07/21 14:52
It does. Whatever the problem is, it's likely neither commission nor balance.
3 155 Read More
Starting with Gamestudio
10/06/21 15:00
As mentioned, WWRAP only works with truetype fonts. If you are using a bitmap font, it will keep going past the entry box, as you show in your first example.
9 587 Read More
Jobs Wanted
10/05/21 14:12
Looking for new games to work on!
58 12,756 Read More
Starting with Zorro
10/04/21 12:14
Thank you both for the replies smile

If its default behavior I can live with it. I am using limit / pending orders so its not a big issue.
5 168 Read More
Starting with Zorro
10/04/21 09:03
Maybe something about lot amounts and lots. One of them is fractional, the other isn't. Read the manual:

https://manual.zorro-project.com/lots.htm
1 110 Read More
Starting with Zorro
10/03/21 10:25
I know that at least with IB you had to call optionprice for any option to get the delta and it takes a looong time. For speeding up, get delta only for a few options and then interpolate.
3 165 Read More
Starting with Zorro
10/02/21 16:39
Hi everyone,

there are some differences how a commission is calculated in different parts of the Zorro-manual.
First I thought only one can be right. But meanwhile I don't think either is.

1.) https://www.zorro-trader.com/manual/en/account.htm
Text:
"...percentage of the trade value...negative percent value... The commission is then automatically calculated from the percentage using the formula Commission = -Percent/100 * Price / LotAmount * PIPCost / PIP. "

Formula in text: Commission = -Percent/100 * Price (/ LotAmount * PIPCost / PIP)

In other ways: -Percent/100 * Price * (Exchange rate counter -> account-currency)
--> Aren't the Lots missing here?

2.) https://zorro-project.com/manual/en/spread.htm
Text:
"If a negative percent value is given (f.i. -0.25 for 0.25%), the commission of a trade is Percent/100 * PIPCost/PIP * Price * Lots * LotAmount."

Formula in text: Commission = Percent/100 * PIPCost/PIP * Price * Lots * LotAmount.

--> Should this be maybe: " / LotAmount" instead of " * LotAmount"?
or should PIP and LotAmount be in brackets?

3.) I think this one should be right: Percent/100 * PIPCost/PIP * Price * Lots / LotAmount.

This would be then: -Percent/100 * Price * Lots * PIPCost / PIP / LotAmount.
= -Percent/100 * (Tradevolume in counter currency) * (Exchange rate counter currency -> account-currency)

Can anybody confirm this?
And can this be fixed in the mentioned links please?
0 106 Read More
Page 1 of 3 1 2 3

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1