-
-
Save anniejw6/add80c13491832967063998c20b3586d to your computer and use it in GitHub Desktop.
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
require(arm) | |
set.seed(987654321) | |
.tmp=(rnorm(100000, mean=0)) | |
.tmp=invlogit(.tmp) | |
shift_param=.3 | |
par(mfrow=c(1,2)) | |
hist(x=.tmp, main=paste0('Mean=',round(mean(.tmp),3))) | |
hist(x=invlogit(logit(.tmp) + shift_param),main=paste0('Mean=',round(mean(invlogit(logit(.tmp) + shift_param)),3))) | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment