Sunday, January 21, 2007

Rich Dad's Guide to Investing

Robert T. Kiyosaki's Rich Dad's Guide to Investing isn't particularly well written, but it contains a fair number of good ideas. The prose is repetitive, and many of the ideas have appeared in other books in the Rich Dad, Poor Dad series. Nevertheless, I found it valuable. The subtitle ("What the Rich Invest In, That the Poor and Middle Class do not") indicates some of what I found in the book.

For a couple of decades, I was a pretty dedicated mutual fund investor. I read the (popular technical) literature, and understood the predominant returns of index funds, and the value of diversity. I continue to subscribe to the No Load Fund Investor newsletter, and use their recommendations to balance the portion of my portfolio that isn't in real estate.

But over the last few years I've moved most of my investments to real estate. The real estate group I've joined does an excellent job of providing education in the fundamentals of real estate investing. I feel competent to evaluate the value of an investment, the likely cash flow and prospects for appreciation. But it's clear that there is a lot more to learn, and many other kinds of investment projects to consider.

The Rich Dad series does a good job of explaining the basics: how to think about cash and cash flow, why real estate investment pays off whether the market is going up or going down, how the tax advantages work, etc. The books share similar stylistic problems; they're repetitive, anecdotal and simplistic. But there's good information in the books, it's not just hype, and if you pay attention, the books do give useful ideas on how get started and to proceed. It helps a lot to have decent classes to fill in the gaps. (If you're in Silicon Valley, or the L.A. area, I can recommend a group that gives informative classes, without hard sell or hype. Selling is strictly segregated from educating. The education tells you why and how and gives you an opportunity to talk to other people who are going through the same thing.)

This book primarily covers investor psychology and how to approach the process of evaluating, buying, and managing investments. Kiyosaki wants to convince people to have a long term view of their financial holdings, to evaluate potential investments for their effects on your cash flow, and to focus on investments that add to your net worth. The first half of the book concentrates on who you have to become in order to be a successful investor. Each chapter ends with a "Mental Aptitude Quizzes" to help you figure out whether you're serious, calm, patient, etc. enough to succeed at investing. The argument is that many people aren't temperamentally suited to being high-stakes investors, and they'd be better off trying something else.

Kiyosaki's main story about growing as an investor is that you need to start with a solid financial foundation so you can afford to take some risks, then you can either grow a portfolio slowly over time, or you can invest your effort into building a business on your own. The latter route provides many tax advantages while building the business, and gives more control over your life and the kinds of projects you invest in. He strongly emphasizes the value of building your own business (even a franchise business) both for the experience in what it takes to make a business succeed, and for the tax advantages. He overemphasizes the chances of building a successful business; he may be right that it's worth it for the experience.

One of his messages is that the safe way to build wealth is to "find a plan that works, and stick with it." Unfortunately, he repeats this mantra without explaining how to pick a good plan or how to tell whether your plan is working. There's a three-page section in Chapter 8 that talks about how to evaluate results, but I doubt that many readers will get it. It's not enough to have a plan and stick to it. You might be lucky enough to pick the right plan, or you might not. What you need first is a method for evaluating plans and their results. Then you can search for good plans, and experiment with them until you find one that works in practice for you.

Another message that is repeated many times is that employees are at someone else's mercy, while people who build successful businesses are in control of their fate. He pounds on this point to convince readers that being an employee isn't a path to wealth or security as most of our parents were taught. Aspiring investors need to be aware that getting loans is the most common path to buying real estate, and lenders like to see stable income. A failing business or intermittent consulting doesn't inspire their confidence. Once you have an investment portfolio, you can go to other sources for leverage, but when starting out, it's quite valuable to continue working the day job.

Different kinds of investors ( accredited, qualified, sophisticated, inside, ultimate) have different opportunities available to them. Moving into a new category requires learning the skills to evaluate the opportunities or gaining the resources to handle setbacks. Investing outside of the categories you are suited for is sometimes illegal, and usually (financially) dangerous. The tax treatment of income is different depending on whether it is from employee, self-employed, Business owner, or Investor. Sophisticated investors understand the tax treatment of each, and use each category when it is advantageous.

In the first chapter, Kiyosaki talks about the abilities of different kinds of investors:

