Displaying 20 results from an estimated 367 matches for "yaxt".
Did you mean:
yast
2003 Aug 07
2
plotmath under windows (PR#3672)
...closer to the axis.
Pasting any character (except "") has this effect.
The following code illustrates the problem.
par(mfrow =c(3,2))
# plotmath not used
plot(seq(-41, -40, 0.5), c(0, 1, 0), type = "n", xlab = "latitude", ylab = "",
xaxt = "n", yaxt = "n")
axis(1, at = seq(-41, -40, 0.5),
labels = seq(41 , 40, -0.5))
# plotmath not used but characters pasted into labels
plot(seq(-41, -40, 0.5), c(0, 1, 0), type = "n", xlab = "latitude", ylab = "",
xaxt = "n", yaxt = "n")
axis(1,...
2012 May 12
2
Plotmath bug or my misunderstanding?
...ymbols and regular text in subsequent plotmath expressions.
However, it is unclear to me what specifying cex _within_ the
annotation function using plotmath should do, and the following seems
to want to have it both ways: ignore/obey )or maybe recycle?)
plot(1,type="n", xaxt='n', yaxt='n', ann=FALSE)
text(1,1,labels=expression(atop(sigma,"some text")),cex = 2)
## obeys the cex specification in symbols and text
HOWEVER
plot(1,type="n", xaxt='n', yaxt='n', ann=FALSE)
text(1,1,labels=expression(atop(atop(sigma,"some text"),&...
2008 Jul 24
1
plot.dendrogram xlim/ylim
...gram does not accept xlim or ylim. So I
would like to enable that. In place of the existing code chunk:
xlim <- c(x1 - 1/2, x2 + 1/2)
ylim <- c(0, yTop)
if (horiz) {
xl <- xlim
xlim <- rev(ylim)
ylim <- xl
tmp <- xaxt
xaxt <- yaxt
yaxt <- tmp
}
plot(0, xlim = xlim, ylim = ylim, ......
I propose something like:
function(..., xlim, ylim)
xlim0 <- c(x1 - 1/2, x2 + 1/2)
ylim0 <- c(0, yTop)
if (horiz) {
xl <- xlim0
xlim0 <- rev(ylim0)
ylim <- xl
tmp...
2012 Nov 06
3
Survplot, Y-axis in percent
Hi
I am a new fan of R after getting mad with the graphical functional in SPSS.
I have been able to create a nice looking Kaplan Meyer graph using Survplot
function.
However I have difficulties in turning the y axis to percent instead of the
default 0-1 scale.
Further I have tried the function yaxt="n" without any results. Any help in
this matter will be appreciated.
The code is posted below:
par(mfrow=c(1,1))
fit <- survfit(Surv(revreg$Tcuprev , revreg$Rcup_n_j_n)~revreg$RAceGrp_1Maz)
fit
survplot (fit, col=c("gray1","gray40"), lty=1, lwd = 1,
col.fill=c(&q...
2005 Oct 18
1
A two-part question about box-percentile plots, bpplot(): (1) yaxt="n" doesn't seem to work (2) how to display mean values
Dear List,
I have a two-part question related to bpplot(), a box-percentile plot
function in the Hmisc package.
Take the example given in the Help for bpplot(), for instance.
(1) How does one set but not draw the y-axis? What I did was,
bpplot(... , yaxt="n"), but that apparently does not work (though it
works for boxplot()).
(2) How does one display the mean value of each variable inside each
respective box-percentile box? The following is what I did but to no
avail:
> bpplot(x1, x2, x3)
> points(1:1, mean(x1), pch = "1&quo...
2011 Jul 08
2
Vertical Labels in plot graph - normally working fine but not on this graph
...tried to select the window but it didnt really help.
Many Thanks
Paolo
ExtAvgCWV = rnorm(200)
ExtAvgDemand = rnorm(200)
ExtGasDays = seq(from = as.Date("2010-8-4", "%Y-%m-%d"), along.with =
ExtAvgCWV, by = "days")
plot(ExtAvgCWV, ann=FALSE, xaxt="n", yaxt="n" )
tickplaces <- seq( from = 1, by = 21, to = length(ExtGasDays))
Labels = ExtGasDays[tickplaces]
axis(side =1 , at = tickplaces, labels = Labels)
par(las = 3)
windows()
plot(ExtAvgDemand, ann=FALSE, xaxt="n", yaxt="n" )
#dev.set(which = 4)
axis(side =1 , at =...
2013 Oct 10
1
pairs plot
my data are matrix with 3 numeric columns.
would like to have pairs plot
with scatterplots in the upper
with hist at the diag
and with correlation at the lower.
actually default pairs does almost what I want but looks semi awesome.
Especially, i didn't find out how to remove the axes from the lower
part where I do only want to display the numeric values correlations
there and somehow axes
2008 Apr 08
1
plot function / par() settings
...0.00, 0.50, 0.50, 0.00))
plot(1:5, 1:5, xlab = "", ylab = "", xaxt = "n", col = "blue");
axis(3, at = seq(1:5), labels = rep("", 5))
par(mai = c(0.00, 0.00, 0.50, 0.00))
plot(1:5, 1:5, xlab = "", ylab = "", xaxt = "n", yaxt = "n", col =
"red"); axis(3, at = seq(1:5), labels = seq(1:5))
par(mai = c(0.00, 0.00, 0.50, 0.50))
plot(1:5, 1:5, xlab = "", ylab = "", xaxt = "n", yaxt = "n", col =
"red"); axis(3, at = seq(1:5), labels = rep("", 5))...
2011 Jan 13
3
Rotated, Right-Justified Labels for Shortened Tick Marks
Hello R-help,
I'm trying to make a fairly simple plot axis that goes something like
this:
plot(-10:10,-10:10, yaxt='n')
axis(side=2, las=1, hadj=1, tck=-.01, cex.axis=.6)
...but as you can see, the labels are not close enough to the y-axis
(where I want them... to save space for publication).
Can anybody help me figure out how to move these labels over the the
right a bit?
Thanks,
-D
2011 Jan 18
2
Barplot and line x-axis positions
...having is that the centre of the bars and the points on line don't match up, which is making the whole thing look untidy. I'm wondering if there is a way for me to specify the positions of the centre of each bar on the graph. The code I have is as follows:
xvals <- barplot(wetMeans[,i], yaxt='n', axisnames=F, xlab='', ylab='', main=names[i], border=F, cex.main=0.7)par(new=T)plot(burnMeans[,i], yaxt='n', xlab='', ylab='', type='b', cex=1, pch=16, lty=44, col='black', lwd=1.5)
As you can see I have suppressed the y-axis so t...
2018 May 08
0
Adding Year-Month-Day to X axis
...", "2018-05-02",
> "2018-05-03", "2018-05-04", "2018-05-05", "2018-05-06", "2018-05-07"),
> format="%Y-%m-%d")
> par (mar=c(6,4,4,2))
> plot (x_yyyymmdd, y_duration, type="l", xaxt="n", yaxt="n",
> ylim=range(240,480), xlab="", ylab="", col="blue")
> abline (h=c(240,270,300,330,360,390,420,450,480,510,540), lty=3,
> lwd=1.0, col="grey50")
> axis (side=2, at=240, cex.axis=1.0, label="4:00")
> axis (side=2,...
2018 May 08
1
Adding Year-Month-Day to X axis
...quot;, "2018-05-01", "2018-05-02", "2018-05-03", "2018-05-04", "2018-05-05", "2018-05-06", "2018-05-07", "2018-05-08)"), format="%Y-%m-%d")
plot (x_yyyymmdd, y_duration, type="l", xaxt="n", yaxt="n", ylim=range(240,480), xlab="", ylab="", col="blue")
plot ( y_duration, type="l", xaxt="n", yaxt="n", ylim=range(240,480), xlab="", ylab="", col="red" )
[[alternative HTML version de...
2005 Feb 09
1
Plotting: Plot several axis at right hand side of the plot
...axes on the right hand side of the plot (or leftside).
For the first two time series it axis are plotted but the last two time
series don't have and axis. How can these be added and where?
e.g.
par(mfrow=c(1,1))
plot(timeserie1)
par(new=T)
plot(timeserie2, type="b", col=3,yaxt="n", ylab="" )
axis(4)
mtext(side=4, line=2, "NDVI")
par(new=T)
plot(timeserie3, type="h", col=2,yaxt="n", ylab="")
par(new=T)
plot(timeserie4, type="b", col=4,yaxt="n", ylab="")
Thank...
2011 Feb 16
3
image() with a vector
Hi,
I have a vectors x and z, for example,
x <- 0:20
z <- round(runif(20,1,7))
y <- 0.5
and I want to display z as an image. However if I then call image() with a vector
image(x,y,t(z),zlim=c(1,7),col=heat.colors(7),xlab="Year",ylab="Action",yaxt="n",xaxs="r",yaxs="r")
then I get the error
Error in image.default(x, y, t(z), zlim = c(1, 7), col = heat.colors(7), :
dimensions of z are not length(x)(-1) times length(y)(-1)
However, transforming z into a matrix with two rows, where both rows are the same as...
2012 May 11
2
text(): combine expression and line break
...t some extra text in my plot.
This should be a two line text including a special character (sigma).
I tried so far a to use expression in combination with paste and "\n"...
but I can't get the line break...
Here what I've done so far:
plot(1,type="n", xaxt='n', yaxt='n', ann=FALSE)
text(1,1,labels=expression(paste(sigma,"\n (log scale, m)")),cex = 2)
Maybe someone knows how I can achieve that...
cheers,
/johannes
[[alternative HTML version deleted]]
2005 Feb 21
4
49 histograms on one page
Hi,
I want to do something like this:
par(mfrow=c(7,7))
for (i in 1:49)
hist(RATDACOM[SUBJNO==i],breaks=0.5+(0:6),
main="",xlab="",ylab="",xaxt="n",yaxt="n")
(Don't think about what RATDACOM and SUBJNO are.)
I get an error
Error in plot.new() : Figure margins too large.
36 histograms with mfrow=c(6,6) work.
But the 36 histograms are then so small that I wonder why 49 do not fit.
It seems that though I have main="",xlab=&...
2004 Mar 20
2
labels on axis(4) and adaptation of legend to size of the plot
...2,1))
plot(ts.Origi[,1],ylab='NDII', main=name)
# Add the legend text in the right order
legend.txt <- c("NDII", "Inverse KBDI")
legend(2001.8,0.29, legend.txt,col=c(1,2), lty=1)
par(new=T)
plot(ts.Origi[,2], yaxt="n", type="l", col=2, las=1, ylab="")
axis(4)
plot(ts.NDVIKB[,1],ylab='NDVI', main=name)
# Add the legend text in the right order
legend.txt <- c("NDVI", "Inverse KBDI")
legend(2001.8,0.4...
2010 Feb 08
1
About scales in graphics
...'correct'.
atend = c(410,430,450,408,408,405)
names(atend) = c('Janeiro', 'Fevereiro', 'Mar?o', 'Abril',
'Maio', 'Junho')
barplot(atend, las=1, xlab='Meses', ylab='N?mero de
atendimentos',
col='LightYellow', yaxt='n', space=0.6)
axis(2, at=seq(0,450, by=50), las=1)
abline(h=0, col='black', lwd=1)
How should I do to get the second graph in the range 400 and
Y in the columns with values below 400 do not appear on the
chart?
atend = c(410,430,450,408,408,405)
names(atend) = c('Janeiro...
2012 Aug 22
3
Barplot with Secondary axis
...e help me.
I am pasting the code as follows.
x = c("a","b","c","d")
y= cbind(c(50,40,30,20),c(40,30,20,10))
y2 = c(0.80,0.65,0.75,0.50)
barplot(t(y),beside = TRUE)
par(new=T)
plot(y2,,,type="o",col="black",lwd=
3,lty=1,xaxt="n",yaxt="n",xlab="",ylab="")
points(y2,pch=20)
I also tried following code for plotting the line point exactly at the
center of two bars:
x = c("a","b","c","d")
y= cbind(c(50,40,30,20),c(40,30,20,10))
y2 = c(0.80,0.65,0.75,0.50)
bar...
2013 Feb 14
5
plot custom x axis ticks values
Readers,
For this data set:
testvalues<-c(10,20,30,40)
How to amend the plot instruction:
plot(testvalues,ann=FALSE,type='l',yaxt='n',xaxt='n')
so that x axis ticks labels can be added to existing graph with
arbitrary value such as 0,100,200,300)?
Thanks in advance.
--
r2151