For this week's homework, we will revisit some old homework problems. But this time we'll use R to solve them (you must
-
answerhappygod
- Site Admin
- Posts: 899604
- Joined: Mon Aug 02, 2021 8:13 am
For this week's homework, we will revisit some old homework problems. But this time we'll use R to solve them (you must
For this week's homework, we will revisit some old homework problems. But this time we'll use R to solve them (you must use R to do problems 1 - 5). We'll also collect a little data in class. 1) Find the following probabilities: a) Pr{Z<4.72) b) Pr{Z> 1.326348) c) Pr{-1.31 <<<1.31} d) Pr{-1.35 <Z<0.9378} e) Pr{Z<-1.31 or Z> 1.31} (you want the probability outside the range -1.31 to 1.31) (Hint: you can use the answer from (c) to help you with this) To get probabilities (areas) in R, you can do the following from the command line: To get, for example, the Pr{Z< 1.90}, you can do: pnorm (1.90) (R should return 0.9712834) You can also, of course, do simple subtractions in R. For example, to get Pr{-1.90<Z<1.90} you could do: pnorm (1.90) - pnorm(-1.90) To get z values in R (technically, “quantiles”), you can do the following from the command line: To get the 2 for which corresponds to 90% of the area in the lower tail, (i.e., to get z in Pr{Z<=} = .90, do: qnorm (.90) R should return 1.281552 (In other words, if z = 1.281552, then 90% of the area under the normal curve will be less than 2) Be prepared to show your R-printout if asked.
Join a community of subject matter experts. Register for FREE to view solutions, replies, and use search function. Request answer by replying!