- ago
I want an exit when the VSI either stays the same or rises twice in a row. I have used the qualifiers listed for this. Unfortunately, it does not work. The result of the backtest shows a lot of trades that were already closed after one day. However, this should not be possible due to the exit logic. Have I overlooked something or is this a bug?


0
162
Solved
11 Replies

Reply

Bookmark

Sort
- ago
#1
0
Glitch8
 ( 10.92% )
- ago
#2
I haven't found a case where it isn't working correctly. Can you post an example screenshot of the chart?

Maybe you are mistaking the signal bar for the entry bar? Here on the signal bar the VSI rose two bars in a row, so it took the exit. On the bar of the exit, the VSI wound up going down at the end of the day, maybe that's what is throwing you off?

0
- ago
#3
Here is an example:



0
Glitch8
 ( 10.92% )
- ago
#4
You specified Greater than or Equal to, and it looks like the indicator values were will equal two bars in a row. Looks correct to me.
0
- ago
#5
I think I know what you mean. Could it be that WealthLab refers the condition to the signal bar and takes the candles before the signal bar? That makes sense for the entry. But not for the exit. How can I ensure that the exit is only counted from the entry bar?

After entry, the condition should be fulfilled.
0
Glitch8
 ( 10.92% )
- ago
#6
I’m not following. All Blocks are processed on a bar by bar basis. If you want something pinned to the entry bar that is a special case and you’d need to use C# code.

The strategy is doing exactly what you laid out in the blocks, no bug 🤷🏼‍♂️
0
- ago
#7
I would like to specify in the exit condition that the exit takes place if, for example, two consecUp bars occur after the entry. However, WealthLab seems to take into account the period before the entry, which is logical for the entry, but not for the exit. Below is a brief example of what I mean:



In this example, I want the entry to take place after three ConsecUp. However, the exit should only take place when the close rises for two more consecutive days. However, it does not work as shown in the blocks, as the logic does not refer to the day after the entry. Is there a way to map this logic via the building blocks or is it only possible via coding?
0
Glitch8
 ( 10.92% )
- ago
#8
“ However, the exit should only take place when the close rises for two more consecutive days. However, it does not work as shown in the blocks, as the logic does not refer to the day after the entry.”

I’m not following this, can you show an example on the chart of where this is not working as you’d expect?

Are you saying for the exit you only want to consider bars that occur after the entry? That’s an interesting assumption that so far no one else has had, and no that’s not how the exits work in blocks.

One possible solution might be the Power Pack block, Bars since Entry. If you add that Blocks and say Bars since Entry > 2 it might do what you’re looking for by excluding those prior bars.
0
Best Answer
Cone8
 ( 23.78% )
- ago
#9
If you want the Position to be open at least 2 days then add a "Trading Days in Trade >= 2" condition to the exit. (You might have to make it 3 because the entry bar is probably counted as the first day.)
0
- ago
#10
QUOTE:
However, it does not work as shown in the blocks, as the logic does not refer to the day after the entry.

The logic works irrespectively of entry or exit bar. Instead of keying off these points as you might imply, it rests upon the price dynamics itself.
0
- ago
#11
Thank you very much for the explanations. Now I understand the logic. Bars since Entry and Trading Days in Trade also help me a lot. Many thanks for that!
0

Reply

Bookmark

Sort