# Finding the Best Fitting Parameters using Optimisation The cumulative distribution function for a Rayleigh distribution F(x) is:

where b is the distribution's parameter.

The links to the Rayleigh Fit software specific models are provided here: Rayleigh_fit

Here is a screenshot of the model: The Solver feature in Excel is set to find the minimum value for the sum of the absolute differences between the observed and Rayleigh F(x)s by changing the value of b. The Solver solution for b is 4.51195, corresponding to the fit shown in the chart. This technique is very flexible in that it allows one to define one's own measure of goodness of fit. In this example, we have simply taken the sum of absolute differences between the observed and fitted cumulative distribution functions, but we could have weighted the differences at the tails if we were concerned about the tail accuracy more than the body of the distribution. We could also have maximized a likelihood calculation to obtain MLEs. The example given here is also rather simple in that the Rayleigh distribution is defined by the one parameter. Many distributions have two or more parameters, but if one is careful in putting constraints on the parameter ranges to be tested, Solver will usually handle at least two parameters well. More sophisticated non-linear optimisers could be considered for more complicated problems. Rayleigh_fit

Here is a screenshot of the model: The Solver feature in Excel is set to find the minimum value for the sum of the absolute differences between the observed and Rayleigh F(x)s by changing the value of b. The Solver solution for b is 4.51195, corresponding to the fit shown in the chart. This technique is very flexible in that it allows one to define one's own measure of goodness of fit. In this example, we have simply taken the sum of absolute differences between the observed and fitted cumulative distribution functions, but we could have weighted the differences at the tails if we were concerned about the tail accuracy more than the body of the distribution. We could also have maximized a likelihood calculation to obtain MLEs. The example given here is also rather simple in that the Rayleigh distribution is defined by the one parameter. Many distributions have two or more parameters, but if one is careful in putting constraints on the parameter ranges to be tested, Solver will usually handle at least two parameters well. More sophisticated non-linear optimisers could be considered for more complicated problems.

• No labels