I work with for a retail company. A recurring problem in our meetings is that our mid-level managers usually blame weather for the sales development. I want to find out if this is right or wrong.

My plan is to create a regression analysis and find out the coefficient of determination (R-squared).

Input so far:

  • Sales per day
  • mm of rain per day
  • hours of sun per day
  • average temperature per day


  1. Is it better to use the actual numbers or should I code the rain, sun and temperature to something, say 0 or 1?
  2. What method would be the best approach to tackle this?

We have business all over the world, but I'm first going to try it in a specific city. I plan to use Excel, could also use statistical software.


The most important factors in sales are typically promotions, price changes and markdowns, followed by seasonality (intra-yearly and intra-weekly) or lifecycles, depending on what you sell. (Grocery has yearly seasonality, fashion and consumer electronics have lifecycle effects.)

I would thus recommend that you account for these effects first. For instance, you could use Fourier terms to account for seasonality, with day-of-week dummies to account for the fact that retail sales are typically higher on Saturday than on other days of the week. Include prices, price changes and promotions as regressors. You may want to model the residuals using an ARIMA model or similar. Finding a good model for these main drivers can certainly be a whole project all by itself.

Then, and only then, you are ready to investigate how much explanatory power weather has on top of all these effects, since your managers presumably know about promotions and seasonality and should not be surprised by them. So you could take the residuals from the above model and regress those on your weather information. (You could also run one big model that includes all covariates simultaneously, and then test the nested models.)

I'd recommend that you include your weather information either as-is, or spline-transformed. Splitting, e.g., temperature information into "hot" vs. "not hot" models the effect that sales change abruptly above some specific temperature threshold, and that simply does not happen. Dichotomizing continuous predictors is almost always a bad idea. You can read a lot about this here on CV by searching. Conversely, you could have nonlinear effects of temperature, which you could capture, e.g., by spline transformations.

You could probably do a lot of this in Excel, but something like R will be far better.

| cite | improve this answer | |
  • $\begingroup$ Thanks a lot Stephan - It helped me greatly, I will look further into this and see if I can establish something by what you explain and then include weather into it lastly. $\endgroup$ – Robin Wiman Jun 3 '16 at 13:52

Not a stats answer but an observation related to sales-weather correlation

I read this: http://www.thisismoney.co.uk/money/news/article-2540499/ONS-There-no-correlation-weather-high-street-sales.html which says:

  • Don't blame it on the weatherman: There is no connection between weather and high street sales, official figures reveal
  • ONS claims there is 'no clear relationship between the two'
  • Analysts argue that while overall sales could stay the same, some categories will rise and fall depending on the weather

Typically, as I am searching on how to correlate weather with retail trends, what I see is that blogs mention how they can use forecasting to stock and rotate weather-sensitive data like telling their customers to be prepared for a incoming heatwave by buying this and that etc... So I guess, the sales is indirectly related?

| cite | improve this answer | |
  • 1
    $\begingroup$ This is very interesting. I will dig deeper in this topic and look at the article, thanks! :) $\endgroup$ – Robin Wiman Sep 19 '18 at 11:54
  • $\begingroup$ @RobinWiman your welcome :) $\endgroup$ – harshvchawla Sep 20 '18 at 12:25

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.