financequantitative-financefinancialwavelet

Denoise of Financial Time Series Data using Wavelet Transform


I need to denoise financial time-series data for a machine learning problem and don't understand how a wavelet transform is computed.

My understanding is that you need multiple points of a time signal to identify frequencies.

What does a wavelet transform do with the first point(s)? If there are not enough points, does it use future data to identify the frequencies? If yes, is it possible to give a wavelet transform to use data only from and in "t"?


Solution

  • Generally, there are three types of methods to process your [financial] time-series data:

    You may use time-frequency methods to denoise, categorize or classify financial time-series data, if you will. Time-frequency methods transform your [1-D] financial time-series data into a new [2-D] domain that you can see both time and frequency information Representation of a Wavelet Transform and Short-Time Fourier Transform (Widipedia).

    [1-D] Frequency domain methods only return frequency information of your [1-D] financial time signals, which means that your [1-D] time data will be lost in exchange for having [1-D] frequency data.

    [1-D] Time domain methods only return [1-D] time analysis of your financial signals, which also cannot help you to capture the frequency information.

    You may use a Continuous Wavelet Transform or a Discrete Wavelet Transform to denoise financial time-series data.

    There are many tools/languages that might help you to do so: MatLab, Python, and such. If you might have a programmer around you, s/he can probably help you in a few hours or a day to pass your [1-D] financial time data through one of these [2-D] time-frequency methods and visualize the outputs.

    Your question is primarily about sampling rate. If your sampling rate is too low, thus frequency domain method may not return accurate resolution for you (regardless of Nyquist theorem). However, if you use such method for denoising, it normally means you have high-frequency data and [usually] you may want to down-sample or filter your data.

    I suggest you to read about mathematics of wavelets with respect to mother and child (e.g., Morlet, Daubechies, etc.) which will help you to understand how a base function maps throughout your financial time-series data, the transformation occurs, and a new time and frequency representation of your initial financial time-series data result in.

    As you know, Wavelet is a mathematical transform. As you wish, you may give almost any input data to the transform equation and will transform it for you. You may initially pick a window size. Imagine, you have a 1X1000 vector of [0,1,0.3,1.2,-1,...] equity or derivative information as your window, or any other larger size window 1X1,000,000. It may not matter, if your data is from the past or you predict from the future and transform it via wavelet.

    As you know, financial [chart] data usually as time passes, have an additional [data point] record, either a real data point or a forecasted one. In that case, It is absolutely fine, and you may shift your window in near-real-time on a new window, either making your window larger or removing the first data point and appending your new data point to your window. That delata time can be any fraction of time. You may just need to also consider computation, later for scale-up, which may not be an issue for you at this time.

    My general view about your approach, not knowing many assumptions, is that you are in a challenging yet really great direction.

    Wavelet Shifting and Scaling

    Image Courtesy: Harvard University

    Good project, best wishes, thank you for your question and welcome to stackoverflow.com!