Loss Simulator Copula Implementation

Frequences defined among lines are correlated using Copula, so are the severities defined among types. Here is a sample workflow of how the Copula concept works in the simulatior.
1. Suppose we have 3 line of businesses, and their severity distributions are defined as :
a. Normal, mean = 0, sd =2
b. Weibull, shape=1,  scale=1
c. Exponential, rate=2
2. Their correlation matrix (in this case, will be Spearman's Rank) is defined as:
1.0      0.5      0.6
0.5      1.0      0.7
0.6      0.7      1.0
3. Suppose user chooses Normal Copula, then the simulator will first compile a Copula object as:
norm.cop <- normalCopula(c(0.5, 0.6, 0.7), dim = 3, dispstr = "un")
4. Then the simulator will construct a multivariate distribution whose marginals are normal, weibull  and exponential respectively, coupled together via a normal copula
x <- mvdc(norm.cop , c("norm", "weibull", "exp"),
          list(list(mean = 0, sd =2),
               list(shape=1, scale=1),
               list(rate = 2)))
5. Now we are simulation ready. x is the object we are going to play with. Suppose we run 5 rounds of simulation
x.samp <- rmvdc(x,  5)
and we will get the simulation result:
           [,1]            [,2]                 [,3]
[1,] -2.4575032    0.0684356    0.4784972
[2,]  0.8593980    0.7897200    0.4010221
[3,]  1.1040019    2.5641807    0.5657534
[4,]  1.3296591    3.9504058    2.0023461
[5,] -0.4770918    1.2985012    1.3659516