Created
July 29, 2021 14:03
-
-
Save CnrLwlss/8cf45c43630e5c381ee89baa368133a1 to your computer and use it in GitHub Desktop.
Visual representation of difference between stochastic process and samples from random distribution
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
N=10000 | |
noise = rnorm(N,mean=0,sd=0.5) | |
random_walk=cumsum(noise) | |
ylim = range(random_walk) | |
op = par(mfrow=c(1,2)) | |
plot(noise,type="l",ylim=ylim,xlab="time",cex.lab=1.75,cex.axis=1.75) | |
plot(random_walk,type="l",ylim=ylim,xlab="time",cex.lab=1.75,cex.axis=1.75) | |
par(op) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment