2
$\begingroup$

I have a data set and I would like to fit a t distribution on it. I use R or Python to feed into my data, and I get the degrees of freedom, the location and the scale parameters.

After that, I generated random t distributed numbers with the parameters I got from my data set. Then I compared these random numbers with the original data using the Kolmogorov Smirnov and the Anderson-Darling tests. Both rejected the Null hypothesis.

I would like to know why this happens and what could I do about it?

$\endgroup$
6
  • 1
    $\begingroup$ Does it happen with any sample you generate or only sometimes? How often it does happen? $\endgroup$
    – Aksakal
    Oct 5, 2018 at 14:06
  • $\begingroup$ It happens with every sample. $\endgroup$
    – Alquil
    Oct 5, 2018 at 14:11
  • $\begingroup$ You might try my online open source Python statistical distribution fitter and see if it can suggest a scipy continuous distribution to consider, the link is zunzun.com/StatisticalDistributions/1 with source code links at the bottom of the web page. $\endgroup$ Oct 5, 2018 at 18:41
  • $\begingroup$ How large is the sample? $\endgroup$ Oct 8, 2018 at 1:47
  • $\begingroup$ @SecretAgentMan It has almost 2000 observations $\endgroup$
    – Alquil
    Oct 8, 2018 at 7:19

1 Answer 1

4
$\begingroup$

This seems to suggest that your original data is not, in fact, t-distributed. You could fit a t-distribution to literally any data set, that doesn't mean it will describe your data well. The fact that your tests reject the null hypothesis shows that there is a mismatch between the distribution of your data and your fitted t-distributed samples.

Maybe try to fit a different distribution to your data, since it is significantly different from t-distributed.

$\endgroup$

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.