Dynamic Micture Models

Discussion in 'Automated Trading' started by Terrylee, Oct 14, 2009.

  1. Terrylee

    Terrylee

    It may not be the right place to ask.

    I have cycles very good at picturing market regimes which I trade manually quite successfully. I like to automate part of it and started reading about Dynamic Mixture Models as a mean to switch from one regime to the next. It looks like these models are very good at finding predictive semantic from pattern associations.

    Is anyone has looked into this already? Is it worth spending the time?

    Thanks

    Terry
     
  2. Corey

    Corey

    From my experience, Dynamic Mixture Models are typically used for some sort of unsupervised learning task. They are all fine and good, but you need some fundamental understanding of your problem domain so you can pick the best distributions to fit your problem (i.e. your mixture density). Though, I suppose there are methods that allow you to estimate your mixture model from empirical data.

    Might want to check out: http://wiki.stat.ucla.edu/socr/inde...ls_Activities_2D_PointSegmentation_EM_Mixture for some practical examples of Dynamic Mixture Models.
     
  3. First, you need to quantitatively and objectively define what regime actually means (not qualitatively). And that is no easy feat.

    Then, you need to define a common range variable that your regimes are conditionally dependent upon.

    If you get that far, then considering there is sufficient separation between your previously defined regimes, then you can start to consider how your question might be useful.

    Setting up the problem is likely more difficult than solving it. There is some discussion (not utilizing mixture modeling) about regime switching via probabilities in the book titled, 'long short market dynamics.'
     
  4. Terrylee

    Terrylee

    Good to hear from knowledgeable traders!

    My definition or regimes is quite loose but more signal oriented than practiced in academic spheres; as long as they represent recurring and hopefully reliable behaviors. In this particular case it is based on the observation that cycles shift from one time frame to another. For example a cycle can shift to a larger one due to institutional traders placing huge bets on the daily crossover.

    Thanks
     
  5. ok, so then you need to quantify it a bit more.

    If you are using cycles to identify dominant modes, then perhaps you can run a histogram of the cycles you record.
    If the histogram shows one or more dominant modes, you could identify the regimes by the modes you've identified.

    Mixture modeling would work with this type of information, but you can also look into quadratic discriminant analysis.

    The obvious problem is that this only identifies regimes in hindsight. You have to do a bit more work beyond this to make it useful.
     
  6. Terrylee

    Terrylee

    I looked into Discriminant analysis already because of its stepwise extension. However, the need for the covariance matrices to be homogeneous was a show stopper. Instead I used a Latent Dirichlet Allocation Model for witch the word count was replaced by the co-occurrence of cycles in different time scales. I have now a good picture as to why the shifts that I am eyeballing are so reliable but encoding time is still an issue.
     
  7. Terry,

    what are "mixture models"?


    let's start there, for the unfamiliar
     
  8. That's an interesting approach. I think I'm still not understanding how you are formulating the problem description specifically enough.

    From my interpretation, all these methods are still classifying past observations into one regime or another.
    I am still missing how it infers the out of sample regime and exactly what it is conditioned upon.

    Anyways, you can PM me with more details if you want more detailed feedback. I always like to hear about these approaches.

    Otherwise, keep the board posted with your results. You have some refreshing ideas.
     
  9. - What software are you using? Those forums would be the place to ask. I have been looking into MatLab, WEKA, and R for similar analysis.

    - From what I've read recently, ensemble methods are getting more popular.

    - In the classic sense of mixture, where one combines multiple gaussian distributions, I'd say don't forget KISS. Simpler linear models often perform better than complex (gaussian) neural network models, in my backtesting.


     
  10. Terrylee

    Terrylee

    limitdown
    A mixture model is an ensemble of functions which number, location and parameters have been chosen to represent the density in a data set. The functions (also called kernels) can be any kind of distribution. This applet shows an example where you can choose a Gaussian or a line as kernel. http://www.neurosci.aist.go.jp/~akaho/MixtureEM.html

    Dtrader98
    The paper that first caught my attention describes a “dynamic” version of mixture models for which the out-of-sample extension is done through signal reconstruction.
    http://www.aaai.org/Papers/IJCAI/2007/IJCAI07-468.pdf

    In my case the data points represent the shifts of orders from one timeframe to the next so a natural out-of sample extension for it is the cycle in the larger time frame itself. Now that I know more about it, I think that Dynamic Mixture Models are able to learn the “quasi periodic” occurrence of these shifts. I might go ahead with some experiments…

    Stoxtrader
    I make dlls in c++. This way I know what I do. But you are right I could also ask the MatLab community about it although I am mostly interested in getting some impressions from traders on the cycle shift phenomenon.
     
    #10     Oct 23, 2009