search for: qqline

Displaying 20 results from an estimated 69 matches for "qqline".

2000 Dec 11
1
qqline (PR#764)
I think qqline does not do exactly what it is advertised to do ("`qqline' adds a line to a normal quantile-quantile plot which passes through the first and third quartiles."). Consider the graph: tmp <- qnorm(ppoints(10)) qqnorm(tmp) qqline(tmp) The line (which I expected go through all the po...
2008 Aug 05
2
qqline function doesn't plot
I have a data vector x. When I try qqline(x) I get the following error: Error in int_abline(a = a, b = b, h = h, v = v, untf = untf, ...) : plot.new has not been called yet And a blank plot appears. Can anybody help? What am I doing wrong? Thanks, Scotty _________________________________________________________________ Contes...
2006 Feb 01
1
Difficulty with qqline in logarithmic context
Hi, R friends. I had some difficulty with the following code: qqnorm(freq, log='y') qqline(freq) as the line drawn was seemingly random. The exact data I used appears below. After wandering a bit within the source code for "abline", I figured out I should rather write: qqnorm(freq, log='y') par(ylog=FALSE) qqline(log10(freq)) par(ylog=TRUE) I'm pr...
2010 Aug 06
1
qqline error: Error in sort.list(x, partial = unique(c(lo, hi))) : 'x' must be atomic for 'sort.list' Have you called 'sort' on a list?
Hi all, I'm modeling using lme in the nlme package. qqnorm makes plots just find, but when I try to add a line with qqline, I get the following error: "Error in sort.list(x, partial = unique(c(lo, hi))) : 'x' must be atomic for 'sort.list' Have you called 'sort' on a list?" For example > modelincr10<-lme(lruin~can.pos.num, data=rwushi30, random=(~1| site/transect/plot),na.acti...
2002 Jan 10
0
Add qqline to plot.lm Q-Q plot?
Dear all, Is there a simple way to add a qqline to the Q-Q plot plot.lm() produces for which = 2? If not, I might write one, but how should this preferably be implemented? Make qqline() generic and add a qqline.lm() method? Add an argument to plot.lm()? Have plot.lm() output something invisibly that qqline() can chew directly? Have plot.lm() o...
2006 Oct 25
1
Drawing a reference line for a qqplot with reference to Weibull distribution
...istribution including a reference line. This is my current code: lights.data <- scan("lights.dat") #Generate Weibull quantiles prob.grid <- ppoints(length(lights.data)) prob.quant <- qweibull(prob.grid , 1.5,4) #Draw QQ plot qqplot(prob.quant,lights.data) #add red reference line qqline(lights.data,col = 2) Obviously the reference line isn't correct this way. How would I go about fitting one? I am grateful for any help, Ben
2011 Apr 30
4
QQ plot for normality testing
Hi all, I am trying to test wheater the distribution of my samples is normal with QQ plot. I have a values of water content in clays in around few hundred samples. Is the code : qqnorm(w) #w being water content qqline(w) sufficient? How do I know when I get the plots which distribution is normal and which is not? Thanks, m [[alternative HTML version deleted]]
2010 May 16
2
Box-Cox Transformation: Drastic differences when varying added constants
...nt Xnew1 = X +abs(min(X))+ .1 box.cox.powers(Xnew1) Xtrans1 = Xnew1^.2682 #(the value of the lambda estimate) # Adding a larger constant Xnew2 = X +abs(min(X)) + 1 box.cox.powers(Xnew2) Xtrans2 = Xnew2^-.2543 #(the value of the lambda estimate) #Plotting it all par(mfrow=c(3,2)) hist(X) qqnorm(X) qqline(X,lty=2) hist(Xtrans1) qqnorm(Xtrans1) qqline(Xtrans1,lty=2) hist(Xtrans2) qqnorm(Xtrans2) qqline(Xtrans2,lty=2) #correlation among original and transformed variables round(cor(cbind(X,Xtrans1,Xtrans2)),2) -- View this message in context: http://r.789695.n4.nabble.com/Box-Cox-T...
2009 Nov 02
7
qqplot
Hi, We could use qqplot to see how two distributions are different from each other. To show better how they are different (departs from the straight line), how is it possible to plot the straight line that goes through them? I am looking for some thing like qqline for qqnorm. I thought of abline but how to determine the slope and intercept? Best wishes, Carol
2011 Jul 25
1
scripting qqplot and qqnorm
Hi all, I am an R newbie, and I have a question about scripting. I have the following lines which I want to put int\ o a script which I can call from the shell of a Mac/Linux machine : myrns <- read.csv(file="/Users/vihan/test.csv",sep="",header=FALSE) qqnorm(myrns) qqline(myrns) This works fine on an interactive R session. However, as I understand the basic framework of an R script for executing on the shell to get a pdf output it is something like : #!/usr/bin/Rscript ? list inputs? pdf("plotexample.pdf", width=7, height=9) plot(...) dev.off() pri...
2000 Sep 21
2
qqnorm(), is it "backwards"?
Hello R friends, I'm wondering why I get funny qqnorm() results. It seems that they should all be reflected in the normal qqline(). For instance: if I qqnorm() bimodal or uniform data I get a sigmoidal in which the qqnorm() points lie above the qqline() at -ve theoretical quantiles, and the qqnorm() points lie below the qqline() at +ve theoretical quantiles. Yet I expect such platykurtic distributions to go the other way (...
2010 Dec 18
3
use of 'apply' for 'hist'
Hi all, ########################################## dof=c(1,2,4,8,16,32) Q5=matrix(rt(100,dof),100,6,T,dimnames=list(NULL,dof)) par(mfrow=c(2,6)) apply(Q5,2,hist) myf=function(x){ qqnorm(x);qqline(x) } apply(Q5,2,myf) ########################################## These looks ok. However, I would like to achieve more. Apart from using a loop, is there are fast way to 'add' the titles to be more informative? that is, in the histograms, I want the titles to be 't distribution with d...
2005 Apr 03
2
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.
2008 Jul 06
1
Backgrounds in Multiple Plots made with "fig"
The following code was adapted from an example Vincent Zoonekynd gave on his web site http://zoonek2.free.fr/UNIX/48_R/03.html: n <- 1000 x <- rnorm(n) qqnorm(x) qqline(x, col="red") op <- par(fig=c(.02,.5,.5,.98), new=TRUE) hist(x, probability=T, col="light blue", xlab="", ylab="", main="", axes=F) lines(density(x), col="red", lwd=2) box() par(op) How can I make the background in the small box i...
2009 Dec 23
2
how to create normal qqplot with the 95% confidence interval
hi everyone! season's greetings! is there any way that i can create a normal qqplot showing, aside from the qqline, the 95% confidence limits? thank you very much.. happy holidays! -- View this message in context: http://n4.nabble.com/how-to-create-normal-qqplot-with-the-95-confidence-interval-tp977727p977727.html Sent from the R help mailing list archive at Nabble.com.
2010 Jun 24
4
Simple qqplot question
...'t step on me if this is too simple. I have two data sets datax and datay for which I created a qqplot qqplot(datax,datay) but now I want a line that indicates the perfect match so that I can see how much the plot diverts from the ideal. This ideal however is not normal, so I think qqnorm and qqline cannot be applied. Perhaps you can help? Ralf
2012 Feb 10
1
Formatting Y axis.
...ime and be an easier more understandable read. Here's sample code to plug in and see. x <- rlnorm(400, 2.3, .8) y <- rlnorm(400, 3, 1.6) plot.new() q1 <- qqnorm(log1p(y)) q2 <- qqnorm(log1p(x)) points( q1, col = "red") points( q2, col = "blue") abline( qqline(log1p(y), col = "red") ) abline( qqline(log1p(x), col = "blue") ) legend( "bottomright", inset = 0.02, title = "Loc_ID", c("Sayincom", "Sayout"), fill = c( "red", "blue"), horiz = TRUE) So what I want is for the y...
2005 Oct 29
1
how to get colnames of a dataframe within a function called by 'apply'
...le string or just the first one.Thus it lacks of a counter that contains the number of the row which is processed. Here is an example code: <---snip---> nv <- function(xno.na) { par.or <- par(mfrow=c(3,3)) qqnorm(xno.na, main="HERE SHOULD BE THE NAME OF THE COLUMN") qqline(xno.na, col="red") par(par.or) print(str(xno.na)) } > temp # just a part of the whole data.frame klarb1 klarb2 abarb laut skla1 skla2 a NA 13.068182 7.5 4 0.5 0.5 b NA 6.818182 9.0 6 NA 0.5 c 15.11628 6.818182 10.0 4 1.0 1.5...
2008 Mar 04
2
paired or one-sample t-Test
...ode One-Sample t-Test dim(data.sub) [1] 10000 140 ##there are 10000 probesets and 140 columns hist(data.sub) ## Histogram. Identify if the probesets are normal distributed q<-rnorm(10000) ##generate 10000 random, normal distributed values qqplot(data.sub,q)) ##Show the plot of the probeset qqline(data.sub,q) ##Show the line going through the plot t.test(data.sub,mu=0) ## One Sample t-test: identify any significant in the probeset When i plot and use histogram, it is showing a nice normal distribution. What i want to do is to use classical paired or one-sample test for each row (10000 rows...
2014 Jul 11
2
outliers (Marta valdes lopez)
...me.without.outs) # Donde # TimeDiff.without.out.rg Son los datos sin outliers utilizando un criterio típico cuando no se sabe la distribución de tus datos # TimeDiff.without.out.norm Son los datos sin outliers asumiendo la normalidad de tus datos qqnorm(time.without.outs$TimeDiff.without.out.rg); qqline(time.without.outs$TimeDiff.without.out.rg, col = 2, lwd = 2) qqnorm(time.without.outs$TimeDiff.without.out.norm); qqline(time.without.outs$TimeDiff.without.out.norm, col = 2, lwd =2) hist(time.without.outs$TimeDiff.without.out.rg) hist(time.without.outs$TimeDiff.without.out.norm) ks.test(x= time$T...