- ago
Hi,
I am making a strategy using Kalman filter and BB.
In sell at market condition, How to create a strategy to sell when the "Kalman crosses over BBupper" condition occurs more than 2 times?

0
531
Solved
2 Replies

Reply

Bookmark

Sort
- ago
#1
QUOTE:
condition occurs more than 2 times?

Does that mean the Kalman crosses "over" the BB bands, and then crosses "under" the BB bands? That is, you want to detect the zigzag (both ways) across the BB bands?

Why have you selected the Kalman filter for this operation? Usually the Kalman filter is employed to help forecast the future and extrapolate to the next bar (while suppressing noise effects), but we aren't doing that here. Would an adaptive (i.e. fast acting with minimal time shift), smoothing filter work better than the Kalman filter for a cross over/under study? Have you considered using the DSMA filter (instead of the Kalman) by John Ehlers instead? It's in the TASC library. (Perhaps the Kalman is able to "double back" faster than other filters? I asking if this may be true.)
0
- ago
#2
It's simple with Building Blocks. Take "N Times within N Bars" qualifier.
0
Best Answer

Reply

Bookmark

Sort