There are many more bad deals than good deals. If a person is not aware, all deals--good and bad--look the same. It takes a great deal of education and experience to sort the more sophisticated investments into good and bad investments.

Reading this book is a small step in learning to distinguish good from bad. If you haven't decided that getting wealthy is worth the effort, you may not get much out of this book. If you have, there are important insights available here.

Wednesday, January 10, 2007

Integrating Book Orders and Market Makers

Dave Pennock gave a gentle introduction to the Market Scoring Rule invented by Robin Hanson. In the comments, Sid asked for an explanation of how to integrate the MSR with an order book. Dave asked me privately if I'd be willing to tackle that, and this post is the result.

Robin's short note on integrating an order book and a market maker covers a lot of territory very quickly. In Robin's defense, it was written to clarify some ideas in the midst of a conversation we were having at the time, and hasn't been cleaned up for publication. I'll expand on it here so it has a chance of making sense to others. The paper couches things in terms of the MSR, a particular AMM, but none of the implementation depends on which AMM is used.

There's a working example of the integration we're talking about in the code for Zocalo. The code that does this is currently in transition since I'm adding support for multi-outcome markets. For the moment, I recommend reading the code for version 375, since the current code is more complex and possibly incomplete. You can either download the complete source code for release 2006.5 of the Zocalo Prediction Market, or browse the code directly using the SVN interface.

The paper starts by giving a very compressed introduction to the idea of a prediction market and market maker (hereafter AMM for Automated Market Maker). Unless you're very familiar with the details and the formalisms that Robin uses to describe them, you'd be better off reading the original papers (Logarithmic Market Scoring Rules, Combinatorial Information Market Design) than trying to pick anything up from the first four paragraphs of the note.

The fourth paragraph slips into the idea of integrating an order book with the AMM he's talked about to that point. ("If instead [the AMM price resulting from buying the entire quantity is higher than the user's max marginal price], a portion [...] could be traded with the market maker, leaving a book order for the remaining quantity"). From that point, he talks about how to integrate the two markets.

If new orders get the advantage of any order price overlap

In book order systems, if orders arrive asynchronously, you will often see orders that "overlap", i.e. orders to buy at a higher price than the best offer to sell, or orders to sell lower than the best offer to buy. The system has to have policy about what price to transact at in these cases. The system could tell each party that they got the price they requested, and pocket the difference; it could use the book order's price or the new offer's price; or it could split the difference in the interest of fairness. If any choice is made other than using the stated price of the order in the book, investors have an incentive to carefully submit bids a little at a time (aka "structure" their bids) so they won't pay more than they have to if new orders should arrive. Robin argued elsewhere (I can't find the reference at the moment) that you should just transact at the book order price so that people submitting market price orders don't waste their resources and yours on this optimization.

That choice also simplifies the calculation for accepting new offers. As Robin says, "each book order [...] imposes a constraint on the market maker price". The AMM should fulfill orders up to that limit, then let trade continue with the book order. This requires a loop, in which you buy from the AMM until you reach the limit imposed by the best order(s), then trade up to the book order's available quantity, then go back to the AMM until you reach the next book order. You can see the approach in Zocalo's method Market.buyFromBothBookAndMaker(...). (The method starts at line 237.)

At every step,

  • find the remaining quantity q of the new order
  • find the price p available from the best existing order
  • if the AMM's price is no better than the book order, trade up to q with the book
  • otherwise trade with the AMM to the lesser of p or q

The loop stops either when the new order is fulfilled or the price limit specified by the new order is reached.

That's the simple version for a one-dimensional AMM. The multi-dimensional version arises if you implement the AMM as described in "Combinatorial Information Market Design". There are two open source implementations of this approach available for reading by hard-core hackers. Robin built an implementation in Lisp, and I wrote a version in E. Neither is more than a demonstration of how the market engine works, since no serious user interface was written for either one.

Rather than attempt to explain how the approach translates to the multi-dimensional case now, I'd prefer to wait until after I write an explanation of the n-dimensional combination market, and that depends on a gentle introduction to conditional and combinatorial betting which I haven't written yet. Having someone ask about Robin's note raises my priority for writing these prerequisites.

Addendum: other explanatory articles I've written: