similar to: Strange behaviour

Displaying 20 results from an estimated 10000 matches similar to: "Strange behaviour"

2006 Aug 01
1
R crashes using pdf() windows() or postscript()
Dear HelpeRs, I have a script where I save several thousands of graphics. These are then used in Latex through Sweave. Unfortunately R crashes while making these plots and Windows pops up some message that I run low on virtual memory. I tried to save the plots using pdf(), windows() and postscript() and also tried to run it with R CMD BATCH myscript.R. But after a while R slows down and crashes
2001 Jul 25
2
pch with plot and legend
I'm trying to plot a scatterplot of two variables using pch to plot different characters based on a third factor. Here is my example > data("ToothGrowth") > attach(ToothGrowth) > levels(supp) [1] "OJ" "VC" > plot(len ~ dose,pch=as.numeric(supp)) > legend(locator(1),pch=as.numeric(supp),legend=levels(supp)) The command as.numeric(supp) returns 2 2
2007 Dec 06
3
Defaults for postscript()
The defaults for postscript() paper = "default" onefile = TRUE horizontal = TRUE (it seems) date from the days when people used to used this to send plots directly to a postscript printer via print.it=TRUE. I haven't done that for years, and it seems that our current generation of students don't even know the concept. It seems 'horizontal = TRUE' is particularly
2007 Oct 24
1
Rotated viewports in Grid
Hi all, I'm trying to generate a plot containing a scatterplot, with marginal densityplots for x and y. However, when I try to generate a vertical densityplot, I get the message "warning: can't clip to rotated viewport", and nothing shows up. I'm probably misunderstanding how viewports are meant to be used, so if someone could give me a hint, I'd be most grateful. my
2003 Oct 14
5
Organized examples for newbyes
I'm learning R from scratch on my linux box, being deeply biased at work by those graphical programs, nice to look but often poor in content and almost generally limited, running under M$ Windows. I wonder if someone out there can suggest to an absolute beginner as I am where to find a collection of examples of R-code (or Splus, as I understand) to play with in order to learn R quicker. The
2008 May 28
2
Gantt chart like graphics
Dear R Community, I have a dataframe like this dat product1 product2 ... productn 01.1.2008 1 1 1 02.1.2008 1 1 2 . 15.2.2008 2 2 NA . 04.4.2008 2 2 1 05.4.2008 NA 2 NA (date ascending order, 1:n products with status 1, 2 or NA) and want to produce a graphic like
2004 Sep 23
1
Gridbase basic question
All, I have a simple plot(x,y) and I would like to then insert rectangles of some length (in native coordinates) and height fixed to 0.5 in native coordinates. I can't quite get the code right to do this. Can anyone give me a quick example of how to do this? I looked the gridBase index and the tutorial (from R-news?) but just haven't gotten it down yet. > plot(1:10,1:10)
2005 Sep 23
2
Strange behaviour of as.Date function
Dear All, I'm happily extracting data of temperature from an oracle db under R via RODBC. After manipulating the extracted data I put them into a data.frame 'dati' which is as follows: > dati DATA tm. UDINE/RIVOLTO tm.TORINO/CASELLE 1 2005-07-01 22.35 23.80 2 2005-07-02 22.70 22.85 3 2005-07-03 23.80
2012 Sep 23
1
Background color in a grid plot seems to interfere with plot()
Hi, Why does the upper left panel (in the plot below) not have a gray background? Cheers, Marius require(grid) require(gridBase) pdf(file="Rplot.pdf", width=8, height=8, onefile=FALSE) ## set up the grid layout gl <- grid.layout(5, 5, widths=unit(c(1.8, 8, 0.8, 8, 0.8), "cm"), heights=unit(c(0.8, 8, 0.8, 8, 1.5), "cm")) if(FALSE) grid.show.layout(gl)
2006 Mar 15
1
How to get correct proportions/bounding box for latex figure?
Hello, I recently posted a question about my troubles with importing a lattice/trellis figure into latex. To recap, The figure contains 3 scatterplots, so it should have roughly a 1:3 sort of aspect ratio, in order to make each of the scatterplots square. Instead, the whole figure comes out roughly square, so each scatterplot is badly stretched. I fixed this by adding aspect=1/1 to the
2004 Feb 16
1
understanding loops for "loop-plotting"
Hi, i make some practice on "loops" to understand this important issue in "difference" to the wrappers like apply finally! The point is that i want plot's for different different const and wish in one pdf the 5 plots . So i want plots for const=1:5 which change the undelying data expressed in t1 and t2. I attempt some trials , while, for and now repeat loop now ,
2011 Apr 28
2
gridBase Base Plot Positioning
Hello, I'm trying to follow the documentation of how to use gridBase, and I've reached the minimal code example below as my best effort. Can someone explain how to keep the column of boxplots on the same page as the rectangles (even though I've tried new = TRUE) ? Also, would it be hard / possible to match up the middle of each boxplot to the middle of each rectangle ?
2008 Jun 17
6
Insert raster image into an R graphic
Dear useRs: Is there a way to include a raster image (e.g., .gif, .jpg, .bmp) representing a company logo, a school logo, etc. into an R graphic? For example, it would be nice to be able to include the logo of the school into the charts that a student produces for her dissertation. Similarly, while working on a competitive analysis, it would be nice to be able to replace the names of the
2005 Apr 19
2
Aspect ratio and limits
Suppose I have the following data I want to scatterplot: > xy [,1] [,2] [1,] 0 0 [2,] 21 4 I start up a graphics window and fire away: > plot(xy) - but because the graphics window is square, the aspect ratio is wrong. So I add: > plot(xy, asp=1) - now the aspect ratio is correct, but the Y range is about -8 to 11, whereas my data has a Y range of 0
2007 Jun 12
5
R Book Advice Needed
I am new to using R and would appreciate some advice on which books to start with to get up to speed on using R. My Background: 1-C# programmer. 2-Programmed directly using IMSL (Now Visual Numerics). 3- Used in past SPSS and Statistica. I put together a list but would like to pick the "best of" and avoid redundancy. Any suggestions on these books would be helpful (i.e. too much
2007 Mar 28
1
is this trellis device or standard graphics device?
OK, here is the issue: I have a graphcis device (say X11) which I can set as active by dev.set(n). Is there ANY way to identify/infer whether this X11 device was obtained from a lattice function (like xyplot, levelplot...) or a standard function (like plot, scatterplot,...). A related question is whether plot.new (or frame) was called to obtain this graphics device... Thanks. PK
2009 Dec 20
1
How to put text outside an xyplot?
Dear R-users, I have a plot created with the code below. I tried to put some text to the right of the color key. I worked with grid.text and also viewport(), but couldn't achieve this. I know this should be simple, but I just couldn't figure out how to do it. How does this work? Cheers, Marius library(lattice) library(grid) myvec=1:10 data=data.frame(x=myvec,y=myvec)
2003 Feb 21
1
grid.grill?
Why this command does not return grob? What is special about grill and what makes it different from axis, lines, rectangles... Thanks in advance
2006 Jul 01
1
postscript file too large : maybe an R question
i created a postscipt file in R and then i downloaded a free version of ghostview to view it. unfortunately, i get the message fata error : dynamic memory exhausted when i try to view it. when i do a dir on windows xp, the file size is 149,034,475 and i know there about 17,000 graphs. is there a way of possibly viewing this size postscript file in R itself ?
2003 Nov 24
4
R postscript generation error (lines versus points) (PR#5285)
Full_Name: Stephen Harker Version: 1.80 OS: linux (Yellow Dog 3.0 on ppc) Submission from: (NULL) (130.194.13.101) In creating a postscript file from a set of data in which the points are plotted using `points()' and lines drawn using `lines()' I have found since upgrading from R version 1.4? to 1.8 that the two sets do not coinicide completely. This is best illustrated by a simple