R2DVine(VineCopula)
R2DVine()所属R语言包:VineCopula
Transform R-vine to D-vine structure
变换R-D-葡萄树结构的藤
译者:生物统计家园网 机器人LoveR
描述----------Description----------
This function transforms an R-vine matrix structure to the corresponding D-vine structure as used in the package CDVine.
此函数变换到相应的D-葡萄树结构的R-藤矩阵结构中所用的包CDVine。
用法----------Usage----------
R2DVine(RVM)
参数----------Arguments----------
参数:RVM
An RVineMatrix object.
RVineMatrix对象。
值----------Value----------
参数:order
A d-dimensional vector specifying the order of the nodes in the D-vine.
甲d维矢量指定的顺序为D-葡萄树中的节点。
参数:family
A d*(d-1)/2 vector of pair-copula families with values<br> 0 = independence copula <br> 1 = Gaussian copula <br> 2 = Student t copula (t-copula) <br> 3 = Clayton copula <br> 4 = Gumbel copula <br> 5 = Frank copula <br> 6 = Joe copula <br> 7 = BB1 copula <br> 8 = BB6 copula <br> 9 = BB7 copula <br> 10 = BB8 copula <br> 13 = rotated Clayton copula (180 degrees; “survival Clayton”) <br> 14 = rotated Gumbel copula (180 degrees; “survival Gumbel”) <br> 16 = rotated Joe copula (180 degrees; “survival Joe”) <br> 17 = rotated BB1 copula (180 degrees; “survival BB1”)<br> 18 = rotated BB6 copula (180 degrees; “survival BB6”)<br> 19 = rotated BB7 copula (180 degrees; “survival BB7”)<br> 20 = rotated BB8 copula (180 degrees; “survival BB8”)<br> 23 = rotated Clayton copula (90 degrees) <br> 24 = rotated Gumbel copula (90 degrees) <br> 26 = rotated Joe copula (90 degrees) <br> 27 = rotated BB1 copula (90 degrees) <br> 28 = rotated BB6 copula (90 degrees) <br> 29 = rotated BB7 copula (90 degrees) <br> 30 = rotated BB8 copula (90 degrees) <br> 33 = rotated Clayton copula (270 degrees) <br> 34 = rotated Gumbel copula (270 degrees) <br> 36 = rotated Joe copula (270 degrees) <br> 37 = rotated BB1 copula (270 degrees) <br> 38 = rotated BB6 copula (270 degrees) <br> 39 = rotated BB7 copula (270 degrees) <br> 40 = rotated BB8 copula (270 degrees)
A D *(D-1)/ 2个向量对Copula的家庭,价值观<BR>0=独立Copula的参考1=高斯系词参考的2=学生参考3=克莱顿系词参考4= Gumbel分布Copula的参考5=弗兰克·系词参考6=乔吨系词(T-Copula函数)系词参考7= BB1 Copula的参考8= BB6 Copula的参考9= BB7系词参考10= BB8 Copula的参考 X> =旋转克莱顿系词(180度;“生存克莱顿”)的参考13=旋转(180度“生存冈贝尔”)Gumbel分布Copula的参考14=旋转乔Copula的参考16=旋转(180度;“BB1生存”)BB1 Copula的参考17=旋转BB6 Copula函数(180度(180度;“生存乔”);“生存BB6)参考18=旋转BB7系词(180度“生存BB7”)参考19=旋转BB8系词(180度“生存BB8”)< BR> 20=旋转克莱顿系词(90度)参考23=旋转冈贝尔系词(90度)参考24 =旋转乔系词(90度)参考26=旋转(90度)BB1 Copula的参考27=旋转BB6 Copula函数(90度)参考28=旋转BB7系词(90度)参考< x> =旋转BB8系词(90度)参考29=旋转克莱顿系词(270度)参考30=旋转(270度)Gumbel分布Copula的参考33 =系词(270度)旋转乔参考34=旋转BB1 Copula函数(270度)参考36=旋转BB6 Copula函数(270度)参考37=旋转BB7系词(270度)参考38=旋转BB8系词(270度)
参数:par
A d*(d-1)/2 vector of pair-copula parameters.
A D *(D-1)/ 2矢量的对Copula函数的参数。
参数:par2
A d*(d-1)/2 vector of second pair-copula parameters for the t-, BB1, BB6, BB7 and BB8 copulas.
A D *(D-1)/ 2矢量T-BB1,BB6,BB7和BB8 Copula函数的第二对Copula函数的参数。
注意----------Note----------
When using this function, one should be sure that the input RVineMatrix object has a D-vine structure, otherwise the transformation function returns an error.
使用此功能时,应确保输入RVineMatrix对象有一个D-葡萄树的结构,否则转换函数返回一个错误。
(作者)----------Author(s)----------
Eike Brechmann
参见----------See Also----------
RVineMatrix, D2RVine, R2CVine
RVineMatrix,D2RVine,R2CVine
实例----------Examples----------
# simulate a sample of size 500 from a 4-dimensional D-vine [模拟一个4维D-葡萄树的样本尺寸500]
# copula model with mixed pair-copulas[混双Copula函数copula模型]
# load package CDVine[加载包CDVine]
library(CDVine)
d = 4
dd = d*(d-1)/2
order = 1:d
family = c(1,2,3,4,7,3)
par = c(0.5,0.4,2,1.5,1.2,1.5)
par2 = c(0,5,0,0,2,0)
type = 2
simdata = CDVineSim(500,family,par,par2,type)
# determine log-likelihood[确定对数似然]
out = CDVineLogLik(simdata,family,par,par2,type)
out$loglik
# transform to R-vine matrix notation[转换到R-藤矩阵符号]
RVM = D2RVine(order,family,par,par2)
# check that log-likelihood stays the same[对数似然保持不变]
out2 = RVineLogLik(simdata,RVM)
out2$loglik
# ... and back[...和背部]
Dvine = R2DVine(RVM)
out3 = CDVineLogLik(simdata[,Dvine$order],Dvine$family,
Dvine$par,Dvine$par2,type)
out3$loglik
转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。
注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
|