[R] 2 questions about probplot in package e1071

David Winsemius dwinsemius at comcast.net
Sat Mar 26 21:11:52 CET 2011


On Mar 26, 2011, at 4:06 PM, Thomas Adams wrote:

> The contributed package e1071 does exactly what I want except that I  
> need to have (1) the abscissa and ordinate axes swapped, with the  
> probability scale on the bottom and the quantiles scale on the LHS.  
> Using the following example:
>
> library(e1071)
> x <- rnorm(100, mean=5)
> probplot(x, line=FALSE)
>
> and (2) I need to have lines connecting the plotted symbols, as you  
> get with:
>
> x<-log(seq(1:20))
> plot(x,type='b')
>
> How can I do these two things; I've done a bunch of searching, but  
> have not come across anything yet.

The code is all there. Just rework it. Type:

probplot

then...

probplot2 <- function(

and paste in your re-worked code that swaps labels,  the x and y  
vectors,  and change axis(1) to axis 2 and axis(2, ...) to  
axis(1,  ...)  a few other swaps like abline(h=...)  to abline(v=...)

-- 

David Winsemius, MD
West Hartford, CT



More information about the R-help mailing list