Support Board
Date/Time: Sun, 07 Sep 2025 19:22:19 +0000
[Programming Help] - Multiple entries triggered occasionally by pyramiding logic
View Count: 123
[2025-08-13 17:27:31] |
User929025 - Posts: 10 |
I have set up a spreadsheet trading study which allows automatic pyramiding from an initial manual entry if PL conditions are met. K3 Buy Entry logic reads: =OR(P3=1,Q3=1) P3 reads: =AND($J$8=1,$J$10>=250) to check the current position size is 1 and the current open position profit is >=250 Q3 reads: =AND($J$8=2,$J$10>=750) to check the current position size is 2 and the current open position profit is >=750 I find that occasionally either entry triggers 2 fills and I end up with a position of 4 rather than the planned 3. Why is this happening and what can I do to prevent it? I know I can set the maximum position size, but this doesn't deal with the issue of getting 2 fills at the first pyramid rather than 1. |
[2025-08-14 13:10:36] |
Sawtooth - Posts: 4261 |
Why is this happening and what can I do to prevent it?
K3 would need more than =OR(P3=1,Q3=1) to initiate the position.When you are flat, P3 and Q3 would be 0. Are you noticing this occurring at a new bar? If 'Reset Condition on New Bar' is set to Yes, and J10 is at 250 or 750 at a new bar, it might take another entry. |
[2025-08-14 19:20:53] |
User929025 - Posts: 10 |
Hi Sawtooth, yes the initial position is a manual entry rather than an automated entry, this system is just designed to automate trade management after a discretionary initial entry. Hence K3 works for these purposes. The double entry occurs at the same bar. I suspect it may be just a problem with sped up back tests, there is not enough time for the computer to check J8 to avoid a second fill.
|
[2025-08-14 19:41:09] |
Sawtooth - Posts: 4261 |
I suspect it may be just a problem with sped up back tests, there is not enough time for the computer to check J8 to avoid a second fill.
This is entirely possible, and I've witnessed things like this using high speed replays.
|
To post a message in this thread, you need to log in with your Sierra Chart account: