Displaying 20 results from an estimated 5516 matches for "axi".
Did you mean:
api
2008 May 02
1
axis 1 and axis 2 margin
Hi,
I am using axis() to plot axis 1 and axis 2. but now when I used
axis(side=1,....) and axis(side=2,.....), there's a big margin between these
two axis. does anybody have any idea about how to shrink the margin between
these two axis. basically, I want to move axis 1 left so that when I plot
axis 3, the margi...
2008 Apr 07
3
Overriding axis formatting with custom Axis method, Axis.numeric etc
...ar list:
I would like to override the default way R formats plot axes with a
custom method(s). Obviously I would prefer to define it as general as
possible avoiding writing a custom method for each individual class
where possible.
The plot.default method (and I assume other methods as well) calls
Axis(...) to produce the axis layout depending on data. In this sense it
seems reasonable to (re)define Axis methods rather than change plot
methods (which are impossible to control as there can be too many custom
ones).
Now my question is how can I redefine Axis that it is automatically
called by plo...
2008 Apr 22
1
graphics::Axis loosing S3/S4 class attributes of 'x' in 2.7.0 RC
Following my previous post on S3 method despatch, I put debug messages
in the code of Axis, Axis.default and plot.default in graphics/R/axis.R
and graphics/R/plot.R to print the class of x, at and y on plot. After
recompiling R, what I see is that x *lost* its class attribute (at least
for classes not known to 'graphics') in Axis, called directly from
plot.default and this could...
2009 Oct 13
2
axis labels
Dear list,
why does the distance between the axis labels and the tick marks looks
different for x axis and y axis in the plot (see code below).
In fact, the x axis labels look furthest from the tickmarks than in the y
axis.
How can I make them look the same?
par(mfrow=c(1,1), cex.axis = 0.5, cex.lab = 0.5)
plot(1,1, axes = F)
axis(1)
axis(2)
T...
2005 Mar 30
1
Finding the "height of a line of text" for axis
I would like to draw only the ticks of an axis, but not the axis
itself. I don't think this can be done using axis(), so I am trying to
write a cut-down version in R, which only draws ticks.
The point at which I am stuck is that the length of a tick is set by
par("tcl") as a fraction of the "height of a line of text"....
2023 Nov 24
1
ggplot adjust two y-axis
Hi,
Just find a scaling factor that would make the two sets of data comparable.
Here I divided the second row by 5 and did the same for the second axis.
Charles-?douard
F1 <- as.table(matrix(c(50,11,6,17,16,3,1,2237,611,403,240,280,0,0), 2,7))
barplot(F1, beside = TRUE, col = c("blue", "grey")) axis(2,
at=c(0,10,20,30,40,50,60, labels=c(0,10,20,30,40,50,60))) axis(4, at =
c(0,500,1000,1500,2000,2500), labels =
c(0,500,1000...
2010 Jun 18
1
ggplot2 boxplot: horizontal, univariate
In ggplot2, I would like to make a boxplot that has the following properties:
(1) Contrary to default, the meaningful axis should be the horizontal axis.
Lattice does this, for instance, by
library(lattice);bwplot(~mtcars$mpg)
(2) It is *univariate*, i.e., of a single vector, say mtcars$mpg. I do not wish to make separate plots for the different values of mtcars$cyl.
(3) Nothing on the meaningless axis--the axis...
2009 Nov 05
2
annotating time axis by axis.POSIXct
Dear all
I try to format labels on axis as standard ones does not look well, but I
am not able to make axis.POSIXct to work. here is an example
x<-seq(as.Date("2008-1-1"), as.Date("2009-9-6"), by="2 months")
y<-rnorm(11)
plot(x,y) #not very sophisticated axis
plot(x,y, axes=F)
axis(2)
axis.POSIXct(...
2023 Nov 24
1
ggplot adjust two y-axis
Dear Charles-Edouard
Thanks a lot. Yes indeed barplot sounds excellent.
Unfortunately, the scale of the smaller axis is fixed, even If I am able to
draw to axes. The idea is to expand the scale to the scale to the second
axis for comparison.
F1 <- as.table(matrix(c(50,11,6,17,16,3,1,2237,611,403,240,280,0,0), 2,7))
barplot(F1, beside = TRUE, col = c("blue", "grey"))
axis(2, at=c(0,10,20...
2010 Aug 24
4
how to plot y-axis on the right of x-axis
Dear List,
I have a richness data distributing across 20 N to 20 S latitude. (120 E-140
E longitude).
I would like to draw the richness in the north hemisphere and a regression
line in the plot
(x-axis: latitude, y-axis: richness in the north hemisphere).
The above demand is done using plot.
Then, south hemisphere richness and regression are required to be generated
using
the same y-axis above but an x-axis on the left side of the y-axis.
(The higher latitude in the south hemisphere, the left i...
2018 May 07
2
Adding Year-Month-Day to X axis
Jim,
Thank you very much!
How do I use the axis command for side=1 to label the x horizontal axis, in the format="%Y-%m-%d? style?
Greg
y_duration <- c (301.59050, 387.35700, 365.64366, 317.26150, 321.71883, 342.44950, 318.95350, 322.33233, 330.60333, 428.99516, 297.82066, 258.23166)
x_yyyymmdd <-as.Date(c ("2018-04-...
2008 Aug 06
4
defining the distance between axis label and axis
Hi,
How can I make the distance between an axis-label and the axis bigger?
I haven't found anything in par()...
2009 Oct 07
2
Second y-axis --- alternative to par(new=
Hi
is there an alternative to par(new), for ading data to a plot for a
different y-axis?
My problem with par(new=TRUE) is, that it re-defines all axis and labels (as
in example 1) and one has to use xlim=... to fix the x-axis.
I am looking for something, which simply resets the y-axis, so that a new
plot() (or points()/lines()) keeps the x-axis, but re-defines the y-axis.
Is there s...
2012 May 18
3
How to create axis y axis for horizontal bar plot?
Hi,
i am working on bar plot but i need to generate y axis for horizontal bar
plot. In the attached diagram x-axis is there with scale 0 to 12 but i need
y axis. How can i implement it?
http://r.789695.n4.nabble.com/file/n4630478/barplot2.jpg
Thanks
--
View this message in context: http://r.789695.n4.nabble.com/How-to-create-axis-y-axis-for-horizont...
2012 May 10
4
additional axis, different scale
Dear list,
I am looking for a possibility to present results in a more graphical way by
adding an axis. But I have trouble relating my data to the added axis.
Imagine the following example:
a <- c(10, 20, 30, 40)
b <- c(50, 250, 500, 600)
ba <- b/a
par(las=1, mar=c(5,5,.5,5))
plot(a,b, type="b", pch=22, cex=2, col=4, lwd=2, ylim=c(0,650),
xlim=c(0,45))
axis(4, at=c(seq(...
2012 Mar 08
1
Warnings when plotting after x11() in R 2.14.2
Dear R-help,
I recently upgraded from R 2.13.1 to R 2.14.2 and now get warning
messages when plotting after using x11(). Example:
> plot(rnorm(10)) ### no warnings
> x11(); plot(rnorm(10))
Warning messages:
1: In axis(side = side, at = at, labels = labels, ...) :
Font family not found in Windows font database
2: In axis(side = side, at = at, labels = labels, ...) :
Font family not found in Windows font database
3: In axis(side = side, at = at, labels = labels, ...) :
Font family not found in Windows font...
2023 Nov 24
1
ggplot adjust two y-axis
Hi,
I don't know the axis mecanism well enough in ggplot but using the original
barplot function you can add an axis on the right using the axis function.
Here is an example:
test <- as.table(matrix(c(2,10,3,11), 2,2))
barplot(test, beside = TRUE, col = scales::brewer_pal(palette = 1)(2))
axis(4, at = c(0, 5, 10), l...
2009 Aug 19
0
font size on graphics
...nt size for graphics.
For this i had written a code that creats 4 diferent graphics and saves
them as a png file.
>From these PNG.graphics , i select one of the proper size and past it to a
word document.
I have experimented with lots of settings yet:nd lost my track a bit.
there are cex; cexaxis cexlabes and so on, i lost track of wich cex does
what exactly.
Fruthermore, these graphs work well in an R window, yet when i open the
png file it did not print the labels of bottom x axis.
One other problem i have is that often '10' on the botom x axis is not
printed.
I tried to pat...
2009 Aug 19
0
font size on graphics question (correction in example,sorry)
...nt size for graphics.
For this i had written a code that creats 4 diferent graphics and saves
them as a png file.
>From these PNG.graphics , i select one of the proper size and past it to a
word document.
I have experimented with lots of settings yet:nd lost my track a bit.
there are cex; cexaxis cexlabes and so on, i lost track of wich cex does
what exactly.
Fruthermore, these graphs work well in an R window, yet when i open the
png file it did not print the labels of bottom x axis.
One other problem i have is that often '10' on the botom x axis is not
printed.
I tried to pat...
2009 Jun 17
3
lattice: axis ticks, axis alignment and remove axis from plot
Hi there,
I'm a bit confused concerning the axis tck setting in the lattice
package as the ticks on left sided axis aren't
drawn at all with the following setting:
dados <- data.frame(varsep = factor(rep(1:2,10)),
i = runif(20))
library(lattice)
my.theme <- list(
axis.components = list(left = list(tck = 1...