How to fit the Copula to the data beased on parametric marginal distribution?

Dear Sir/Madam
I am trying to fit the Copula to the data, regarding to the parametric marginal distribution. As I found the way that you introduced in MathWorks is Nonparametric based on finding Kernel;
u = ksdensity(x,x,'function','cdf'); v = ksdensity(y,y,'function','cdf');
But I already found the best distribution of my variables and going to fit with copula. for example my data is as follow:
x = [98.67 310.02 578.90 281.36 134.95 76.9 109.343 79.055 204.417 141.965 263.037 120.186 278.257 539.315 549.6 301.118 363.301 204.276 173.175 511.985 105.95 255.875 724.734 86.8 166.181 165.053 231.291 186.729 140.248 226.472 234.605 361.213 90.186 135.494];
y = [408 552 312 384 360 144 384 168 312 456 360 216 360 384 240 480 192 192 216 264 576 432 192 312 480 600 192 480 240 504 480 360 336 312];
and with the mathematical solution I found the best fitted distribution for X variable is Gen. Pareto and for Y variable is Gen. Extreme Value. So how to joint these two variables with the mentioned best fit distribution and after fit copula .
Regards Mohsen

 채택된 답변

Tom Lane
Tom Lane 2012년 7월 30일
If you have fit the marginals so that you have both the family (such as generalized Pareto) and the parameters, you could use a technique similar to what you see in the example. Use the cdf function for the fitted distribution (such as gpcdf) to produce an array U of values between 0 and 1. Then use copulafit on that. Then afterward, if you want, you can generate random values from the copula and use the fitted distributions icdf function (gpicdf) to transform to the original scale.

댓글 수: 1

I would like to ask a question related to this.
In my case, I have two variables that allow me to think they are distributed under a Normal Distributions, so as you say, I use the normcdf to obtain the array U(0,1), and afterwards use the copulafit on this.
My questions, are two, with this copulafit what I obtained are the parameters of the copula that have this marginals (eg, in the case of a t, the parameters would be the linear correlation and the degrees of freedom). Therefore, the parameters that characterize my copula. Is this right?
On the other hand, how can I choose which Copula fits better with my data, I have to measure the dependence among both variables, so I guess the one which shows me this dependence. How can I do it? is there any way of doing it visually?
Thank you very much.

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

도움말 센터File Exchange에서 Probability Distributions and Hypothesis Tests에 대해 자세히 알아보기

질문:

2012년 7월 29일

댓글:

2014년 9월 19일

Community Treasure Hunt

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

Start Hunting!

Translated by