Saturday, 19 May 2007

The OCaml revolution

The man behind the O'Reilly book publishers, Tim O'Reilly, recently released a series of articles analysing book sales in the programming industry and, in particular, devoted one article to breakdown by programming language.

OCaml can be seen right at the bottom under the heading "Irrelevant Programming Languages". The interesting thing from our point of view is that these statistics do not include sales of our book OCaml for Scientists, which introduces professionals in science and engineering to the OCaml programming language as a high-performance tool to help them with their research.

Naturally, by diregarding profits and more prolific publications like magazines, O'Reilly's article shows O'Reilly topping the charts in terms of units sold. Although selling many units is nice, particularly for advertising, most industries are more concerned with profits. To estimate profits it is necessary to take the cost of the book into account. This changes the results drastically and, in particular, penalises O'Reilly for publishing very cheap books.

Several amazing results come from such an analysis. Firstly, Flying Frog Consultancy have long wondered how we could boost sales and compete with mainstream publishers. From these statistics, it seems that we have been beating the mainstream publishers at their own game for some time.
We even outsold Practical OCaml in Q1 2007 in terms of units sold!

Secondly, we had been wondering if OCaml is a comparatively profitable market to enter. According to these statistics, OCaml is one of the most profitable languages to choose, beating Lisp, Scheme, Haskell and even C/C++ and Python.

Thirdly, dissecting the results by profit indicates that OCaml for Scientists is in the top 5% of the world's favorite programming books. This is probably due to the fact that OCaml for Scientists received universally fantastic reviews.

Finally, the growth of the market determines whether or not we can stay. The OCaml market has shown the second largest growth of any programming language, topped only by Ruby. We have felt this ourselves, as sales of our OCaml-related products have quadrupled over the past year and continue to rise.

Overall, we are very happy with the result. So happy that we will write a very cheap introductory book on OCaml and publish it through a mainstream publisher as well as release a second edition of our best-selling book OCaml for Scientists.

We predict that the F# programming language from Microsoft Research (which is derived from OCaml) will explode in popularity over the next year, starting with the publication of Foundations of F# by Robert Pickering later this month, then Expert F# and our own F# for Scientists.

5 comments:

rubyfan said...

You could sell a lot more copies of "OCaml for Scientists" if it didn't cost $160 USD.

I'd buy one at $50 USD, but my wife won't let me by computer books that are over $100 ;-)

Also: is F# going to end up splitting the OCaml community and booksales?

Jon Harrop said...

You are quite correct that we would sell more copies if it were cheaper. However, we would make less profit. Manufacture and distribution cost us around $50 per book.

We used to be concerned about splitting small communities and competing in small markets but, from experience, this is actually completely unjustified. Publication of the book Practical OCaml greatly increased the sales of our book OCaml for Scientists.

So we now believe that any growth in functional programming is good for all of us. Books on all functional languages are good for us.

Also, it is worth noting that OCaml is natively Linux and F# is natively Windows. Consequently, we shall angle our F# work to the OCaml community as a path that allows them to commercialize their OCaml code and skills.

rubyfan said...

Manufacture and distribution cost us around $50 per book.

This is primarily because you've self-published, correct?

I suspect you could get these costs down significantly. Have you talked to the Pragmatic Programmers about the possibility of them publishing it? I suspect they would be very happy to have an OCaml title. And I know they are able to sell books like yours in the $40 range - they just came out with a Programming Erlang book.

I'd really like to purchase your book, but as things are now the cost is prohibitive. (of course, some of this is caused by the $/Pound exchange rate - another way the Pragmatic Programmers could help you).

Jon Harrop said...

If the book was smaller, black and white and printed/shipped in bulk then the manufacturing costs could be reduced, yes.

We are certainly considering writing a new book, a small and cheap introduction to OCaml for the masses, and we shall consider Pragmatic Programmers as a publishing house. Thank you.

Lloyd said...

Although I am not one who tends to spend an awful lot of money on a book, I have to say that purchasing Ocaml for scientists ( and I have to also mention Artificial Intelligence Programming by the great Peter Norvig) was one of the smartest moves I ever made.

Agreed, it (they) isn't (are) the cheapest of books, but then again you do get what you pay for, and in this case a whole lot more.

After months of seeing people being slated for telling the world about their work, including Dr Jon Harrop and Rob Pickering for starters, I cannot help but wonder at the power of petty minded jealousy.

That's some fantastic advise there, "rubyfan", although I don't think that the restriction laid down by your wife is grounds to drop the price of a book.

My girlfriend won't let me buy a new computer because the model I want is quite expensive - maybe I should speak to the shop owner and explain my position.