Advertisement
Guest User

Untitled

a guest
Jun 17th, 2019
58
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.90 KB | None | 0 0
  1. Matrix <- matrix(c(4, 3, 2, 1,
  2. 0, 3, 2, 1,
  3. 0, 0, 2, 1,
  4. 0, 0, 0, 1), 4, 4)
  5.  
  6. returns <- cbind(stock1, stock2, stock3, stock4)
  7.  
  8. selectedCopula <- RVineCopSelect(pobs(as.matrix(returns)), Matrix = Matrix, familyset = NA)
  9. selectedCopula
  10.  
  11. C-vine copula with the following pair-copulas:
  12. Tree 1:
  13. 1,4 t (par = 0.35, par2 = 4.89, tau = 0.23)
  14. 1,3 Gaussian (par = 0.53, tau = 0.36)
  15. 1,2 BB8 (par = 1.78, par2 = 0.86, tau = 0.19)
  16. Tree 2:
  17. 2,4;1 Tawn type 1 (par = 3.04, par2 = 0.01, tau = 0.01)
  18. 2,3;1 BB8 (par = 4.61, par2 = 0.84, tau = 0.54)
  19. Tree 3:
  20. 3,4;2,1 Rotated Tawn type 1 180 degrees (par = 11.06, par2 = 0, tau = 0)
  21.  
  22. copula_dist14
  23. sim14
  24. copula_dist13
  25. sim13
  26. copula_dist12
  27. sim12
  28.  
  29. selectedCopula124 <- BiCopSelect(sim12,sim14,familyset=NA)
  30. selectedCopula124
  31.  
  32. Error:
  33. In BiCopSelect: Data have to be in the interval [0,1].
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement