Block Maxima Model

The stationary BlockMaxima model is illustrated using the annual maximum sea-levels recorded at Port Pirie in South Australia from 1923 to 1987, studied by Coles (2001) in Chapter 3. The annual maxima are assumed independent and identically distributed.

The Extremes.jl package supports maximum likelihood inference, Bayesian inference and inference based on the probability weigthed moments. For the GEV parameter estimation, the following functions can be used:

  • gevfitpwm: estimation with the probability weighted moments;
  • gevfit: maximum likelihood estimation;
  • gevfitbayes: Bayesian estimation.
Log-scale paremeter

These functions shows the estimate of the log-scale parameter $\phi = \log \sigma$ instead of the scale parameter.

Load the data

Loading the annual maximum sea-levels at Port Pirie:

data = Extremes.dataset("portpirie")
first(data,5)
5×2 DataFrame
RowYearSeaLevel
Int64Float64
119234.03
219243.83
319253.65
419263.88
519274.01

The annual maxima can be shown as a function of the year using the Gadfly package:

set_default_plot_size(12cm, 8cm)
plot(data, x=:Year, y=:SeaLevel, Geom.line)
Year 1920 1940 1960 1980 2000 1920 1925 1930 1935 1940 1945 1950 1955 1960 1965 1970 1975 1980 1985 1990 1995 2000 1920.0 1920.5 1921.0 1921.5 1922.0 1922.5 1923.0 1923.5 1924.0 1924.5 1925.0 1925.5 1926.0 1926.5 1927.0 1927.5 1928.0 1928.5 1929.0 1929.5 1930.0 1930.5 1931.0 1931.5 1932.0 1932.5 1933.0 1933.5 1934.0 1934.5 1935.0 1935.5 1936.0 1936.5 1937.0 1937.5 1938.0 1938.5 1939.0 1939.5 1940.0 1940.5 1941.0 1941.5 1942.0 1942.5 1943.0 1943.5 1944.0 1944.5 1945.0 1945.5 1946.0 1946.5 1947.0 1947.5 1948.0 1948.5 1949.0 1949.5 1950.0 1950.5 1951.0 1951.5 1952.0 1952.5 1953.0 1953.5 1954.0 1954.5 1955.0 1955.5 1956.0 1956.5 1957.0 1957.5 1958.0 1958.5 1959.0 1959.5 1960.0 1960.5 1961.0 1961.5 1962.0 1962.5 1963.0 1963.5 1964.0 1964.5 1965.0 1965.5 1966.0 1966.5 1967.0 1967.5 1968.0 1968.5 1969.0 1969.5 1970.0 1970.5 1971.0 1971.5 1972.0 1972.5 1973.0 1973.5 1974.0 1974.5 1975.0 1975.5 1976.0 1976.5 1977.0 1977.5 1978.0 1978.5 1979.0 1979.5 1980.0 1980.5 1981.0 1981.5 1982.0 1982.5 1983.0 1983.5 1984.0 1984.5 1985.0 1985.5 1986.0 1986.5 1987.0 1987.5 1988.0 1988.5 1989.0 1989.5 1990.0 1990.5 1991.0 1991.5 1992.0 1992.5 1993.0 1993.5 1994.0 1994.5 1995.0 1995.5 1996.0 1996.5 1997.0 1997.5 1998.0 1998.5 1999.0 1999.5 2000.0 1900 2000 h,j,k,l,arrows,drag to pan i,o,+,-,scroll,shift-drag to zoom r,dbl-click to reset c for coordinates ? for help ? 3.5 4.0 4.5 5.0 3.5 3.6 3.7 3.8 3.9 4.0 4.1 4.2 4.3 4.4 4.5 4.6 4.7 4.8 4.9 5.0 3.500 3.505 3.510 3.515 3.520 3.525 3.530 3.535 3.540 3.545 3.550 3.555 3.560 3.565 3.570 3.575 3.580 3.585 3.590 3.595 3.600 3.605 3.610 3.615 3.620 3.625 3.630 3.635 3.640 3.645 3.650 3.655 3.660 3.665 3.670 3.675 3.680 3.685 3.690 3.695 3.700 3.705 3.710 3.715 3.720 3.725 3.730 3.735 3.740 3.745 3.750 3.755 3.760 3.765 3.770 3.775 3.780 3.785 3.790 3.795 3.800 3.805 3.810 3.815 3.820 3.825 3.830 3.835 3.840 3.845 3.850 3.855 3.860 3.865 3.870 3.875 3.880 3.885 3.890 3.895 3.900 3.905 3.910 3.915 3.920 3.925 3.930 3.935 3.940 3.945 3.950 3.955 3.960 3.965 3.970 3.975 3.980 3.985 3.990 3.995 4.000 4.005 4.010 4.015 4.020 4.025 4.030 4.035 4.040 4.045 4.050 4.055 4.060 4.065 4.070 4.075 4.080 4.085 4.090 4.095 4.100 4.105 4.110 4.115 4.120 4.125 4.130 4.135 4.140 4.145 4.150 4.155 4.160 4.165 4.170 4.175 4.180 4.185 4.190 4.195 4.200 4.205 4.210 4.215 4.220 4.225 4.230 4.235 4.240 4.245 4.250 4.255 4.260 4.265 4.270 4.275 4.280 4.285 4.290 4.295 4.300 4.305 4.310 4.315 4.320 4.325 4.330 4.335 4.340 4.345 4.350 4.355 4.360 4.365 4.370 4.375 4.380 4.385 4.390 4.395 4.400 4.405 4.410 4.415 4.420 4.425 4.430 4.435 4.440 4.445 4.450 4.455 4.460 4.465 4.470 4.475 4.480 4.485 4.490 4.495 4.500 4.505 4.510 4.515 4.520 4.525 4.530 4.535 4.540 4.545 4.550 4.555 4.560 4.565 4.570 4.575 4.580 4.585 4.590 4.595 4.600 4.605 4.610 4.615 4.620 4.625 4.630 4.635 4.640 4.645 4.650 4.655 4.660 4.665 4.670 4.675 4.680 4.685 4.690 4.695 4.700 4.705 4.710 4.715 4.720 4.725 4.730 4.735 4.740 4.745 4.750 4.755 4.760 4.765 4.770 4.775 4.780 4.785 4.790 4.795 4.800 4.805 4.810 4.815 4.820 4.825 4.830 4.835 4.840 4.845 4.850 4.855 4.860 4.865 4.870 4.875 4.880 4.885 4.890 4.895 4.900 4.905 4.910 4.915 4.920 4.925 4.930 4.935 4.940 4.945 4.950 4.955 4.960 4.965 4.970 4.975 4.980 4.985 4.990 4.995 5.000 3 4 5 SeaLevel

Maximum likelihood inference

GEV parameter estimation

The GEV parameter estimation with maximum likelihood is performed with the gevfit function:

julia> fm = gevfit(data, :SeaLevel)MaximumLikelihoodAbstractExtremeValueModel
model :
	BlockMaxima{GeneralizedExtremeValue}
	data :		Vector{Float64}[65]
	location :	μ ~ 1
	logscale :	ϕ ~ 1
	shape :		ξ ~ 1

θ̂  :	[3.874750223091266, -1.6192723640210762, -0.05010719929448139]
Note

In this example, the gevfit function is called using the data DataFrame structure as the first argument. The function can also be called using the vector of maxima as the first argument, e.g. gevfit(data[:,:SeaLevel]).

The vector of the parameter estimates (location scale and shape) can be extracted with the function params:

julia> params(fm)1-element Vector{Tuple{Float64, Float64, Float64}}:
 (3.874750223091266, 0.19804274969909974, -0.05010719929448139)

The location parameter with the function location:

julia> location(fm)1-element Vector{Float64}:
 3.874750223091266

The scale parameter with the function Extremes.scale:

julia> scale(fm)1-element Vector{Float64}:
 0.19804274969909974

The shape parameter with the function shape:

julia> shape(fm)1-element Vector{Float64}:
 -0.05010719929448139
Type-stable function

These functions return a unit dimension vector for the return level and a vector containing only one vector for the confidence interval. The reason is that the functions always return the same type in the stationary and non-stationary case. The functions are therefore type-stable allowing better performance of code execution.

The approximate covariance matrix of the parameter estimates can be obtained with the parametervar function:

julia> parametervar(fm)3×3 Matrix{Float64}:
  0.000780204   0.000995016  -0.0010741
  0.000995016   0.0104541    -0.00392576
 -0.0010741    -0.00392576    0.00965404

Confidence intervals for the parameters are obtained with the cint function:

julia> cint(fm)3-element Vector{Vector{Float64}}:
 [3.820004234825991, 3.929496211356541]
 [-1.819669858589598, -1.4188748694525544]
 [-0.24268345866324303, 0.14246906007428023]

