simcompositeCOP | R Documentation |
Simulate copula parameters and compute L-comoments and provision for plotting features for a composited copula using using two compositing parameters (see composite1COP
as well as composite2COP
). The compositing parameters are each independent and uniformly distributed:
\alpha \sim \mathrm{U}[0,1];\ \beta \sim \mathrm{U}[0,1]\mbox{.}
L-comoment estimation is provided by the lcomCOP
.
simcompositeCOP(nsim=100, compositor=composite2COP,
parents=NULL, ploton=FALSE, points=FALSE,
showpar=FALSE, showresults=FALSE, digits=6, ...)
nsim |
Number of simulations to perform; |
compositor |
The compositing function, could be either |
parents |
A special parameter |
ploton |
A logical to toggle on intermediate plotting; |
points |
A logical to actually draw the simulations on the |
showpar |
Print the simulated parameter set with each iteration; |
showresults |
Print the results (useful if harvest results from a batch operation in R); |
digits |
The number digits to pass to |
... |
Additional arguments to pass. |
An R matrix of results is returned. Each row represents a single simulation run. The first two columns are the \alpha
and \beta
compositing parameters and are labeled as such. The next two columns are the opposing diagonals, by first row and then second, of the L-comoment correlation. The following two columns are the opposing diagonals, by row and then second, of the L-coskew. The following two columns are the opposing diagonals, by row and then second, of the L-cokurtosis. The L-comoment columns are labeled to reflect the L-comoment matrix: T2.21
means the L-comoment correlation row 2 column 1 and T3.12
mean the L-coskew row 1 column 2. The remaining columns represent the \Theta_n
parameters for copula 1, the \Theta_m
parameters for copula 2. The columns are labeled Cop1Thetas
or Cop2Thetas
.
The following descriptions list in detail the parents
argument structure and content of the para
argument:
cop1
— Function of the first copula;
cop2
— Function of the second copula;
para1gen
— Function to generate random parameters for the first copula; and
para2gen
— Function to generate random parameters for the second copula.
The para
argument of this function are passed to the function contained in compositor
and are therefore subject to further constraints in items should such constraints exist.
W.H. Asquith
Asquith, W.H., 2011, Distributional analysis with L-moment statistics using the R environment for statistical computing: Createspace Independent Publishing Platform, ISBN 978–146350841–8.
lcomCOP
, simcomposite3COP
## Not run:
# A single simulation result.
mainpara <- list(cop1=PLACKETTcop, cop2=PLACKETTcop,
para1gen=function() { return(c(10^runif(1,min=-5,max=0))) },
para2gen=function() { return(c(10^runif(1,min= 0,max=5))) })
v <- simcompositeCOP(nsim=1, parent=mainpara, showresults=TRUE)
print(v) # for review
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.