Question: Explain the following piece of code. Write the code in your computer and run it . After running the code, explain what the code illustrate.

Explain the following piece of code. Write the code in your computer and run it. After running the code, explain what the code illustrate.
rm(list=ls())
set.seed(1)
y <- rnorm(10000,2.5,1)
hist(y, freq = FALSE, col = "darkgray", ylim = c(0,0.4), xlim = c(-2,6))
curve(dnorm(x,2.5,1), col ="darkblue", n=8129, lwd =2, add = TRUE)

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!