For instance, the shape parameter 95% confidence interval is as follows:

julia> cint(fm)[3]2-element Vector{Float64}:
 -0.24268345866324303
  0.14246906007428023

Diagnostic plots

Several diagnostic plots for assessing the accuracy of the GEV model fitted to the Port Pirie data are can be shown with the diagnosticplots function:

set_default_plot_size(21cm ,16cm)
diagnosticplots(fm)
Return Period 100.0 100.5 101.0 101.5 102.0 100.0 100.1 100.2 100.3 100.4 100.5 100.6 100.7 100.8 100.9 101.0 101.1 101.2 101.3 101.4 101.5 101.6 101.7 101.8 101.9 102.0 100.00 100.01 100.02 100.03 100.04 100.05 100.06 100.07 100.08 100.09 100.10 100.11 100.12 100.13 100.14 100.15 100.16 100.17 100.18 100.19 100.20 100.21 100.22 100.23 100.24 100.25 100.26 100.27 100.28 100.29 100.30 100.31 100.32 100.33 100.34 100.35 100.36 100.37 100.38 100.39 100.40 100.41 100.42 100.43 100.44 100.45 100.46 100.47 100.48 100.49 100.50 100.51 100.52 100.53 100.54 100.55 100.56 100.57 100.58 100.59 100.60 100.61 100.62 100.63 100.64 100.65 100.66 100.67 100.68 100.69 100.70 100.71 100.72 100.73 100.74 100.75 100.76 100.77 100.78 100.79 100.80 100.81 100.82 100.83 100.84 100.85 100.86 100.87 100.88 100.89 100.90 100.91 100.92 100.93 100.94 100.95 100.96 100.97 100.98 100.99 101.00 101.01 101.02 101.03 101.04 101.05 101.06 101.07 101.08 101.09 101.10 101.11 101.12 101.13 101.14 101.15 101.16 101.17 101.18 101.19 101.20 101.21 101.22 101.23 101.24 101.25 101.26 101.27 101.28 101.29 101.30 101.31 101.32 101.33 101.34 101.35 101.36 101.37 101.38 101.39 101.40 101.41 101.42 101.43 101.44 101.45 101.46 101.47 101.48 101.49 101.50 101.51 101.52 101.53 101.54 101.55 101.56 101.57 101.58 101.59 101.60 101.61 101.62 101.63 101.64 101.65 101.66 101.67 101.68 101.69 101.70 101.71 101.72 101.73 101.74 101.75 101.76 101.77 101.78 101.79 101.80 101.81 101.82 101.83 101.84 101.85 101.86 101.87 101.88 101.89 101.90 101.91 101.92 101.93 101.94 101.95 101.96 101.97 101.98 101.99 102.00 100 102 1.8195439355418694.69 1.51851393987788774.55 1.34242268082220664.55 1.21748394421390674.37 1.12057393120584964.36 1.0413926851582254.33 0.97444589552761174.33 0.91645394854992514.25 0.86530142610254384.24 0.81954393554186884.24 0.77815125038364374.22 0.7403626894942444.21 0.70560058323503184.21 0.67341589986363064.18 0.64345267648618744.18 0.61542395288594394.11 0.58909501416359484.11 0.56427143043856264.11 0.54079033458903984.08 0.51851393987788754.08 0.497324640807949364.06 0.47712125471966244.06 0.457816099524275774.05 0.439332693830262634.03 0.421603926869831064.01 0.404570587571050744.01 0.38818017138288144.0 0.372385904199649453.98 0.35714593764291253.97 0.342422680822206173.96 0.328182241707595973.96 0.314393957221962673.96 0.30102999566398123.96 0.28806501849961353.94 0.27547589119159313.93 0.263241434774581453.91 0.251342211474873733.9 0.23976033892505863.9 0.22847932851536953.89 0.217483944213906273.88 0.20676007882213323.88 0.19629464514396823.88 0.186075479962282163.86 0.176091259055681183.86 0.166331421766524963.85 0.156786103860294573.85 0.147446077606151223.85 0.138302698166281463.85 0.129347855513354983.83 0.120573931205849893.8 0.111973759443932333.79 0.103540591907069563.78 0.095268065941079693.75 0.08715017571890023.75 0.079181246047624823.74 0.071355908535668273.73 0.06366907986937733.72 0.056115941978931413.71 0.0486919238997245363.71 0.041392685158225083.66 0.0342141005311016743.66 0.0271522460436147763.65 0.020203386088286993.63 0.0133639615579815023.62 0.0066305788990130763.57 h,j,k,l,arrows,drag to pan i,o,+,-,scroll,shift-drag to zoom r,dbl-click to reset c for coordinates ? for help ? 3.5 4.0 4.5 5.0 3.5 3.6 3.7 3.8 3.9 4.0 4.1 4.2 4.3 4.4 4.5 4.6 4.7 4.8 4.9 5.0 3.500 3.505 3.510 3.515 3.520 3.525 3.530 3.535 3.540 3.545 3.550 3.555 3.560 3.565 3.570 3.575 3.580 3.585 3.590 3.595 3.600 3.605 3.610 3.615 3.620 3.625 3.630 3.635 3.640 3.645 3.650 3.655 3.660 3.665 3.670 3.675 3.680 3.685 3.690 3.695 3.700 3.705 3.710 3.715 3.720 3.725 3.730 3.735 3.740 3.745 3.750 3.755 3.760 3.765 3.770 3.775 3.780 3.785 3.790 3.795 3.800 3.805 3.810 3.815 3.820 3.825 3.830 3.835 3.840 3.845 3.850 3.855 3.860 3.865 3.870 3.875 3.880 3.885 3.890 3.895 3.900 3.905 3.910 3.915 3.920 3.925 3.930 3.935 3.940 3.945 3.950 3.955 3.960 3.965 3.970 3.975 3.980 3.985 3.990 3.995 4.000 4.005 4.010 4.015 4.020 4.025 4.030 4.035 4.040 4.045 4.050 4.055 4.060 4.065 4.070 4.075 4.080 4.085 4.090 4.095 4.100 4.105 4.110 4.115 4.120 4.125 4.130 4.135 4.140 4.145 4.150 4.155 4.160 4.165 4.170 4.175 4.180 4.185 4.190 4.195 4.200 4.205 4.210 4.215 4.220 4.225 4.230 4.235 4.240 4.245 4.250 4.255 4.260 4.265 4.270 4.275 4.280 4.285 4.290 4.295 4.300 4.305 4.310 4.315 4.320 4.325 4.330 4.335 4.340 4.345 4.350 4.355 4.360 4.365 4.370 4.375 4.380 4.385 4.390 4.395 4.400 4.405 4.410 4.415 4.420 4.425 4.430 4.435 4.440 4.445 4.450 4.455 4.460 4.465 4.470 4.475 4.480 4.485 4.490 4.495 4.500 4.505 4.510 4.515 4.520 4.525 4.530 4.535 4.540 4.545 4.550 4.555 4.560 4.565 4.570 4.575 4.580 4.585 4.590 4.595 4.600 4.605 4.610 4.615 4.620 4.625 4.630 4.635 4.640 4.645 4.650 4.655 4.660 4.665 4.670 4.675 4.680 4.685 4.690 4.695 4.700 4.705 4.710 4.715 4.720 4.725 4.730 4.735 4.740 4.745 4.750 4.755 4.760 4.765 4.770 4.775 4.780 4.785 4.790 4.795 4.800 4.805 4.810 4.815 4.820 4.825 4.830 4.835 4.840 4.845 4.850 4.855 4.860 4.865 4.870 4.875 4.880 4.885 4.890 4.895 4.900 4.905 4.910 4.915 4.920 4.925 4.930 4.935 4.940 4.945 4.950 4.955 4.960 4.965 4.970 4.975 4.980 4.985 4.990 4.995 5.000 3 4 5 Return Level Return Level Plot Data 3.0 3.5 4.0 4.5 5.0 5.5 3.4 3.5 3.6 3.7 3.8 3.9 4.0 4.1 4.2 4.3 4.4 4.5 4.6 4.7 4.8 4.9 5.0 5.1 3.470 3.475 3.480 3.485 3.490 3.495 3.500 3.505 3.510 3.515 3.520 3.525 3.530 3.535 3.540 3.545 3.550 3.555 3.560 3.565 3.570 3.575 3.580 3.585 3.590 3.595 3.600 3.605 3.610 3.615 3.620 3.625 3.630 3.635 3.640 3.645 3.650 3.655 3.660 3.665 3.670 3.675 3.680 3.685 3.690 3.695 3.700 3.705 3.710 3.715 3.720 3.725 3.730 3.735 3.740 3.745 3.750 3.755 3.760 3.765 3.770 3.775 3.780 3.785 3.790 3.795 3.800 3.805 3.810 3.815 3.820 3.825 3.830 3.835 3.840 3.845 3.850 3.855 3.860 3.865 3.870 3.875 3.880 3.885 3.890 3.895 3.900 3.905 3.910 3.915 3.920 3.925 3.930 3.935 3.940 3.945 3.950 3.955 3.960 3.965 3.970 3.975 3.980 3.985 3.990 3.995 4.000 4.005 4.010 4.015 4.020 4.025 4.030 4.035 4.040 4.045 4.050 4.055 4.060 4.065 4.070 4.075 4.080 4.085 4.090 4.095 4.100 4.105 4.110 4.115 4.120 4.125 4.130 4.135 4.140 4.145 4.150 4.155 4.160 4.165 4.170 4.175 4.180 4.185 4.190 4.195 4.200 4.205 4.210 4.215 4.220 4.225 4.230 4.235 4.240 4.245 4.250 4.255 4.260 4.265 4.270 4.275 4.280 4.285 4.290 4.295 4.300 4.305 4.310 4.315 4.320 4.325 4.330 4.335 4.340 4.345 4.350 4.355 4.360 4.365 4.370 4.375 4.380 4.385 4.390 4.395 4.400 4.405 4.410 4.415 4.420 4.425 4.430 4.435 4.440 4.445 4.450 4.455 4.460 4.465 4.470 4.475 4.480 4.485 4.490 4.495 4.500 4.505 4.510 4.515 4.520 4.525 4.530 4.535 4.540 4.545 4.550 4.555 4.560 4.565 4.570 4.575 4.580 4.585 4.590 4.595 4.600 4.605 4.610 4.615 4.620 4.625 4.630 4.635 4.640 4.645 4.650 4.655 4.660 4.665 4.670 4.675 4.680 4.685 4.690 4.695 4.700 4.705 4.710 4.715 4.720 4.725 4.730 4.735 4.740 4.745 4.750 4.755 4.760 4.765 4.770 4.775 4.780 4.785 4.790 4.795 4.800 4.805 4.810 4.815 4.820 4.825 4.830 4.835 4.840 4.845 4.850 4.855 4.860 4.865 4.870 4.875 4.880 4.885 4.890 4.895 4.900 4.905 4.910 4.915 4.920 4.925 4.930 4.935 4.940 4.945 4.950 4.955 4.960 4.965 4.970 4.975 4.980 4.985 4.990 4.995 5.000 5.005 5.010 5.015 5.020 5.025 5.030 5.035 3 6 h,j,k,l,arrows,drag to pan i,o,+,-,scroll,shift-drag to zoom r,dbl-click to reset c for coordinates ? for help ? 0.0 0.5 1.0 1.5 2.0 0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 0.00 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.10 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.20 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.30 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.40 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.50 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.60 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.70 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.80 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.90 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.00 1.01 1.02 1.03 1.04 1.05 1.06 1.07 1.08 1.09 1.10 1.11 1.12 1.13 1.14 1.15 1.16 1.17 1.18 1.19 1.20 1.21 1.22 1.23 1.24 1.25 1.26 1.27 1.28 1.29 1.30 1.31 1.32 1.33 1.34 1.35 1.36 1.37 1.38 1.39 1.40 1.41 1.42 1.43 1.44 1.45 1.46 1.47 1.48 1.49 1.50 1.51 1.52 1.53 1.54 1.55 1.56 1.57 1.58 1.59 1.60 1.61 1.62 1.63 1.64 1.65 1.66 1.67 1.68 1.69 1.70 1.71 1.72 1.73 1.74 1.75 1.76 1.77 1.78 1.79 1.80 1.81 1.82 1.83 1.84 1.85 1.86 1.87 1.88 1.89 1.90 1.91 1.92 1.93 1.94 1.95 1.96 1.97 1.98 1.99 2.00 0 2 Density Density Plot Model 3.5 4.0 4.5 5.0 3.5 3.6 3.7 3.8 3.9 4.0 4.1 4.2 4.3 4.4 4.5 4.6 4.7 4.8 4.9 5.0 3.500 3.505 3.510 3.515 3.520 3.525 3.530 3.535 3.540 3.545 3.550 3.555 3.560 3.565 3.570 3.575 3.580 3.585 3.590 3.595 3.600 3.605 3.610 3.615 3.620 3.625 3.630 3.635 3.640 3.645 3.650 3.655 3.660 3.665 3.670 3.675 3.680 3.685 3.690 3.695 3.700 3.705 3.710 3.715 3.720 3.725 3.730 3.735 3.740 3.745 3.750 3.755 3.760 3.765 3.770 3.775 3.780 3.785 3.790 3.795 3.800 3.805 3.810 3.815 3.820 3.825 3.830 3.835 3.840 3.845 3.850 3.855 3.860 3.865 3.870 3.875 3.880 3.885 3.890 3.895 3.900 3.905 3.910 3.915 3.920 3.925 3.930 3.935 3.940 3.945 3.950 3.955 3.960 3.965 3.970 3.975 3.980 3.985 3.990 3.995 4.000 4.005 4.010 4.015 4.020 4.025 4.030 4.035 4.040 4.045 4.050 4.055 4.060 4.065 4.070 4.075 4.080 4.085 4.090 4.095 4.100 4.105 4.110 4.115 4.120 4.125 4.130 4.135 4.140 4.145 4.150 4.155 4.160 4.165 4.170 4.175 4.180 4.185 4.190 4.195 4.200 4.205 4.210 4.215 4.220 4.225 4.230 4.235 4.240 4.245 4.250 4.255 4.260 4.265 4.270 4.275 4.280 4.285 4.290 4.295 4.300 4.305 4.310 4.315 4.320 4.325 4.330 4.335 4.340 4.345 4.350 4.355 4.360 4.365 4.370 4.375 4.380 4.385 4.390 4.395 4.400 4.405 4.410 4.415 4.420 4.425 4.430 4.435 4.440 4.445 4.450 4.455 4.460 4.465 4.470 4.475 4.480 4.485 4.490 4.495 4.500 4.505 4.510 4.515 4.520 4.525 4.530 4.535 4.540 4.545 4.550 4.555 4.560 4.565 4.570 4.575 4.580 4.585 4.590 4.595 4.600 4.605 4.610 4.615 4.620 4.625 4.630 4.635 4.640 4.645 4.650 4.655 4.660 4.665 4.670 4.675 4.680 4.685 4.690 4.695 4.700 4.705 4.710 4.715 4.720 4.725 4.730 4.735 4.740 4.745 4.750 4.755 4.760 4.765 4.770 4.775 4.780 4.785 4.790 4.795 4.800 4.805 4.810 4.815 4.820 4.825 4.830 4.835 4.840 4.845 4.850 4.855 4.860 4.865 4.870 4.875 4.880 4.885 4.890 4.895 4.900 4.905 4.910 4.915 4.920 4.925 4.930 4.935 4.940 4.945 4.950 4.955 4.960 4.965 4.970 4.975 4.980 4.985 4.990 4.995 5.000 3 4 5 4.6219509798308444.69 4.5073896587311764.55 4.4379252372205574.55 4.3873501120583414.37 4.3472730930804924.36 4.313903268268714.33 4.2851964610403764.33 4.25992160207960254.25 4.2372785494932264.24 4.2167172562601814.24 4.1978429548925214.22 4.18036246023178754.21 4.1640518720023744.21 4.14873618478422754.18 4.1342758917585314.18 4.1205578840608224.11 4.107489089680754.11 4.0949919165478614.11 4.0830009172231174.08 4.0714603009881474.08 4.06032204638748254.06 4.0495444473207744.06 4.0390909774483094.05 4.0289293918036584.03 4.0190310075252554.01 4.0093701214333984.01 3.9999235332277164.0 3.99067015091516363.98 3.98159066070875723.97 3.9726672477294713.96 3.9638833568460993.96 3.95522348520539073.96 3.9466729996474673.96 3.9382179734150353.94 3.9298450374502633.93 3.9215412421998623.91 3.91329392626300183.9 3.9050905884463323.9 3.89691875984847653.89 3.88876587248179863.88 3.8806191206362553.88 3.8724653106656273.88 3.8642906940751653.86 3.85608077762571273.86 3.84782010251257533.85 3.83949198233107853.85 3.8310781862064933.85 3.82255854868440853.85 3.813910481030283.83 3.8051083483269283.8 3.7961226613133913.79 3.7869190081377673.78 3.7774566136810483.75 3.76768635317758933.75 3.7575479445941513.74 3.74696586597646063.73 3.73584321926299933.72 3.7240521389848173.71 3.71141807165880173.71 3.6976924459992053.66 3.68250144422118543.66 3.66523984685777743.65 3.64481765205137183.63 3.61890765144723763.62 3.58059910841052183.57 h,j,k,l,arrows,drag to pan i,o,+,-,scroll,shift-drag to zoom r,dbl-click to reset c for coordinates ? for help ? 3.5 4.0 4.5 5.0 3.5 3.6 3.7 3.8 3.9 4.0 4.1 4.2 4.3 4.4 4.5 4.6 4.7 4.8 4.9 5.0 3.500 3.505 3.510 3.515 3.520 3.525 3.530 3.535 3.540 3.545 3.550 3.555 3.560 3.565 3.570 3.575 3.580 3.585 3.590 3.595 3.600 3.605 3.610 3.615 3.620 3.625 3.630 3.635 3.640 3.645 3.650 3.655 3.660 3.665 3.670 3.675 3.680 3.685 3.690 3.695 3.700 3.705 3.710 3.715 3.720 3.725 3.730 3.735 3.740 3.745 3.750 3.755 3.760 3.765 3.770 3.775 3.780 3.785 3.790 3.795 3.800 3.805 3.810 3.815 3.820 3.825 3.830 3.835 3.840 3.845 3.850 3.855 3.860 3.865 3.870 3.875 3.880 3.885 3.890 3.895 3.900 3.905 3.910 3.915 3.920 3.925 3.930 3.935 3.940 3.945 3.950 3.955 3.960 3.965 3.970 3.975 3.980 3.985 3.990 3.995 4.000 4.005 4.010 4.015 4.020 4.025 4.030 4.035 4.040 4.045 4.050 4.055 4.060 4.065 4.070 4.075 4.080 4.085 4.090 4.095 4.100 4.105 4.110 4.115 4.120 4.125 4.130 4.135 4.140 4.145 4.150 4.155 4.160 4.165 4.170 4.175 4.180 4.185 4.190 4.195 4.200 4.205 4.210 4.215 4.220 4.225 4.230 4.235 4.240 4.245 4.250 4.255 4.260 4.265 4.270 4.275 4.280 4.285 4.290 4.295 4.300 4.305 4.310 4.315 4.320 4.325 4.330 4.335 4.340 4.345 4.350 4.355 4.360 4.365 4.370 4.375 4.380 4.385 4.390 4.395 4.400 4.405 4.410 4.415 4.420 4.425 4.430 4.435 4.440 4.445 4.450 4.455 4.460 4.465 4.470 4.475 4.480 4.485 4.490 4.495 4.500 4.505 4.510 4.515 4.520 4.525 4.530 4.535 4.540 4.545 4.550 4.555 4.560 4.565 4.570 4.575 4.580 4.585 4.590 4.595 4.600 4.605 4.610 4.615 4.620 4.625 4.630 4.635 4.640 4.645 4.650 4.655 4.660 4.665 4.670 4.675 4.680 4.685 4.690 4.695 4.700 4.705 4.710 4.715 4.720 4.725 4.730 4.735 4.740 4.745 4.750 4.755 4.760 4.765 4.770 4.775 4.780 4.785 4.790 4.795 4.800 4.805 4.810 4.815 4.820 4.825 4.830 4.835 4.840 4.845 4.850 4.855 4.860 4.865 4.870 4.875 4.880 4.885 4.890 4.895 4.900 4.905 4.910 4.915 4.920 4.925 4.930 4.935 4.940 4.945 4.950 4.955 4.960 4.965 4.970 4.975 4.980 4.985 4.990 4.995 5.000 3 4 5 Empirical Quantile Plot Model 0.0 0.5 1.0 0.00 0.05 0.10 0.15 0.20 0.25 0.30 0.35 0.40 0.45 0.50 0.55 0.60 0.65 0.70 0.75 0.80 0.85 0.90 0.95 1.00 0.000 0.005 0.010 0.015 0.020 0.025 0.030 0.035 0.040 0.045 0.050 0.055 0.060 0.065 0.070 0.075 0.080 0.085 0.090 0.095 0.100 0.105 0.110 0.115 0.120 0.125 0.130 0.135 0.140 0.145 0.150 0.155 0.160 0.165 0.170 0.175 0.180 0.185 0.190 0.195 0.200 0.205 0.210 0.215 0.220 0.225 0.230 0.235 0.240 0.245 0.250 0.255 0.260 0.265 0.270 0.275 0.280 0.285 0.290 0.295 0.300 0.305 0.310 0.315 0.320 0.325 0.330 0.335 0.340 0.345 0.350 0.355 0.360 0.365 0.370 0.375 0.380 0.385 0.390 0.395 0.400 0.405 0.410 0.415 0.420 0.425 0.430 0.435 0.440 0.445 0.450 0.455 0.460 0.465 0.470 0.475 0.480 0.485 0.490 0.495 0.500 0.505 0.510 0.515 0.520 0.525 0.530 0.535 0.540 0.545 0.550 0.555 0.560 0.565 0.570 0.575 0.580 0.585 0.590 0.595 0.600 0.605 0.610 0.615 0.620 0.625 0.630 0.635 0.640 0.645 0.650 0.655 0.660 0.665 0.670 0.675 0.680 0.685 0.690 0.695 0.700 0.705 0.710 0.715 0.720 0.725 0.730 0.735 0.740 0.745 0.750 0.755 0.760 0.765 0.770 0.775 0.780 0.785 0.790 0.795 0.800 0.805 0.810 0.815 0.820 0.825 0.830 0.835 0.840 0.845 0.850 0.855 0.860 0.865 0.870 0.875 0.880 0.885 0.890 0.895 0.900 0.905 0.910 0.915 0.920 0.925 0.930 0.935 0.940 0.945 0.950 0.955 0.960 0.965 0.970 0.975 0.980 0.985 0.990 0.995 1.000 0 1 0.99010053058224780.9848484848484849 0.97650210763630050.9696969696969697 0.97650210763630050.9545454545454546 0.93321091988811060.9393939393939394 0.92939101449036890.9242424242424242 0.91671062941716220.9090909090909091 0.91671062941716220.8939393939393939 0.87233980831400430.8787878787878788 0.86554033047676530.8636363636363636 0.86554033047676530.8484848484848485 0.85099657827387360.8333333333333334 0.8432325017727410.8181818181818182 0.8432325017727410.803030303030303 0.81785590009886520.7878787878787878 0.81785590009886520.7727272727272727 0.7453900741842490.7575757575757576 0.7453900741842490.7424242424242424 0.7453900741842490.7272727272727273 0.70823505183899630.7121212121212122 0.70823505183899630.696969696969697 0.68137240938767050.6818181818181818 0.68137240938767050.6666666666666666 0.66731679869928480.6515151515151515 0.63797938096828930.6363636363636364 0.60705919188059170.6212121212121212 0.60705919188059170.6060606060606061 0.59103303823344880.5909090909090909 0.55792367347072520.5757575757575758 0.5408778674161110.5606060606060606 0.52353387599501370.5454545454545454 0.52353387599501370.5303030303030303 0.52353387599501370.5151515151515151 0.52353387599501370.5 0.488054965276711440.48484848484848486 0.469978599967746440.4696969696969697 0.43331854235728040.45454545454545453 0.41480927452708190.4393939393939394 0.41480927452708190.42424242424242425 0.396234251648682640.4090909090909091 0.37763664582146870.3939393939393939 0.37763664582146870.3787878787878788 0.37763664582146870.36363636363636365 0.3405564272709580.3484848484848485 0.3405564272709580.3333333333333333 0.322169429631464830.3181818181818182 0.322169429631464830.30303030303030304 0.322169429631464830.2878787878787879 0.322169429631464830.2727272727272727 0.285950069557234070.25757575757575757 0.233769221393338920.24242424242424243 0.217149621406222880.22727272727272727 0.200997664605057970.21212121212121213 0.155787780522999080.19696969696969696 0.155787780522999080.18181818181818182 0.141930610745581470.16666666666666666 0.128735419058502910.15151515151515152 0.11622864329282370.13636363636363635 0.104431525702927620.12121212121212122 0.104431525702927620.10606060606060606 0.0564361556412569940.09090909090909091 0.0564361556412569940.07575757575757576 0.04902158135621790.06060606060606061 0.036257878806067290.045454545454545456 0.030855545359097220.030303030303030304 0.0122361316781267810.015151515151515152 h,j,k,l,arrows,drag to pan i,o,+,-,scroll,shift-drag to zoom r,dbl-click to reset c for coordinates ? for help ? 0.0 0.5 1.0 0.00 0.05 0.10 0.15 0.20 0.25 0.30 0.35 0.40 0.45 0.50 0.55 0.60 0.65 0.70 0.75 0.80 0.85 0.90 0.95 1.00 0.000 0.005 0.010 0.015 0.020 0.025 0.030 0.035 0.040 0.045 0.050 0.055 0.060 0.065 0.070 0.075 0.080 0.085 0.090 0.095 0.100 0.105 0.110 0.115 0.120 0.125 0.130 0.135 0.140 0.145 0.150 0.155 0.160 0.165 0.170 0.175 0.180 0.185 0.190 0.195 0.200 0.205 0.210 0.215 0.220 0.225 0.230 0.235 0.240 0.245 0.250 0.255 0.260 0.265 0.270 0.275 0.280 0.285 0.290 0.295 0.300 0.305 0.310 0.315 0.320 0.325 0.330 0.335 0.340 0.345 0.350 0.355 0.360 0.365 0.370 0.375 0.380 0.385 0.390 0.395 0.400 0.405 0.410 0.415 0.420 0.425 0.430 0.435 0.440 0.445 0.450 0.455 0.460 0.465 0.470 0.475 0.480 0.485 0.490 0.495 0.500 0.505 0.510 0.515 0.520 0.525 0.530 0.535 0.540 0.545 0.550 0.555 0.560 0.565 0.570 0.575 0.580 0.585 0.590 0.595 0.600 0.605 0.610 0.615 0.620 0.625 0.630 0.635 0.640 0.645 0.650 0.655 0.660 0.665 0.670 0.675 0.680 0.685 0.690 0.695 0.700 0.705 0.710 0.715 0.720 0.725 0.730 0.735 0.740 0.745 0.750 0.755 0.760 0.765 0.770 0.775 0.780 0.785 0.790 0.795 0.800 0.805 0.810 0.815 0.820 0.825 0.830 0.835 0.840 0.845 0.850 0.855 0.860 0.865 0.870 0.875 0.880 0.885 0.890 0.895 0.900 0.905 0.910 0.915 0.920 0.925 0.930 0.935 0.940 0.945 0.950 0.955 0.960 0.965 0.970 0.975 0.980 0.985 0.990 0.995 1.000 0 1 Empirical Probability Plot

