Saturday, December 15, 2007

Shannon's Investment Strategy

Was reading the book 'Fortune's Formula', which I highly recommend. Claude Shannon, the genius of Information theory fame, came up with an approach to investing in the market using a interesting variant of Kelly's betting approach.

Assuming a market with constant mean (no drift / trend over time):
  1. Invest 1/2 of your capital in an asset
  2. Periodically rebalance
  3. If the market went up, sell enough units of the asset to have exactly 1/2 of your capital invested
  4. If the market goes down, buy enough units of the asset to maintain 1/2 investment
This is an effective scheme (assuming no transaction costs). Why?
  1. rebalancing implicitly executes a mean reversion strategy
  2. losses reduce the capital in the market
  3. wins increase the capital in the market
In effect, this is a ratcheting investment approach. As was pointed out, most assets are not constant mean over time. This would imply a strategy that trades mean reversion around a longer term drift in the mean. How might such a strategy work?
  1. since drift might be upwards or downwards, fundamental position should be long or short
  2. rebalancing should take into account the expected movement of the mean so that the ratio of cash to position will depend on this
This is referred to as a Constant Rebalanced Portfolio (CRP). Thomas Covers, later extended on this concept with non-even distribution of allocations with his Constant Universal Portfolio (CUP).

Sunday, December 9, 2007

Price Path Probability

What is the probable path of a security over the next 1 second, 5 seconds, 30 seconds?

I attended a quantitative algorithmic trading seminar 3 weeks ago where one presenter was discussing fill probability (in general terms). The presenter claimed that their model predicts the price path over the next few minutes to determine how best to read a VWAP strategy.

While I don't believe it is possible to predict a specific price path, it is possible to determine the probability of any given price path. If we can determine the probability of any given path through time from the current price to some final price in N seconds or minutes, we can compute the expected probability of going through a price level within some period of time.

The expected probability through a node at time Tn at price level Pa on a multinomial tree will simply be the sum of the probability of all sub-paths from Ts to Tn going through Pa. That part may be simple, but accurately determining the likely paths / probabilities is a hard research problem.

Given that the number of paths is exponential with time, the farther out we look the more time it takes to compute a precise expectation. We must use a monte carlo analysis, sampling a calibrated timeseries equation, to approximate the expectation function.

Determining the timeseries function that accurately reflects the market is a very hard research problem. Alas, if I told you my approach would have to kill you ;)

Wednesday, November 21, 2007

Trading Signals

I'm putting together a framework to evolve, test, and optimize signals using a genetic algorithm approach. Signals with statistically significant results will be further combined into bayseian networks and fed back into this testing framework.

Determining the conditionality of one signal against another requires insight and guesswork, or evaluating permutations of networks. With a GA optimizer and enough computing power should be able to determine networks that successfully amplify the combination of signals to one that is correct more often than not (or at least is more successful in the profitable situations than the losing ones).

The universe of events and indicators that have potential to be significant is large, as are their parameterizations. Choosing the search space will be a challenge, as is sometimes having access to the required data.

I plan to overlay our tick UI with trading signal indicators indicating a probability weighting when a signal reaches a non-neutral threshold. Should be interesting to visualize the results.

Thursday, November 8, 2007

Long / Short

I noticed that BIDU, one of the stronger stocks in the chinese market has outperformed FXI consistently both with upside and downside market moves. In other words, when the market is in a strong downward trend (as it is now), BIDU has gone down less than FXI. When the market was appreciating BIDU outperformed FXI.

Assuming this relationship holds on the near term, speculative play: long BIDU, short FXI. Should yield return in an upward or downward trending market.

Wednesday, November 7, 2007

Spread Plays

The china vs taiwan spread trade has done well in the short term with 7% gains over the last two days, but not for the reasons I discussed in the previous post. I noticed that the markets are cointegrated, however moves in the china market (both positive and negative) have a steeper slope, so that positive and negative moves are bigger with FXI than for EWT.

Given the current downward trend for FXI, the FXI - EWT spread contracted, yielding 7%. Of course should the trend reverse and FXI recover, would expect the spread to flip back to a widening phase.

I think a better trade at this point is a view towards continued growth in the indian market accompanied with a deflation of the chinese market bubble. Speculative trade: short FXI, long INP.

Friday, November 2, 2007

Spread play: China vs HK market?

If one looks at the annual performance of FXI (China index) versus EWH (HK index), we see a widening spread over the last year, but a lot of simularity in the chart patterns. I suspect these markets are cointegrated, but with a scaling factor (a difference in slope).

This article indicates that chinese will soon be able to invest in the HK market. With the huge flow of speculative money in China soon to be able to find alternative venues (such as HK), should expect to see a move of some of this buying pressure into the HK market.

A speculative play: looking to see a contracting FXI - EWH spread. Trade: buy EHW, sell FXI.

A Bad Deal?

I was looking at investments offered in my offshore account and came across the following structure:
  • 5 year investment into china fund
  • capital preservation (built-in floor at initial investment level)
  • max 55% return total across 5 years, the bank pockets the excess above
For someone not in the financial business this may seem to be a good deal (seeing the 55% and capital preservation). I think it is a relatively poor deal though. The continuously compounded effective annual rate is only ~8% and that is only achieved if the market does indeed appreciate 55%.

I began thinking about how closely could replicate this structure on my own, but with a much higher max payoff. Though the payoff function I am going to indicate is not perfect (I can go under my initial capital if the timing of my protection is not right), would do as follows:

Initially
  • buy into FXI index
  • allow some appreciation and then buy the 1 month put option at the initial point of entry
On an ongoing basis:
  • roll put option at initial investment point + cost of option premiums thus far, maybe with longer maturity
  • if FXI drops below initial investment, sell FXI, sell option, coverage should be close to offsetting
  • as and if FXI approaches entry point buy in again and buy protection
  • repeat
Of course one can structure this more advantageously:
  • additional protection (by adjusting strike upwards as FXI gains)
  • reentering trade if FXI falls at lower level rather than initial investment level

The cost of the options is paid for out of the returns or in the worst case through the adjusted strike price. That said, increasingly, the options are going to be deeper and deeper out of the money if FXI continues to be a good investment (meaning cheaper hedging costs).