Answer:
> a<-rnorm(20,50,6)
> a
[1] 51.72213 53.09989 59.89221 32.44023 47.59386 33.59892 47.26718 55.61510 47.95505 48.19296 54.46905
[12] 45.78072 57.30045 57.91624 50.83297 52.61790 62.07713 53.75661 49.34651 53.01501
Then we can find the mean and the standard deviation with the following formulas:
> mean(a)
[1] 50.72451
> sqrt(var(a))
[1] 7.470221
Explanation:
For this case first we need to create the sample of size 20 for the following distribution:
![X\sim N(\mu = 50, \sigma =6)](https://img.qammunity.org/2021/formulas/mathematics/college/cgxm05h1golszazwln8pnwl3fvztg42a3u.png)
And we can use the following code: rnorm(20,50,6) and we got this output:
> a<-rnorm(20,50,6)
> a
[1] 51.72213 53.09989 59.89221 32.44023 47.59386 33.59892 47.26718 55.61510 47.95505 48.19296 54.46905
[12] 45.78072 57.30045 57.91624 50.83297 52.61790 62.07713 53.75661 49.34651 53.01501
Then we can find the mean and the standard deviation with the following formulas:
> mean(a)
[1] 50.72451
> sqrt(var(a))
[1] 7.470221