The diagnostic plots consist in the probability plot (upper left panel), the quantile plot (upper right panel), the density plot (lower left panel) and the return level plot (lower right panel). These plots can be displayed separately using respectively the probplot, qqplot, histplot and returnlevelplot functions.

Return level estimation

T-year return level estimate can be obtained using the returnlevel function. For example, the 100-year return level for the Port Pirie block maxima model is computed as follows:

julia> r = returnlevel(fm, 100)ReturnLevel
returnperiod :	100
value :		Vector{Float64}[1]

The return level can be accessed as follows:

julia> r.value1-element Vector{Float64}:
 4.688403360432851

The corresponding confidence interval can be computed with the cint function:

julia> c = cint(r)1-element Vector{Vector{Real}}:
 [4.377121171613512, 4.99968554925219]

To get the scalar return level in the stationary case, the following command can be used:

julia> r.value[]4.688403360432851

To get the scalar confidence interval in the stationary case, the following command can be used:

julia> c[]2-element Vector{Real}:
 4.377121171613512
 4.99968554925219

Bayesian Inference

Most functions described in the previous sections also work in the Bayesian context. To reproduce exactly the results, the seed should be fixed as follows:

import Random
Random.seed!(4786)

GEV parameter estimation

The Bayesian GEV parameter estimation is performed with the gevfitbayes function:

julia> fm = gevfitbayes(data, :SeaLevel)
Progress:   0%|                                         |  ETA: 0:06:38
Progress: 100%|█████████████████████████████████████████| Time: 0:00:02
BayesianAbstractExtremeValueModel
model :
	BlockMaxima{GeneralizedExtremeValue}
	data :		Vector{Float64}[65]
	location :	μ ~ 1
	logscale :	ϕ ~ 1
	shape :		ξ ~ 1

sim :
	MambaLite.Chains
	Iterations :		2001:5000
	Thinning interval :	1
	Chains :		1
	Samples per chain :	3000
	Value :			Array{Float64, 3}[3000,3,1]
Prior

Currently, only the improper uniform prior is implemented, i.e. \[ f_{(μ,ϕ,ξ)}(μ,ϕ,ξ) ∝ 1. \] It yields to a proper posterior as long as the sample size is larger than 3 (Northrop and Attalides, 2016).

Sampling scheme

Currently, the No-U-Turn Sampler extension (Hoffman and Gelman, 2014) to Hamiltonian Monte Carlo (Neel, 2011, Chapter 5) is implemented for simulating an autocorrelated sample from the posterior distribution.

The generated sample from the posterior distribution is contained in the field sim of the fitted structure. It is an object of type Chains from the Mamba.jl package.

