# NOT RUN {
## 1.EXAMPLE
## Dataset
data <- data.frame(X = rnorm(100), Y = rexp(100))
## Joint function
dim <- c(3,2)
param <- parametersJointMoTBF(data, dimensions = dim)
P <- jointMoTBF(param)
density <- as.function(P)(data[,1], data[,2])
density
## Log-likelihood
sum(log(density))
#############################################################################
## MORE EXAMPLES ############################################################
#############################################################################
# }
# NOT RUN {
## Dataset
data <- data.frame(X = rnorm(100), Y = rexp(100), Z = rnorm(100))
## Joint function
dim <- c(2,3,4)
param <- parametersJointMoTBF(data, dimensions = dim)
P <- jointMoTBF(param)
density <- as.function(P)(data[,1], data[,2], data[,3])
density
## Log-likelihood
sum(log(density))
# }
Run the code above in your browser using DataLab