# \donttest{
# Tests on the functional toy fct 'Arctangent temporal function'
y0 <- atantemp.fun(matrix(c(-7,0,7,-7,0,7),ncol=2))
#plot(y0[1,],type="l")
#apply(y0,1,lines)
n <- 100
X <- matrix(c(runif(2*n,-7,7)),ncol=2)
y <- atantemp.fun(X)
plot(y0[2,],ylim=c(-2,2),type="l")
apply(y,1,lines)
# Sobol indices computations
n <- 1000
X1 <- data.frame(matrix(runif(2*n,-7,7), nrow = n))
X2 <- data.frame(matrix(runif(2*n,-7,7), nrow = n))
sa <- sobolMultOut(model=atantemp.fun, q=100, X1, X2,
MCmethod="soboljansen", ubiquitous=TRUE)
print(sa)
plot(sa)
plotMultOut(sa)
library(ggplot2)
ggplot(sa)
# }
Run the code above in your browser using DataLab