Credible intervals for the parameters are obtained with the cint function:

julia> cint(fm)3-element Vector{Vector{Float64}}:
 [3.8182738930811233, 3.931583774977113]
 [-1.7897113975890682, -1.4005833922456459]
 [-0.2018902582086667, 0.1553392907141933]

Inference based on the probability weighted moments

Most functions described in the previous sections also work for the model fitted with the probability weighted moments.

GEV parameter estimation

The parameter estimation based on the probability weighted moments is performed with the gevfitpwm function:

julia> fm = gevfitpwm(data, :SeaLevel)pwmAbstractExtremeValueModel
model :
	BlockMaxima{GeneralizedExtremeValue}
	data :		Vector{Float64}[65]
	location :	μ ~ 1
	logscale :	ϕ ~ 1
	shape :		ξ ~ 1

θ̂  :	[3.8731723562720766, -1.5932320395836068, -0.051477125862911276]

The approximate covariance matrix of the parameter estimates using a bootstrap procedure can be obtained with the parametervar function:

julia> parametervar(fm)3×3 Matrix{Float64}:
  0.000871239   0.00116247  -0.00111277
  0.00116247    0.0106812   -0.00361624
 -0.00111277   -0.00361624   0.0072629

Confidence intervals on the parameter estimates using a bootstrap procedure can be obtained with the cint function:

julia> cint(fm)3-element Vector{Vector{Float64}}:
 [3.822276679146202, 3.9317746782451266]
 [-1.8146460804733326, -1.4222820715987998]
 [-0.224777189866786, 0.08648421062397504]

Inference for the Gumbel distribution

The inference for the Gumbel distribution is also provided for modeling the series of block maxima. The Gumbel distribution is a sub-family of the GEV distribution when the shape parameter $\xi = 0$. The library provides functions analogous to those for the GEV distribution for the adjustment of the parameters of the Gumbel distribution:

The inference for the fitted model is performed with the same methods defined previously for the GEV distribution, notably with the cint and returnlevel methods. Diagnostic plot methods diagnosticplots are also implemented, such as probplot, qqplot, histplot and returnlevelplot.

Gumbel distribution for modelling block maxima

As extreme-value statisticians, we advocate avoiding the use of the Gumbel distribution for modelling the block maxima. This is because the choice of family is made with the data at hand, and when extrapolating to large quantiles, i.e. larger than the range of the data, the uncertainty associated with this choice is not taken into account. If the data suggest that the Gumbel family is the best one, this does not imply that the other families are not plausible. In applications, the confidence intervals on the shape parameter are often wide, representing the difficulty of discriminating the tail behavior using only the limited number of data. Therefore, we plead for the use of the GEV distribution for the block maxima model without choosing a subfamily such as the Gumbel. As Coles (2001) also argued in Page 64, this is "... the safest option is to accept there is uncertainty about the value of the shape parameter ... and to prefer the inference based on the GEV model. The larger measures of uncertainty generated by the GEV model then provide a more realistic quantification of the genuine uncertainties involved in model extrapolation".

Example on the annual maximum sea-levels recorded at Port Pirie

The Gumbel distribution parameter estimation with maximum likelihood can be performed with the gumbelfit function:

julia> fm = gumbelfit(data, :SeaLevel)MaximumLikelihoodAbstractExtremeValueModel
model :
	BlockMaxima{Gumbel}
	data :		Vector{Float64}[65]
	location :	μ ~ 1
	logscale :	ϕ ~ 1

θ̂  :	[3.8694436499474767, -1.6353194298573894]

The approximate covariance matrix of the parameter estimates can be obtained with the parametervar function:

julia> parametervar(fm)2×2 Matrix{Float64}:
 0.000649941  0.000783584
 0.000783584  0.00935991

Confidence intervals for the parameters are obtained with the cint function:

julia> cint(fm)2-element Vector{Vector{Float64}}:
 [3.819476453475028, 3.9194108464199253]
 [-1.824939298384268, -1.4456995613305108]

The diagnostic plots for assessing the accuracy of the Gumbel model can be shown with the diagnosticplots function:

