Testing lower Tail GPD Fit

조회 수: 4 (최근 30일)
Carolin Brueckmann
Carolin Brueckmann 2015년 5월 8일
Hi there,
I am trying to adjust the code below to test the fit of my lower tail instead of the upper tail (as the current code does). However, I have problems understanding the meaning of line 2 and 3 in the code. Specifically, I am unsure about the meaning of Q(1), P(1) and P(2) and thus how to change them to model the lower tail.
I would appreciate any hints!
Thanks in advance.
Carolin
%% Testing the GPD Fit _ Upper Tail
for i=1:nIndices
figure [P,Q] = boundary(tails{i}); % cumulative probabilities & quantiles at boundaries y = sort(residuals(residuals(:,i) > Q(2), i) + Q(2)); % sort exceedances plot(y, (cdf(tails{i}, y + Q(2)) - P(1))/P(2)) [F,x] = ecdf(y); % empirical CDF hold on stairs(x, F, 'r') grid on
legend('Fitted Generalized Pareto CDF','Empirical CDF','Location','SouthEast'); xlabel('Exceedance') ylabel('Probability') title('Upper Tail of Standardized Residuals') end

답변 (0개)

카테고리

Help CenterFile Exchange에서 Linear and Nonlinear Regression에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by