4
$\begingroup$

I have total tickets sold data from a single movie theater at a daily level. Its 2 years daily data for every single show date. I did Anderson-Darling test using ad.test() in nortest package in R and it results came significant which means this is not normal distribution as per this tutorial. Is it binomial by any chance? Or what is it?

This is QQplot enter image description here

This is density plot enter image description here

This is a simple plot of data using qplot function from ggplot package in R enter image description here

Can anyone suggest what distribution this variable has? To a naked eye, second and third plot looks like a right skewed/right tailed distribution. I want to use this for regression and want to be sure of the distribution so that i can proceed further.

Edit: I found an R package fitdistrplus and used fitdist() to test different distributions. Below is how qqplot looks like in each distribution and below are aic values

enter image description here

library(fitdistrplus)
#gamma distribution
fit.fg <- fitdist(data$Tot_ticket_sold, "gamma")
#log normal
fit.fln <- fitdist(data$Tot_ticket_sold, "lnorm")
#weibull
fit.fw <- fitdist(data$Tot_ticket_sold, "weibull")
#normal
fit.fn <- fitdist(data$Tot_ticket_sold, "norm")

check qqplot and emperical and theoritical density to see what fits best

plot(fit.fg)
plot(fit.fln)
plot(fit.fw)
plot(fit.fn)

find lowest aic

> fit.fg$aic
[1] 656590.6
> fit.fln$aic
[1] 664127.3
> fit.fw$aic
[1] 656753.2
> fit.fn$aic
[1] 691545.8

It looks like a gamma distribution.

$\endgroup$
8
  • 2
    $\begingroup$ Gamma and log normal are very similar distributions. There is a great post on CV by Glen_b. $\endgroup$ Commented Sep 14, 2016 at 5:32
  • 1
    $\begingroup$ Here $\endgroup$ Commented Sep 14, 2016 at 5:35
  • $\begingroup$ Excellent work (I just had my phone last time we talked...). Can you share the estimated parameters if we were to assume a log-normal? $\endgroup$ Commented Sep 14, 2016 at 13:35
  • 2
    $\begingroup$ If this is count data we know it can't actually be gamma or lognormal or any other continuous distribution. If it has low minimum counts (especially if you can observe 0's or even 1's), I'd avoid continuous approximations. 1. What's wrong with discrete distributions as models for discrete data? 2. Why do you need a simple-functional form as a distributional model at all? $\endgroup$
    – Glen_b
    Commented Sep 15, 2016 at 7:57
  • $\begingroup$ Hi @Glen_b, is there any test to identify the data is discrete or not. Also, it if it is indeed discrete, what modelling approach can i take? i assume an glm model? Please suggest. $\endgroup$ Commented Sep 19, 2016 at 6:47

2 Answers 2

6
$\begingroup$

Check the log-normal distribution. I have some notes on it here.

It's count data, so it doesn't go below zero, and has a positive skew because every once in a while a blockbuster movie attracts multitudes to the movies. Normally, though, (pun intended), it has a bell-ish shape. This seems in line with the multiplicative process that may explain bacterial or cell counts (Problems with Using the Normal Distribution – and Ways to Improve Quality and Efficiency of Data Analysis Eckhard Limpert, Werner A. Stahel in PLoS ONE, July 2011, vol.6, Issue 7.). I wonder if your tickets can be compared to ducks...

Can you take logs and run your QQ plot again?

$\endgroup$
4
  • $\begingroup$ Thanks! i added a bit more detail and possibly the solution as well. $\endgroup$ Commented Sep 14, 2016 at 5:25
  • $\begingroup$ and i have the plot of log-normal qqplot as well. $\endgroup$ Commented Sep 18, 2016 at 10:12
  • $\begingroup$ for count data use Poisson distribution $\endgroup$
    – JeeyCi
    Commented Oct 2 at 8:10
  • $\begingroup$ ... or Negative Binomial for overdispersed Poisson $\endgroup$
    – JeeyCi
    Commented Oct 2 at 11:16
0
$\begingroup$

A Q-Q plot is a great way to determine whether residuals from regression analysis are normally distributed.

here can see that (sometimes):

the normality test is statistically significant, indicating the data don’t follow the normal distribution. However, the QQ plot shows that they do. The sample size is 5000, giving the test the power to detect trivial departures from the normal distribution.

..., you’d conclude that your data are normally distributed. This is a rare case where statisticians will trust graphical results more than the hypothesis test!

concerning your Q-Q plot taking into consideration this table of distributions' Q-Q plots you can conclude that you're having bimodal distribution. But better make conclusion from the domain knowledge of your data: right-skewed data have positive skew (Mean > Median> Mode) - your plot can be described as Light-tailed truncnorm as well. I think, increasing sample size for sufficient statistics you could be able to get enough p-value not to reject H0: "The sample data follow the hypothesized distribution", where you test Poisson distribution. Because as I already mentioned in comments for count-data Poisson (or Negative Binomial for overdispersed Poisson) distributions are used

p.s. pdf for real data or fitting different distributions

$\endgroup$
3
  • $\begingroup$ That quotation is so contradictory (and wrong) as to call into question your entire answer. $\endgroup$
    – whuber
    Commented Oct 2 at 16:37
  • $\begingroup$ quotation is the author's observations by reference given in link - better see full example given by link, - I just marked author's conclusion. In addition, I wrote my own viewpoint as fully as I consider it to be... $\endgroup$
    – JeeyCi
    Commented Oct 2 at 17:38
  • $\begingroup$ ... for clarity edited with the word sometimes - as per reference's observation $\endgroup$
    – JeeyCi
    Commented Oct 2 at 17:42

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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