FindDistributionParameters and Test Options

This is very much related to my earlier post FindDistributionParameters and Hypothesis Testing. However, I did not get a satisfactory anaswer and it keeps bugging me. I am trying to get help this time with an easier example.

I generate some data:

data = RandomVariate[WeibullDistribution[1.80631, 421.258],1000];

When I run the following code:

FindDistributionParameters[data, WeibullDistribution[a, b],
ParameterEstimator -> “MethodOfMoments”]

I get values of aa and bb. I want to test whether a=1a = 1 in fitting the data to the Weibull distribution. Can anybody help me please?

=================

  

 

You could perform a parametric bootstrap as explained here and check whether or not the confidence interval around a includes 1.
– Sjoerd C. de Vries
Jun 7 ’15 at 21:57

  

 

@Sjoerd Thank you for your suggestion.
– ramesh
Jun 7 ’15 at 22:14

  

 

How about DistributionFitTest[data, WeibullDistribution[1, b]] ?
– Stefan R
Jun 9 ’15 at 22:24

=================

1 Answer
1

=================

You specifically use the method of moments, is that meant to be a real problem constraint?

If you can instead use the maximum likelihood estimate for {a,b} then you can you perform a straightforward likelihood ratio (LR) test. In the following quick check, the LR test statistic is approximately Chi-Square distributed (see Wilk’s theorem), so you can accept the null hypothesis that a=1 unless the test statistic exceeds InverseCDF[ChiSquareDistribution[1], 1 – \[Alpha]].

(* Null hypothesis, b is a nuisance parameter *)
H[0] = WeibullDistribution[1, b];

(* Alternative hypothesis, which has one more degree of freedom. *)
H[1] = WeibullDistribution[a, b];

(* Check the distribution of the LR test statistic *)
sampleSize = 100;
lrTestStatistic = Table[
data = RandomVariate[WeibullDistribution[1, 421.258], 1000];
sol[0] = FindDistributionParameters[data, H[0]];
sol[1] = FindDistributionParameters[data, H[1]];
-2 (LogLikelihood[H[0]/.sol[0], data] – LogLikelihood[H[1]/.sol[1], data]),
{sampleSize}
];

(* by the eyeball test, I’d say we’ve met the assumptions for Wilk’s theorem to hold *)
\[Alpha] = 0.05;
Plot[{
CDF[EmpiricalDistribution[lrTestStatistic], x],
CDF[ChiSquareDistribution[1], x]},
{x, 0, 2 InverseCDF[ChiSquareDistribution[1], 1 – \[Alpha]]}
]

  

 

Thank you Ian for your answer. MM is not my prefer method of estimation. It could be ML too. I think this helps me. Thank you.
– ramesh
Jun 8 ’15 at 2:43