Created
April 8, 2020 10:27
-
-
Save timcdlucas/e5ca6a782a3d051fc05eab1538079ee2 to your computer and use it in GitHub Desktop.
look at seeds
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
norm <- rep(NA, 1e4) | |
unif <- rep(NA, 1e4) | |
for(i in seq(1e4)){ | |
set.seed(i) | |
norm[i] <- rnorm(1) | |
set.seed(i) | |
unif[i] <- runif(1) | |
} | |
d <- data.frame(norm = norm, unif = unif) | |
which.max(unif) | |
which.min(unif) | |
unif[which.max(unif)] | |
unif[which.min(unif)] | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment