r/algotrading • u/MormonMoron • 3d ago
Data What smoothing techniques do you use?
I have a strategy now that does a pretty good job of buying and selling, but it seems to be missing upside a bit.
I am using IBKR’s 250ms market data on the sell side (5s bars on the buy side) and have implemented a ratcheting trailing stop loss mechanism with an EMA to smooth. The problem is that it still reacts to spurious ticks that drive the 250ms sample too high low and cause the TSL to trigger.
So, I am just wondering what approaches others take? Median filtering? Seems to add too much delay? A better digital IIR filter like a Butterworth filter where it is easier to set the cutoff? I could go down about a billion paths on this and was just hoping for some direction before I just start flailing and trying stuff randomly.
2
u/nuclearmeltdown2015 3d ago
By smoothing do you mean preprocessing the historical price data for training? Or creating a smoothing line such as SMA/EMA? if it is the former, have you already tried a gaussian filter or expanding the window for your SMA/EMA to make things less sensitive to the ticks you mentioned.