set_default_plot_size(21cm ,16cm)
diagnosticplots(fm)
Return Period 100.0 100.5 101.0 101.5 102.0 100.0 100.1 100.2 100.3 100.4 100.5 100.6 100.7 100.8 100.9 101.0 101.1 101.2 101.3 101.4 101.5 101.6 101.7 101.8 101.9 102.0 100.00 100.01 100.02 100.03 100.04 100.05 100.06 100.07 100.08 100.09 100.10 100.11 100.12 100.13 100.14 100.15 100.16 100.17 100.18 100.19 100.20 100.21 100.22 100.23 100.24 100.25 100.26 100.27 100.28 100.29 100.30 100.31 100.32 100.33 100.34 100.35 100.36 100.37 100.38 100.39 100.40 100.41 100.42 100.43 100.44 100.45 100.46 100.47 100.48 100.49 100.50 100.51 100.52 100.53 100.54 100.55 100.56 100.57 100.58 100.59 100.60 100.61 100.62 100.63 100.64 100.65 100.66 100.67 100.68 100.69 100.70 100.71 100.72 100.73 100.74 100.75 100.76 100.77 100.78 100.79 100.80 100.81 100.82 100.83 100.84 100.85 100.86 100.87 100.88 100.89 100.90 100.91 100.92 100.93 100.94 100.95 100.96 100.97 100.98 100.99 101.00 101.01 101.02 101.03 101.04 101.05 101.06 101.07 101.08 101.09 101.10 101.11 101.12 101.13 101.14 101.15 101.16 101.17 101.18 101.19 101.20 101.21 101.22 101.23 101.24 101.25 101.26 101.27 101.28 101.29 101.30 101.31 101.32 101.33 101.34 101.35 101.36 101.37 101.38 101.39 101.40 101.41 101.42 101.43 101.44 101.45 101.46 101.47 101.48 101.49 101.50 101.51 101.52 101.53 101.54 101.55 101.56 101.57 101.58 101.59 101.60 101.61 101.62 101.63 101.64 101.65 101.66 101.67 101.68 101.69 101.70 101.71 101.72 101.73 101.74 101.75 101.76 101.77 101.78 101.79 101.80 101.81 101.82 101.83 101.84 101.85 101.86 101.87 101.88 101.89 101.90 101.91 101.92 101.93 101.94 101.95 101.96 101.97 101.98 101.99 102.00 100 102 1.8195439355418694.69 1.51851393987788774.55 1.34242268082220664.55 1.21748394421390674.37 1.12057393120584964.36 1.0413926851582254.33 0.97444589552761174.33 0.91645394854992514.25 0.86530142610254384.24 0.81954393554186884.24 0.77815125038364374.22 0.7403626894942444.21 0.70560058323503184.21 0.67341589986363064.18 0.64345267648618744.18 0.61542395288594394.11 0.58909501416359484.11 0.56427143043856264.11 0.54079033458903984.08 0.51851393987788754.08 0.497324640807949364.06 0.47712125471966244.06 0.457816099524275774.05 0.439332693830262634.03 0.421603926869831064.01 0.404570587571050744.01 0.38818017138288144.0 0.372385904199649453.98 0.35714593764291253.97 0.342422680822206173.96 0.328182241707595973.96 0.314393957221962673.96 0.30102999566398123.96 0.28806501849961353.94 0.27547589119159313.93 0.263241434774581453.91 0.251342211474873733.9 0.23976033892505863.9 0.22847932851536953.89 0.217483944213906273.88 0.20676007882213323.88 0.19629464514396823.88 0.186075479962282163.86 0.176091259055681183.86 0.166331421766524963.85 0.156786103860294573.85 0.147446077606151223.85 0.138302698166281463.85 0.129347855513354983.83 0.120573931205849893.8 0.111973759443932333.79 0.103540591907069563.78 0.095268065941079693.75 0.08715017571890023.75 0.079181246047624823.74 0.071355908535668273.73 0.06366907986937733.72 0.056115941978931413.71 0.0486919238997245363.71 0.041392685158225083.66 0.0342141005311016743.66 0.0271522460436147763.65 0.020203386088286993.63 0.0133639615579815023.62 0.0066305788990130763.57 h,j,k,l,arrows,drag to pan i,o,+,-,scroll,shift-drag to zoom r,dbl-click to reset c for coordinates ? for help ? 3.5 4.0 4.5 5.0 3.5 3.6 3.7 3.8 3.9 4.0 4.1 4.2 4.3 4.4 4.5 4.6 4.7 4.8 4.9 5.0 3.500 3.505 3.510 3.515 3.520 3.525 3.530 3.535 3.540 3.545 3.550 3.555 3.560 3.565 3.570 3.575 3.580 3.585 3.590 3.595 3.600 3.605 3.610 3.615 3.620 3.625 3.630 3.635 3.640 3.645 3.650 3.655 3.660 3.665 3.670 3.675 3.680 3.685 3.690 3.695 3.700 3.705 3.710 3.715 3.720 3.725 3.730 3.735 3.740 3.745 3.750 3.755 3.760 3.765 3.770 3.775 3.780 3.785 3.790 3.795 3.800 3.805 3.810 3.815 3.820 3.825 3.830 3.835 3.840 3.845 3.850 3.855 3.860 3.865 3.870 3.875 3.880 3.885 3.890 3.895 3.900 3.905 3.910 3.915 3.920 3.925 3.930 3.935 3.940 3.945 3.950 3.955 3.960 3.965 3.970 3.975 3.980 3.985 3.990 3.995 4.000 4.005 4.010 4.015 4.020 4.025 4.030 4.035 4.040 4.045 4.050 4.055 4.060 4.065 4.070 4.075 4.080 4.085 4.090 4.095 4.100 4.105 4.110 4.115 4.120 4.125 4.130 4.135 4.140 4.145 4.150 4.155 4.160 4.165 4.170 4.175 4.180 4.185 4.190 4.195 4.200 4.205 4.210 4.215 4.220 4.225 4.230 4.235 4.240 4.245 4.250 4.255 4.260 4.265 4.270 4.275 4.280 4.285 4.290 4.295 4.300 4.305 4.310 4.315 4.320 4.325 4.330 4.335 4.340 4.345 4.350 4.355 4.360 4.365 4.370 4.375 4.380 4.385 4.390 4.395 4.400 4.405 4.410 4.415 4.420 4.425 4.430 4.435 4.440 4.445 4.450 4.455 4.460 4.465 4.470 4.475 4.480 4.485 4.490 4.495 4.500 4.505 4.510 4.515 4.520 4.525 4.530 4.535 4.540 4.545 4.550 4.555 4.560 4.565 4.570 4.575 4.580 4.585 4.590 4.595 4.600 4.605 4.610 4.615 4.620 4.625 4.630 4.635 4.640 4.645 4.650 4.655 4.660 4.665 4.670 4.675 4.680 4.685 4.690 4.695 4.700 4.705 4.710 4.715 4.720 4.725 4.730 4.735 4.740 4.745 4.750 4.755 4.760 4.765 4.770 4.775 4.780 4.785 4.790 4.795 4.800 4.805 4.810 4.815 4.820 4.825 4.830 4.835 4.840 4.845 4.850 4.855 4.860 4.865 4.870 4.875 4.880 4.885 4.890 4.895 4.900 4.905 4.910 4.915 4.920 4.925 4.930 4.935 4.940 4.945 4.950 4.955 4.960 4.965 4.970 4.975 4.980 4.985 4.990 4.995 5.000 3 4 5 Return Level Return Level Plot Data 3.0 3.5 4.0 4.5 5.0 5.5 3.4 3.5 3.6 3.7 3.8 3.9 4.0 4.1 4.2 4.3 4.4 4.5 4.6 4.7 4.8 4.9 5.0 5.1 5.2 5.3 3.49 3.50 3.51 3.52 3.53 3.54 3.55 3.56 3.57 3.58 3.59 3.60 3.61 3.62 3.63 3.64 3.65 3.66 3.67 3.68 3.69 3.70 3.71 3.72 3.73 3.74 3.75 3.76 3.77 3.78 3.79 3.80 3.81 3.82 3.83 3.84 3.85 3.86 3.87 3.88 3.89 3.90 3.91 3.92 3.93 3.94 3.95 3.96 3.97 3.98 3.99 4.00 4.01 4.02 4.03 4.04 4.05 4.06 4.07 4.08 4.09 4.10 4.11 4.12 4.13 4.14 4.15 4.16 4.17 4.18 4.19 4.20 4.21 4.22 4.23 4.24 4.25 4.26 4.27 4.28 4.29 4.30 4.31 4.32 4.33 4.34 4.35 4.36 4.37 4.38 4.39 4.40 4.41 4.42 4.43 4.44 4.45 4.46 4.47 4.48 4.49 4.50 4.51 4.52 4.53 4.54 4.55 4.56 4.57 4.58 4.59 4.60 4.61 4.62 4.63 4.64 4.65 4.66 4.67 4.68 4.69 4.70 4.71 4.72 4.73 4.74 4.75 4.76 4.77 4.78 4.79 4.80 4.81 4.82 4.83 4.84 4.85 4.86 4.87 4.88 4.89 4.90 4.91 4.92 4.93 4.94 4.95 4.96 4.97 4.98 4.99 5.00 5.01 5.02 5.03 5.04 5.05 5.06 5.07 5.08 5.09 5.10 5.11 5.12 5.13 5.14 5.15 5.16 5.17 5.18 5.19 5.20 5.21 5.22 3 6 h,j,k,l,arrows,drag to pan i,o,+,-,scroll,shift-drag to zoom r,dbl-click to reset c for coordinates ? for help ? 0.0 0.5 1.0 1.5 2.0 0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 0.00 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.10 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.20 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.30 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.40 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.50 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.60 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.70 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.80 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.90 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.00 1.01 1.02 1.03 1.04 1.05 1.06 1.07 1.08 1.09 1.10 1.11 1.12 1.13 1.14 1.15 1.16 1.17 1.18 1.19 1.20 1.21 1.22 1.23 1.24 1.25 1.26 1.27 1.28 1.29 1.30 1.31 1.32 1.33 1.34 1.35 1.36 1.37 1.38 1.39 1.40 1.41 1.42 1.43 1.44 1.45 1.46 1.47 1.48 1.49 1.50 1.51 1.52 1.53 1.54 1.55 1.56 1.57 1.58 1.59 1.60 1.61 1.62 1.63 1.64 1.65 1.66 1.67 1.68 1.69 1.70 1.71 1.72 1.73 1.74 1.75 1.76 1.77 1.78 1.79 1.80 1.81 1.82 1.83 1.84 1.85 1.86 1.87 1.88 1.89 1.90 1.91 1.92 1.93 1.94 1.95 1.96 1.97 1.98 1.99 2.00 0 2 Density Density Plot Model 3.5 4.0 4.5 5.0 3.5 3.6 3.7 3.8 3.9 4.0 4.1 4.2 4.3 4.4 4.5 4.6 4.7 4.8 4.9 5.0 3.500 3.505 3.510 3.515 3.520 3.525 3.530 3.535 3.540 3.545 3.550 3.555 3.560 3.565 3.570 3.575 3.580 3.585 3.590 3.595 3.600 3.605 3.610 3.615 3.620 3.625 3.630 3.635 3.640 3.645 3.650 3.655 3.660 3.665 3.670 3.675 3.680 3.685 3.690 3.695 3.700 3.705 3.710 3.715 3.720 3.725 3.730 3.735 3.740 3.745 3.750 3.755 3.760 3.765 3.770 3.775 3.780 3.785 3.790 3.795 3.800 3.805 3.810 3.815 3.820 3.825 3.830 3.835 3.840 3.845 3.850 3.855 3.860 3.865 3.870 3.875 3.880 3.885 3.890 3.895 3.900 3.905 3.910 3.915 3.920 3.925 3.930 3.935 3.940 3.945 3.950 3.955 3.960 3.965 3.970 3.975 3.980 3.985 3.990 3.995 4.000 4.005 4.010 4.015 4.020 4.025 4.030 4.035 4.040 4.045 4.050 4.055 4.060 4.065 4.070 4.075 4.080 4.085 4.090 4.095 4.100 4.105 4.110 4.115 4.120 4.125 4.130 4.135 4.140 4.145 4.150 4.155 4.160 4.165 4.170 4.175 4.180 4.185 4.190 4.195 4.200 4.205 4.210 4.215 4.220 4.225 4.230 4.235 4.240 4.245 4.250 4.255 4.260 4.265 4.270 4.275 4.280 4.285 4.290 4.295 4.300 4.305 4.310 4.315 4.320 4.325 4.330 4.335 4.340 4.345 4.350 4.355 4.360 4.365 4.370 4.375 4.380 4.385 4.390 4.395 4.400 4.405 4.410 4.415 4.420 4.425 4.430 4.435 4.440 4.445 4.450 4.455 4.460 4.465 4.470 4.475 4.480 4.485 4.490 4.495 4.500 4.505 4.510 4.515 4.520 4.525 4.530 4.535 4.540 4.545 4.550 4.555 4.560 4.565 4.570 4.575 4.580 4.585 4.590 4.595 4.600 4.605 4.610 4.615 4.620 4.625 4.630 4.635 4.640 4.645 4.650 4.655 4.660 4.665 4.670 4.675 4.680 4.685 4.690 4.695 4.700 4.705 4.710 4.715 4.720 4.725 4.730 4.735 4.740 4.745 4.750 4.755 4.760 4.765 4.770 4.775 4.780 4.785 4.790 4.795 4.800 4.805 4.810 4.815 4.820 4.825 4.830 4.835 4.840 4.845 4.850 4.855 4.860 4.865 4.870 4.875 4.880 4.885 4.890 4.895 4.900 4.905 4.910 4.915 4.920 4.925 4.930 4.935 4.940 4.945 4.950 4.955 4.960 4.965 4.970 4.975 4.980 4.985 4.990 4.995 5.000 3 4 5 4.6844800667667984.69 4.5478875281421974.55 4.4673416741454924.55 4.4097302968020954.37 4.3646759749010774.36 4.3275559727316214.33 4.2959040643763264.33 4.2682478405965724.25 4.2436372933105474.24 4.22142350276411454.24 4.2011433692529464.22 4.1824547117859264.21 4.1650974330983984.21 4.14886911635754.18 4.1336090601435824.18 4.1191874750407974.11 4.1054979597087654.11 4.0924521292421054.11 4.0799756961565694.08 4.068005556024124.08 4.0564875830179674.06 4.0453749367275424.06 4.0346267434659894.05 4.02420705605462554.03 4.01408402349359154.01 4.0042292207287734.01 3.99461710183340024.0 3.9852245492019613.98 3.9760304980122933.97 3.96701562004645373.96 3.9581620545068883.96 3.9494531760854893.96 3.9408733924896173.96 3.932407965074983.94 3.9240428473015043.93 3.91576453649903033.91 3.907559934961823.9 3.89941621672095853.9 3.8913206964915953.89 3.88326069726253743.88 3.8752234127790183.88 3.86719576073874153.88 3.85916422182879253.86 3.85111465870032753.86 3.843032107492033.85 3.83490053239432263.85 3.82670253072332673.85 3.8184189716293083.85 3.81002854524568063.83 3.8015071897491343.8 3.7928273497466573.79 3.7839569977783863.78 3.7748583166036373.75 3.7654858845416683.75 3.75578411321064333.74 3.7456835251169313.73 3.7350951638211713.72 3.7239018642401323.71 3.7119439571702813.71 3.69899444119197263.66 3.68471249361378963.66 3.66854725650780633.65 3.64950852687855283.63 3.6254871063274383.62 3.5902405093992523.57 h,j,k,l,arrows,drag to pan i,o,+,-,scroll,shift-drag to zoom r,dbl-click to reset c for coordinates ? for help ? 3.5 4.0 4.5 5.0 3.5 3.6 3.7 3.8 3.9 4.0 4.1 4.2 4.3 4.4 4.5 4.6 4.7 4.8 4.9 5.0 3.500 3.505 3.510 3.515 3.520 3.525 3.530 3.535 3.540 3.545 3.550 3.555 3.560 3.565 3.570 3.575 3.580 3.585 3.590 3.595 3.600 3.605 3.610 3.615 3.620 3.625 3.630 3.635 3.640 3.645 3.650 3.655 3.660 3.665 3.670 3.675 3.680 3.685 3.690 3.695 3.700 3.705 3.710 3.715 3.720 3.725 3.730 3.735 3.740 3.745 3.750 3.755 3.760 3.765 3.770 3.775 3.780 3.785 3.790 3.795 3.800 3.805 3.810 3.815 3.820 3.825 3.830 3.835 3.840 3.845 3.850 3.855 3.860 3.865 3.870 3.875 3.880 3.885 3.890 3.895 3.900 3.905 3.910 3.915 3.920 3.925 3.930 3.935 3.940 3.945 3.950 3.955 3.960 3.965 3.970 3.975 3.980 3.985 3.990 3.995 4.000 4.005 4.010 4.015 4.020 4.025 4.030 4.035 4.040 4.045 4.050 4.055 4.060 4.065 4.070 4.075 4.080 4.085 4.090 4.095 4.100 4.105 4.110 4.115 4.120 4.125 4.130 4.135 4.140 4.145 4.150 4.155 4.160 4.165 4.170 4.175 4.180 4.185 4.190 4.195 4.200 4.205 4.210 4.215 4.220 4.225 4.230 4.235 4.240 4.245 4.250 4.255 4.260 4.265 4.270 4.275 4.280 4.285 4.290 4.295 4.300 4.305 4.310 4.315 4.320 4.325 4.330 4.335 4.340 4.345 4.350 4.355 4.360 4.365 4.370 4.375 4.380 4.385 4.390 4.395 4.400 4.405 4.410 4.415 4.420 4.425 4.430 4.435 4.440 4.445 4.450 4.455 4.460 4.465 4.470 4.475 4.480 4.485 4.490 4.495 4.500 4.505 4.510 4.515 4.520 4.525 4.530 4.535 4.540 4.545 4.550 4.555 4.560 4.565 4.570 4.575 4.580 4.585 4.590 4.595 4.600 4.605 4.610 4.615 4.620 4.625 4.630 4.635 4.640 4.645 4.650 4.655 4.660 4.665 4.670 4.675 4.680 4.685 4.690 4.695 4.700 4.705 4.710 4.715 4.720 4.725 4.730 4.735 4.740 4.745 4.750 4.755 4.760 4.765 4.770 4.775 4.780 4.785 4.790 4.795 4.800 4.805 4.810 4.815 4.820 4.825 4.830 4.835 4.840 4.845 4.850 4.855 4.860 4.865 4.870 4.875 4.880 4.885 4.890 4.895 4.900 4.905 4.910 4.915 4.920 4.925 4.930 4.935 4.940 4.945 4.950 4.955 4.960 4.965 4.970 4.975 4.980 4.985 4.990 4.995 5.000 3 4 5 Empirical Quantile Plot Model 0.0 0.5 1.0 0.00 0.05 0.10 0.15 0.20 0.25 0.30 0.35 0.40 0.45 0.50 0.55 0.60 0.65 0.70 0.75 0.80 0.85 0.90 0.95 1.00 0.000 0.005 0.010 0.015 0.020 0.025 0.030 0.035 0.040 0.045 0.050 0.055 0.060 0.065 0.070 0.075 0.080 0.085 0.090 0.095 0.100 0.105 0.110 0.115 0.120 0.125 0.130 0.135 0.140 0.145 0.150 0.155 0.160 0.165 0.170 0.175 0.180 0.185 0.190 0.195 0.200 0.205 0.210 0.215 0.220 0.225 0.230 0.235 0.240 0.245 0.250 0.255 0.260 0.265 0.270 0.275 0.280 0.285 0.290 0.295 0.300 0.305 0.310 0.315 0.320 0.325 0.330 0.335 0.340 0.345 0.350 0.355 0.360 0.365 0.370 0.375 0.380 0.385 0.390 0.395 0.400 0.405 0.410 0.415 0.420 0.425 0.430 0.435 0.440 0.445 0.450 0.455 0.460 0.465 0.470 0.475 0.480 0.485 0.490 0.495 0.500 0.505 0.510 0.515 0.520 0.525 0.530 0.535 0.540 0.545 0.550 0.555 0.560 0.565 0.570 0.575 0.580 0.585 0.590 0.595 0.600 0.605 0.610 0.615 0.620 0.625 0.630 0.635 0.640 0.645 0.650 0.655 0.660 0.665 0.670 0.675 0.680 0.685 0.690 0.695 0.700 0.705 0.710 0.715 0.720 0.725 0.730 0.735 0.740 0.745 0.750 0.755 0.760 0.765 0.770 0.775 0.780 0.785 0.790 0.795 0.800 0.805 0.810 0.815 0.820 0.825 0.830 0.835 0.840 0.845 0.850 0.855 0.860 0.865 0.870 0.875 0.880 0.885 0.890 0.895 0.900 0.905 0.910 0.915 0.920 0.925 0.930 0.935 0.940 0.945 0.950 0.955 0.960 0.965 0.970 0.975 0.980 0.985 0.990 0.995 1.000 0 1 0.98526847331057530.9848484848484849 0.97001871226417440.9696969696969697 0.97001871226417440.9545454545454546 0.92620668689261620.9393939393939394 0.92247600351985460.9242424242424242 0.91017134872110570.9090909090909091 0.91017134872110570.8939393939393939 0.86771279533161750.8787878787878788 0.86125446585329910.8636363636363636 0.86125446585329910.8484848484848485 0.84746347694415470.8333333333333334 0.84011076086249510.8181818181818182 0.84011076086249510.803030303030303 0.81610341301371890.7878787878787878 0.81610341301371890.7727272727272727 0.74749085646498870.7575757575757576 0.74749085646498870.7424242424242424 0.74749085646498870.7272727272727273 0.71215136092686320.7121212121212122 0.71215136092686320.696969696969697 0.68649826367421150.6818181818181818 0.68649826367421150.6666666666666666 0.6730362869995150.6515151515151515 0.64484328938211260.6363636363636364 0.61498063392336210.6212121212121212 0.61498063392336210.6060606060606061 0.59943894617568140.5909090909090909 0.56718575981365350.5757575757575758 0.55050201337006030.5606060606060606 0.53346977817979750.5454545454545454 0.53346977817979750.5303030303030303 0.53346977817979750.5151515151515151 0.53346977817979750.5 0.49844577905278050.48484848484848486 0.48050449096362580.4696969696969697 0.44391286204417190.45454545454545453 0.42533183484818760.4393939393939394 0.42533183484818760.42424242424242425 0.40661214397389090.4090909090909091 0.38779626246936550.3939393939393939 0.38779626246936550.3787878787878788 0.38779626246936550.36363636363636365 0.350060430132954350.3484848484848485 0.350060430132954350.3333333333333333 0.33123946079255810.3181818181818182 0.33123946079255810.30303030303030304 0.33123946079255810.2878787878787879 0.33123946079255810.2727272727272727 0.29395622906528220.25757575757575757 0.239771849085112620.24242424242424243 0.222404952649301130.22727272727272727 0.205480914791937420.21212121212121213 0.15790940346973850.19696969696969696 0.15790940346973850.18181818181818182 0.14328608857153320.16666666666666666 0.129353449756336470.15151515151515152 0.116148328955931880.13636363636363635 0.103701664666399140.12121212121212122 0.103701664666399140.10606060606060606 0.0534481815274281960.09090909090909091 0.0534481815274281960.07575757575757576 0.045809797348004480.06060606060606061 0.032828037357590470.045454545454545456 0.0274236301509087380.030303030303030304 0.0095790823536893360.015151515151515152 h,j,k,l,arrows,drag to pan i,o,+,-,scroll,shift-drag to zoom r,dbl-click to reset c for coordinates ? for help ? 0.0 0.5 1.0 0.00 0.05 0.10 0.15 0.20 0.25 0.30 0.35 0.40 0.45 0.50 0.55 0.60 0.65 0.70 0.75 0.80 0.85 0.90 0.95 1.00 0.000 0.005 0.010 0.015 0.020 0.025 0.030 0.035 0.040 0.045 0.050 0.055 0.060 0.065 0.070 0.075 0.080 0.085 0.090 0.095 0.100 0.105 0.110 0.115 0.120 0.125 0.130 0.135 0.140 0.145 0.150 0.155 0.160 0.165 0.170 0.175 0.180 0.185 0.190 0.195 0.200 0.205 0.210 0.215 0.220 0.225 0.230 0.235 0.240 0.245 0.250 0.255 0.260 0.265 0.270 0.275 0.280 0.285 0.290 0.295 0.300 0.305 0.310 0.315 0.320 0.325 0.330 0.335 0.340 0.345 0.350 0.355 0.360 0.365 0.370 0.375 0.380 0.385 0.390 0.395 0.400 0.405 0.410 0.415 0.420 0.425 0.430 0.435 0.440 0.445 0.450 0.455 0.460 0.465 0.470 0.475 0.480 0.485 0.490 0.495 0.500 0.505 0.510 0.515 0.520 0.525 0.530 0.535 0.540 0.545 0.550 0.555 0.560 0.565 0.570 0.575 0.580 0.585 0.590 0.595 0.600 0.605 0.610 0.615 0.620 0.625 0.630 0.635 0.640 0.645 0.650 0.655 0.660 0.665 0.670 0.675 0.680 0.685 0.690 0.695 0.700 0.705 0.710 0.715 0.720 0.725 0.730 0.735 0.740 0.745 0.750 0.755 0.760 0.765 0.770 0.775 0.780 0.785 0.790 0.795 0.800 0.805 0.810 0.815 0.820 0.825 0.830 0.835 0.840 0.845 0.850 0.855 0.860 0.865 0.870 0.875 0.880 0.885 0.890 0.895 0.900 0.905 0.910 0.915 0.920 0.925 0.930 0.935 0.940 0.945 0.950 0.955 0.960 0.965 0.970 0.975 0.980 0.985 0.990 0.995 1.000 0 1 Empirical Probability Plot

The 100-year return level for the Port Pirie block maxima model is computed with the returnlevel function as follows:

julia> r = returnlevel(fm, 100)ReturnLevel
returnperiod :	100
value :		Vector{Float64}[1]

The return level can be accessed as follows:

julia> r.value1-element Vector{Float64}:
 4.7659672278955645

The corresponding confidence interval can be computed with the cint function:

julia> c = cint(r)1-element Vector{Vector{Real}}:
 [4.574150814798266, 4.957783640992863]