n <- 2500
ease <- rnorm(n, 1, 1)
uslope <- 25*ease + rnorm(n, 0.25, .15)
uintercept <- ease + rnorm(n, 0, .10)
use1 <- uintercept + rnorm(n, 0, .10)
use2 <- uintercept + 1*uslope + rnorm(n, 0, .05)
use3 <- uintercept + 2*uslope + rnorm(n, 0, .10)
use4 <- uintercept + 3*uslope + rnorm(n, 0, .05)

pslope <- ease + rnorm(n, 0.25, .15)
pintercept <- .25*ease + rnorm(n, 0, .10)
use1 <- pintercept + rnorm(n, 0, .10)
use2 <- pintercept + 1*pslope + rnorm(n, 0, .05)
use3 <- pintercept + 2*pslope + rnorm(n, 0, .10)
use4 <- pintercept + 3*pslope + rnorm(n, 0, .05)

data22 <- data.frame(cbind(use1, use2, use3, use4, prof1, prof2, prof3, prof4, ease))

names(data22)=c('use1', 'use2', 'use3', 'use4', 'prof1', 'prof2', 'prof3', 'prof4', 'ease')

write.csv(data22, 'dataset22.csv', row.names=F)
