s-news
[Top] [All Lists]

[S] Getting the axis right for a plot on the log 2 scale

To: "'S-Plus Listserve'" <S-news@wubios.wustl.edu>
Subject: [S] Getting the axis right for a plot on the log 2 scale
From: "Bruden, Dana" <zkg9@cdc.gov>
Date: Mon, 25 Sep 2000 13:01:42 -0400
Sender: owner-s-news@wubios.wustl.edu
Hello All,

I am trying to plot data on the log(2) scale but get my tick mark labels to
label
according to the original scale of the data.  This I have worked out with
the
axes = F option in my plot statement and issueing the axis statement
afterword.
But I would like the "box" that is placed around the data to still be in the
plot.
I don't want just the shortened x and y axis lines that I am getting
issueing the
axis statements after the plot statement.  Thanks in advance for any help!!

Dana Bruden

data<-matrix(scan("h:\\hp2.out"),54,3,T)
graphsheet(orientation="landscape")
log<-matrix(0,108,2)
log[,1]<-log(data[,1],2)
log[,2]<-log(data[,2],2)
plot(x=log[,1],y=log[,2],xlab = "Anaerobic", ylab = "Micro",type = "n" ,axes
= F )
title("Metronidazole MICs" )
lines(x = c(2.8,2.8),y=c(-8,360),col=8, lty = 4)
lines(x=c(-8,360),y=c(2.8,2.8),col =8,lty = 4)
text(log[,1],log[,2],data[,3])
axis(side = 1,at = c(-4,-2,0,2,4,6,8),xaxs = "r",labels =
c("0.06","0.25","1","4","16","64","256"))
axis(side = 2,at = c(-4,-2,0,2,4,6,8),yaxs = "r",labels =
c("0.06","0.25","1","4","16","64","256"))



Dana Bruden
Phone = (907)729-3431
Site = 0034757156
Company: Centers for Disease Control
Area = SAS STAT
Release = 8.00
OS = PC, Win 95
 
Problem:

-----------------------------------------------------------------------
This message was distributed by s-news@wubios.wustl.edu.  To unsubscribe
send e-mail to s-news-request@wubios.wustl.edu with the BODY of the
message:  unsubscribe s-news

<Prev in Thread] Current Thread [Next in Thread>
  • [S] Getting the axis right for a plot on the log 2 scale, Bruden, Dana <=