# I can not draw a 45 degree line on a qqnorm() plot, jj <- sample(c(1:100), 10) qqnorm(jj) abline() don't work. Thank you.
Bill.Venables@csiro.au
2005-Apr-03 06:40 UTC
[R] how to draw a 45 degree line on qqnorm() plot?
You didn't try very hard. Try this, look at it and think about it: jj <- scale(sample(1:100, 10)) qqnorm(jj) abline(0, 1) Rather than abline, however, most people, however, would use qqline(jj) in which case you don't need the scaling. V. -----Original Message----- From: r-help-bounces at stat.math.ethz.ch [mailto:r-help-bounces at stat.math.ethz.ch] On Behalf Of Terry Mu Sent: Sunday, 3 April 2005 4:00 PM To: R-Help Subject: [R] how to draw a 45 degree line on qqnorm() plot? # I can not draw a 45 degree line on a qqnorm() plot, jj <- sample(c(1:100), 10) qqnorm(jj) abline() don't work. Thank you. ______________________________________________ R-help at stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Bill.Venables@csiro.au
2005-Apr-04 00:09 UTC
[R] how to draw a 45 degree line on qqnorm() plot?
Remember this is just a diagnostic procedure and all you are really looking for is whether the normal scores plot is pretty straight. The reason for anchoring the guiding line at the quartiles is really the same reason that boxplots use quartiles for the central chunk. You don't want the guiding line to be influenced by the tails too much. It's a robustness thing. In order for the 45 degree line to be useful, you have to *standardize* your residuals so that they look like *standard* normal residuals (just as the normal scores are standardized). If you do that then the 45 degree line is likely to be useful, but no more so in practice than the usual qqline, which applies irrespective of standardization. Bill Venables. -----Original Message----- From: Terry Mu [mailto:muster at gmail.com] Sent: Sunday, 3 April 2005 6:10 PM To: Venables, Bill (CMIS, Cleveland) Cc: r-help at stat.math.ethz.ch Subject: Re: [R] how to draw a 45 degree line on qqnorm() plot? Thank you. I didn't know scale(). Qqline passes through 1st and 3rd quantiles, It doesn't seem very useful to me. I thought a diagnol line will demonstrate the deviation from a standard normal. Correct me if I was wrong. Thanks. On Apr 3, 2005 2:40 AM, Bill.Venables at csiro.au <Bill.Venables at csiro.au> wrote:> You didn't try very hard. > > Try this, look at it and think about it: > > jj <- scale(sample(1:100, 10)) > qqnorm(jj) > abline(0, 1) > > Rather than abline, however, most people, however, would use > > qqline(jj) > > in which case you don't need the scaling. > > V. > > -----Original Message----- > From: r-help-bounces at stat.math.ethz.ch > [mailto:r-help-bounces at stat.math.ethz.ch] On Behalf Of Terry Mu > Sent: Sunday, 3 April 2005 4:00 PM > To: R-Help > Subject: [R] how to draw a 45 degree line on qqnorm() plot? > > # I can not draw a 45 degree line on a qqnorm() plot, > > jj <- sample(c(1:100), 10) > qqnorm(jj) > > abline() don't work. > Thank you. > > ______________________________________________ > R-help at stat.math.ethz.ch mailing list > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide! > http://www.R-project.org/posting-guide.html >