## Posts tagged ‘regression’

### Hold On… How Many Copies?

How many copies of Math Jokes 4 Mathy Folks do you think sold last week?

Why would you want to make a prediction? Well, lots of reasons…

• Like the author (and readers) of this blog, you’re a math geek.
• You swoon at the sight of data.
• You’ve never met a puzzle you didn’t like.
• You want to show the world how awesome you are.
• You’d like to win a signed copy of Math Jokes 4 Mathy Folks, some cool MJ4MF stickers, and a surprise gift, all shipped to you in exclusive MJ4MF packaging!
• All of the above.

If you’re reading this blog, then you surely love being alive in the Age of Big Data. I love it, too, and I devour any data that I can get my hands on.

Amazon feeds my desire by providing two valuable pieces of data about Math Jokes 4 Mathy Folks. First, they provide the sales rank for the book, which is updated hourly. Second, they provide weekly sales data. The downside to this latter stat is the delay in its release — they provide data for Monday-Sunday, but it isn’t released until the following Friday. The upside is that big dorks like me use the time from Monday through Thursday to make predictions.

The chart below shows the average sales rank and weekly sales for Nov 24 through Dec 14. (The “average sales rank” is the average of the sales ranks for the seven days each week. Although it’s updated hourly, I don’t have the time to check it that frequently, so I rely on Author Central, which reports the sales rank at the end of each day.) It also shows the average sales rank (but not sales) for last week, Dec 15‑21.

 Week Amazon Sales Rank (Weekly Average) Weekly Sales Nov 24-30 4,742 114 Dec 1-7 3,437 279 Dec 8-14 2,390 435 Dec 15-21 2,063 ?

The question: How many copies of MJ4MF were sold last week?

Oh, sure… I could just wait until Friday to find out — but what fun would that be?

Instead, I constructed several mathematical models, and then I tweaked them to predict how many books were sold. The tweaks were based on some things I’ve learned over the past couple of years:

• Holiday sales are most vigorous in the first two weeks of December. They slow down a bit in the third week. Consequently, a sales rank of 1,655 on Dec 1 does not equal a sales rank of 1,655 on Dec 21.
• The long-term trend is not linear. In fact, this graph from Foner Books shows that it’s logarithmic.

Which brings us to the contest. Go to the Google form and enter your prediction and email address. (The email is only so I can contact you if you win.) Closest guess to the actual number of sales will win the grand prize. In the event of a tie, a winner will be randomly selected (or if I’m feeling generous, maybe there will be multiple winners… it’s hard to predict my disposition on any given day).

So, what are you waiting for? Open Excel or SPSS or your stat software of choice, muddle through a few regressions, and submit your entry!

Winners will be announced on Saturday, December 27, 2014. The exact time will depend on what time I roll out of bed, what activities my wife and kids propose for the day, and my particular disposition on Saturday. On second thought… safest if you check back on Sunday.

Good luck!

### Amazon Sales Rank, and What Math Geeks Do

Today, I asked my son’s if they would like to buy The Oatmeal’s Why Grizzly Bears Should Wear Underpants. They laughed uproariously at the title, and then Eli asked, “Is that the #1 book on Amazon?” In fact, it’s not. At the time of this writing, its ranking was #624. “That’s not #1,” Alex affirmed, then added, “but it’s a lot better than your book.”

Ha-rumph.

“A lot better” is highly subjective. Sure enough, the #3,517 ranking of Math Jokes 4 Mathy Folks has an absolute difference of 2,893 compared to WGBSWU; or, if you’re into ratios, the rank of my book is five times as much as the rank of WGBSWU. But what does that really mean?

In practical terms, it means that the number of copies of WGBSWU that will sell on Amazon this week is approximately six times the number of copies of MJ4MF that will sell during the same period. If my calculations are correct, that is. No one is really sure how ranking translates to sales, but I estimate that approximately 250 copies of MJ4MF and 1,500 copies of WGBSWU will sell this week.

This is what math geeks do: We try to understand everything quantitatively.

I took weekly sales data for MJ4MF and compared that with the book’s average ranking for the week. I randomly chose 20 weeks in 2012-13 for this analysis, because while pulling weekly sales data is relatively easy — it’s provided at Amazon Author Central — determining weekly average ranking is more difficult, since data has to be pulled day by day. And it’s not as simple as just exporting the data to Excel or a CSV file… the data is provided in a graph, and if you want to manipulate that data in any way, you have to look at each point on the graph, determine its value, and then enter it manually. Ugh.

The graph below shows the relationship between average rank and weekly sales:

The regression equation S = 914.77 × R-0.977 gives a reasonably good fit (r = 0.89). What’s interesting is that this formula is less accurate in November and December than during the rest of year. There are two reasons for that. First, sales increase dramatically during the holiday shopping season. Second, such a formula is bound to be less accurate with larger numbers.

The average rank for December 9-15 was #3,592, and using the formula above, approximately 253 copies of MJ4MF should have sold. (I suspect that estimate is a little low. For the same week last year, the average rank was #4,573 and 277 copies were sold.)

Amazon posts sales data for each week on the following Friday. Sales data for last week won’t post until December 20. I’ll update this post on Friday and let you know how well I did.

[Update, 12/20/13: A record-breaking 335 copies of MJ4MF sold December 9-15. (Thank you!) But as predicted, the estimate was indeed low. As I gather more data, perhaps I will be able to create a better model.]

The Math Jokes 4 Mathy Folks blog is an online extension to the book Math Jokes 4 Mathy Folks. The blog contains jokes submitted by readers, new jokes discovered by the author, details about speaking appearances and workshops, and other random bits of information that might be interesting to the strange folks who like math jokes.

## MJ4MF (offline version)

Math Jokes 4 Mathy Folks is available from Amazon, Borders, Barnes & Noble, NCTM, Robert D. Reed Publishers, and other purveyors of exceptional literature.