similar to: grid location on plot

Displaying 20 results from an estimated 10000 matches similar to: "grid location on plot"

2006 Apr 28
2
How to get a grid behind a boxplot
I am using R 2.2.1 on a Windows 2000 PC. When I do a grid() after the boxplot it overprints the boxplot: > boxplot(count ~ spray, data = InsectSprays, col = "lightgray") > grid(nx=NA, ny=NULL) > if I try the panel.first > boxplot(count ~ spray, data = InsectSprays, col = "lightgray", + panel.first=grid(nx=NA, ny=NULL)) > I can see the grid flash
2007 Sep 20
1
help with making a function of scatter plot with multiple variables
Dear list, I have done a scatter plot of multiple variables in the same graph, with different col and pch. I managed to do it with the following code but not know how to make a function of these so that next time if I want to do similar graph but with new variables, I dont have to copy the code and then change the old variables with the new ones but just call a function with the new
2010 Oct 05
2
is there a way to avoid "traveling" grid?
Hello! If you run the whole code below, it'll produce a stacked diagram. And it looks good - because the tick-marks are aligned with the grid. However, if I stretch the graph window, grid becomes misaligned with the tickmarks. Or, rather, it seems aligned for the first and the last tick mark, but not for tickmarks in between. Can it be addressed? Thank you! Dimitri ### Creating a data set
2003 Apr 15
2
troubles with displaying legend on the plot
Dear colleagues, I have troubles while trying to display legend on the plot. I have data.frame fr > fr year M1 M2 1 1979 58.85198 56.77303 2 1980 57.59725 55.93749 3 1981 57.32133 55.55232 4 1982 54.69320 53.10566 5 1983 56.58973 55.03811 6 1984 58.81363 56.97641 7 1985 58.35583 56.82091 8 1986 60.41842 58.45457 9 1987
2013 Nov 19
2
como agrego una linea dibujada con abline() en la leyenda de un grafico ?
Eric Recordé un ejemplo rápido ## Setup up coordinate system (with x == y aspect ratio): plot(c(-2,3), c(-1,5), type = "n", xlab = "x", ylab = "y", asp = 1) ## the x- and y-axis, and an integer grid abline(h = 0, v = 0, col = "gray60") text(1,0, "abline( h = 0 )", col = "gray60", adj = c(0, -.1)) abline(h = -1:5, v = -2:3, col =
1999 Jun 30
1
grid command
I'd like to know if there is a way to plot your stuff and have a grid on the plot, in which the grid falls exactly where it should, i.e. on the axis labels. E.g., if on x axis I have the labels -4,-2,0,2,4 and on y -1,-0.5,0,0.5,1 the command grid(5,5) puts the grid out of place, just on 0 it falls right. Any hint? Thanks Alessandro Magni --
2006 Feb 09
2
nice log-log plots
Dear All, I am trying to produce log-log plots in R and I was wondering if any of you have a 'template' for generating these with 'nice' labels and log-log grids? I know I can set up axes individually and use the intervals I want, however, I will be producing a large number of these plots and would not like to do this manually for each of them + I am very new to R and at the
2012 Feb 03
1
incomplete final line found on <name of my sourced function file>
Dear R-ers, I hope there is a really simple solution to my problem. I've written a function that I saved in an .r file. I source this file in my code. For a while it worked fine. But then when I run the line: source("F mylineplot.r") I started getting a warning: In readLines(file) : incomplete final line found on 'F mylineplot.r' I have no idea why - I tried to check and
2008 Jun 05
2
Y values below the X plot
Dear List, I am creating a plot and I want to insert the tabular data below the X axis. I mean for every value of X I want to show the value in Y as a table below the plot. I think the attached image gives an idea of what I mean by this. Below is the code i am using now... but as you see the Y values don't have the right location. Maybe I should insert them as a table? Any ideas on that.
2013 Nov 19
1
como agrego una linea dibujada con abline() en la leyenda de un grafico ?
Estimado Eric En Hmisc la función labcurve puede ser útil, en todos casos crear una curva con valores constantes, habría que intentar, pero labcurve en algunos ejemplos en mi computadora no anda. Ayer envié dos correos, el primero era de latticeextra, usted nombra lattice, pero podría funcionar, en latticeextra: ## horizontal and vertical lines xyplot(ysim ~ xsim) + layer(panel.ablineq(v
2013 Nov 16
3
como agrego una linea dibujada con abline() en la leyenda de un grafico ?
Estimados, tengo un grafico al que agregue una linea con abline(), este es el codigo ... library(Hmisc) # agregar una linea horizontal con el valor del angulo de contacto del control trellis.device(color = FALSE) xYplot(Cbind(ca.med[,3],ca.med[,5],ca.med[,6])~ca.med[,2], groups=Sol, data=ca.med, xlab=list(label="Concentration (mM)", cex=1.3), ylab=list(label="Contact Angle
2009 Mar 10
1
North Arrow (.png file) on a Map
Hi list. I would like to know how do I insert a North arrow, stored as a png file in my computer, in a map? I found lots of post asking similar things, one of them mentioned the pixmap package. The map was done using map() and shapefiles (the code is below). I’m using the pixmap () and addlogo() functions. Well I can import the png with pixmap() function (I guess, once there’s no error message),
2017 Sep 19
3
Graph f(x) = 1/x
Dear All: good morning I am trying to graph the function y=f(x)=1/x over the interval (-5,5). But I am getting an error message. Please see below. I am getting the error message: *Error in xy.coords(x, y, xlabel, ylabel, log) : * * 'x' and 'y' lengths differ* x x <- seq(-5, 5, 0.01) y < 1/x plot(x,y, type='l', xlim=c(-5, 5), ylim=c(-5, 5), xlab = "x",
2007 Dec 09
1
Setting the grid of a graph of timeseries
I have the following code #################################################################### library(zoo) miedate <- yearmon((2006)+seq(0,23)/12) tab <- zoo(cbind(A = c(79.47, 89.13, 84.86, 75.68, 72.82, 78.87, 93.46, 78.18, 82.46, 77.25, 80.95, 84.39, 81.7, 74.76, 65.29, 60.3, 66.59, 73.19, 92.39, 65.76, 77.45, 74.22, 101.36, 100.01), B = c(77.95, 76.73, 51.2, 51.86, 51.29, 49.45,
2017 Jun 14
2
Plot MArginal distribution in the correct place
Please can you send me some orientation? Many thanks in advance. Only if posible one book o similar example to understand why it is not what I try. El 8 jun. 2017 7:50 PM, "Pedro p?ramo" <percentil101 at gmail.com> escribi?: > Many thanks Jim. > > What I,m trying to show with the fhist plot is the empirical distribution > of the values of the left plot simulation.
2017 Jun 08
0
Plot MArginal distribution in the correct place
Many thanks Jim. What I,m trying to show with the fhist plot is the empirical distribution of the values of the left plot simulation. You say: However, I don't think that this plot illustrates quite what you think it does. Can you give me a clue to try to illustrate better if it is not showing what I believe it shows a better way to show it? Many thanks in advance. El 7 jun. 2017
2012 Feb 12
2
dotplots with error bars
Does anyone have any recommendations for producing dotplots with error bars? Are there packages available for this? I searched far and wide and cannot find a suitable option. I am trying to produce publication-quality figures for my thesis results. Dotplots (Cleveland dotplots) are a much better form of summarizing barchart-type data. It does not appear that any of the main plotting packages in r
2017 Jun 06
2
Plot MArginal distribution in the correct place
Hi all, I have this code, but the marginal distribution plot doesn?t appear aligned with the left plot. I think could be something about layout or par() mar. The code was programmed by me time ago. Can anyone help me to get the marginal distribution on the center (more higher centered) id.txt Could have this code: 05/01/2016;9335,200195 06/01/2016;9197,400391 07/01/2016;9059,299805
2017 Jun 07
2
Plot MArginal distribution in the correct place
Hi Pedro, As a one-off, you just shove the coordinates around a bit: par(mar=c(11,0,6,6)) barplot(fhist$counts,axes=FALSE, space=0,horiz=TRUE,col="lightgray", ylim=c(0,24)) However, I don't think that this plot illustrates quite what you think it does. Jim On Wed, Jun 7, 2017 at 4:01 PM, Pedro p?ramo <percentil101 at gmail.com> wrote: > Please, I'm trying to put
2013 Feb 14
1
fill colour in grid
Dear all r-users,   I have this code below to draw two squares, small and big square.  I would like to colour the small square with red and the big square with blue for example.  I tried using polygon but fail.  Thank you so much for your help.     par(mar=c(4,4,2,1.2),oma=c(0,0,0,0),xaxs="i", yaxs="i") plot.new() plot.window(xlim= c(0,8),