Welcome to NexusFi: the best trading community on the planet, with over 150,000 members Sign Up Now for Free
Genuine reviews from real traders, not fake reviews from stealth vendors
Quality education from leading professional traders
We are a friendly, helpful, and positive community
We do not tolerate rude behavior, trolling, or vendors advertising in posts
We are here to help, just let us know what you need
You'll need to register in order to view the content of the threads and start contributing to our community. It's free for basic access, or support us by becoming an Elite Member -- see if you qualify for a discount below.
-- Big Mike, Site Administrator
(If you already have an account, login at the top of the page)
So I made some Matlab code and a GUI that looked at the tick-by-tick ES (e-mini S&P 500) data provided for Elite members here and did some curve fitting using 8 part Fourier Series.
Above just shows a look at data from 06/15/2009-06/18/2009. The first box next to the chart shows the 1st derivative of the fitted curve and the second box shows the 2nd derivative.
Any thoughts? Perhaps on-the-fly curve fitting could be implemented in a trade strategy, with a fast enough computer?
UPDATE: Also confidence is just R^2 for those who care. And does anyone else think the data is remarkably harmonic in the last hour?
Fourier Analysis is useful, if you have a reason to believe that there are cyclical components in your time series and if you can identify the frequencies and eliminate the noise.
However, futures and stock prices mostly exhibit a non-linear behaviour, which means there are few such cyclical components to be identified.
If I look at your first chart, it shows a curve retro-fitted to data. At the right border - that is the place, where we want to predict price action and use the prediction for our trading - your curve exhibits a downward slope. If you please check what the market really did: it went up.
Curve fitting is a nice mathematical exercise. If you use a sufficient number of parameters, you can fit your curve to any past price action. But the curve has no predictive value. You can use it for interpolation but not for extrapolation.
Taking that data and drawing a simple trendline and wait until it is broken is more helpful. If you want to apply mathematics to trading, better look at volatility and autocorrelation than analyze supposed, but inexistant cyclical components.
There might by cyclical components in things affected by seasons, human-imposed or natural. Human-imposed would be futures rolls. Natural would be seasons.
In both cases that will involve looking at spreads.
Yes, of course there are natural and human cycles that do have an impact:
Day and night (as seen from the exchange where the instrument is traded): Participation (volume) and volatility during the night session is lower.
Weekly cycle: I have incorporated this cycle into my relative volume indicator by measuring the current volume against the average volume of the weekday.
Monthly cycle: Window dressing in the beginning of the month.
Yearly cycle: Seasonal impact for grain, energy. Tax season in May, etc.
If you talk about spreads, you are talking about agriculturals? I do not see many cyclical components in the note over bonds spread (as opposed to mean reversion, which can be assumed).
Fat i have a knowledge who uses this type of analysis (Fourier Analysis) to fine tune the parameters of his indicators and according to him this is the cream of the cream. For example, finding the optimal range per bar to use as interval for the ES or TF to name one. So to fine-tune our indicators would you consider it or do you think it's a lost of time ?
I agree with you when looking at big time periods but would you agree that on short time periods (~1 hr) there appears to be use for the fourier regressions?
Not sure that a naked DFT will reveil much of a cycle. You could have a look at the Corona Indicators developped by John F. Ehlers. He detrends the time series before analyzing for cycles. I have put the indicators on a 3 min chart for ES for last Friday.
If you look at the cyclical component, there was a dominant cycle with a period of around 28 in the beginning of the session. The lows were tradeable because of the trend that developped later in the day, the highs predicted were not impressive. The problem here is that the cycle amplitude was too small compared to the noise. The signal-to-noise stayed below 4DB during the first two hours, with a large corona, which means that the cyclical signal was week and the noise dominant.
Also to note that the cyclical component, which can barely be identified within price action, changed its period during noon - increased period - and then again prior to the close of the session. if I take into account the daily volatility smile, it is possible that the cycle analysis works better on range charts than time based charts. This is what the shorter cycle in the beginning and the end and the longer cycle in the middle suggest.
But this is just one day of observation. I do not think that cycle analysis is an easy route to success. But it is the sexiest indicator I have ever seen.
Indicators courtesy of @sefstrat can be downloaded here. They work with both NT 6.5. and NT 7.0