N = 100
x = seq(-0.30, 1.30, len=N)
alpha = 8
ox = expand.grid(x, x)
z = dfrank(ox[,1], ox[,2], alp=alpha)
contour(x, x, matrix(z, N, N))
z = pfrank(ox[,1], ox[,2], alp=alpha)
contour(x, x, matrix(z, N, N))
alpha = exp(4)
plot(r <- rfrank(n=3000, alpha=alpha))
par(mfrow=c(1,2))
hist(r[,1]) # Should be uniform
hist(r[,2]) # Should be uniform
Run the code above in your browser using DataLab