# 2.6 2.7 2.8 2.9 3.0 # Let's make a vector of the values the function takes given those Z-scores. Let me show you what I mean by graphing the pdf of the normal distribution with dnorm. # above, since mean = 0 and sd = 0 are the default arguments for the dnormĭnorm(0) # 0.3989423 # Another exmaple of dnorm where parameters have been changed.ĭnorm(2, mean = 5, sd = 3) # 0.08065691Īlthough \(x\) represents the independent variable of the pdf for the normal distribution, it’s also useful to think of \(x\) as a Z-score. The dnorm function takes three main arguments, as do all of theĭnorm(0, mean = 0, sd = 1) # 0.3989423 # The line of code below does the same thing as the same as the line of code # This is the same as computing the pdf of the normal with x = 0, mu = 0 and Anything I write after the octothorpe is not executed. Some examples of using dnorm are below: # This is a comment. The function dnorm returns the value of the probability density function for the normal distribution given parameters for \(x\), \(\mu\), and \(\sigma\). As we all know the probability density for the normal distribution is:į(x|\mu,\sigma) = \frac
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |