search for: mygraph

Displaying 20 results from an estimated 20 matches for "mygraph".

2012 May 25
1
R+Stata batch mode
...btain with my computations written in my R source file I believe this is related to the global Rterm_options `"--vanilla"' that I need to precise to Rsource (otherwise it does not work) ... What kind of options should I precise instead in order to be able to use the R line : png('mygraph.png') dev.off() ? At the moment the file obtained (mygraph.png) is void ... but strangely enough the pictures are exported in a pdf file... which is not what I want anyway Any help ? Many thanks Best Regards [[alternative HTML version deleted]]
2002 Nov 08
1
pdf() and pdflatex
...ily='Helvetica',onefile=FALSE) par(lwd = lwd, mgp = c(2.5, .6, 0), mar = c(3.5, 3.5, 1, 1) + 1.e-10, bty='l') par(smo=0) plot( . . .) dev.off() Here is how I include the graphics file in LaTeX: \usepackage{graphics} ... \begin{figure}[hb]\leavevmode\centerline{\includegraphics{mygraph.pdf}} \caption{A caption} \label{fig:mygraph} \end{figure} I need onefile=FALSE because some of the high-level graphics commands I use produce more than one page of output. I am using pdflatex rather than including postscript files with latex so that I can use the hyperref style for pdflatex. Ha...
2004 Jun 11
2
Sweave and multiple graphs
Dear list, I am using Sweave to build a small report. I want to produce a series of figures, each figure containing a number of plots and then have them included in the Sweave file. An example would be to : postscript(file = "ANCbwplot%03d.eps", onefile = FALSE, other options...) oldpar <- par(mfrow = c(2,2)) .... do lots of plots to produce a number of eps files .... par(oldpar)
2002 Jan 09
3
lattice problems under Win2K and R-1.4.0
...ms I've see this alluded to recently in R-help. If I do the following example: > data(quakes) > xyplot(long ~ lat , data = quakes) And then try to copy or save the graph as either a metafile or bitmap or if I use any of the bitmap/metafile devices via (for example) > png(file="mygraph.png") > data(quakes) > xyplot(long ~ lat , data = quakes) > dev.off() I get the following type of error: Error in grid.newpage() : A png file can store only one figure. or for a metafile: Error: A metafile can store only one figure. This happens using R-1.4.0 installed using Setup...
2017 Jun 20
3
error while creating a simple graph
Dear All, I am learning R so it's a very simple problem but I do not understand while I am not able to generate a graph from two vectors. when I type this code, it generates a very nice graph. pdf("mygraph.pdf") > attach(mtcars) > plot(wt,mpg) > abline(lm(mpg~wt)) > title("Regreesion of mpg") > detach(mtcars) > dev.off() But I am trying to create a graph from this code, it generates a pdf with nothing. > dev.new() > pdf("test.pdf") > x <- c(1,...
2007 Sep 12
1
labels into graph
Hi, I have a matrix as: a b c 2 1 3 2 2 5 2 5 9 With values of this matrix, I draw a graph. Each row has a different meaning. For this reason, I need put different names each row. For example: mygraph ------------------- ------------------- -------------------- DescriptionA DescriptionB DescriptionC ------------------------------------------------- -------- -------- ab c1 c2 I know it...
2009 Sep 06
2
How to pop up the graphics window from Rscript?
Hi, I am wondering how to pop up the graphics window from Rscript. I run the following code, but I don't see the graphics window, even transiently. Regards, Peng $ Rscript plot.R > x=1:10 > y=1:10 > plot(x,y) >
2008 Feb 27
1
how to convert a table to adjacency matrix used in social network analysis?
Hi Guys, Do you any one know how to convert a long format table to an adjacency matrix used in sna? The long table looks like p1 p2 counts a b 100 a c 200 a d 100 b c 80 b d 90 b e 100 c d 100 c e 40 d e 60 and I want to convert it to an adjacency matrix which can be used in sna? Any methods will be appreciated! btw, besides sna package, is there any better package can be used in social
2010 May 22
1
Lattice Wireframe Plot into LaTex
...I'm simply trying to include a plot created with the Lattice wireframe function into LaTex. I have no problems including other R plots into LaTex by exporting as a Postcript and then including the graph in LaTex using \begin{figure} % Requires \usepackage{graphicx} \includegraphics[width=]{mygraph.eps}\\ \caption{}\label{} \end{figure} However, for some reason when I do this with a wireframe plot I can see the plot area in LaTex but not the plot itself. I've search for this exhaustively on the web but couldn't find an answer. I'll appreciate your help. Thanks, Lars. [[alte...
2012 Jan 29
1
How I assign the result of a plot to a variable?
I can write a plot to a files of a given format using this: x<-sample(c(1:100),10) bmp("c:/mygraph.bmp") plot(x) dev.off() and then show the image file in another application. This application can also display the image from the stream of numbers that define the image. How I can get the plot as a stream of numbers? [[alternative HTML version deleted]]
2008 Sep 01
1
How remove the small outline around R plots in LaTeX?
Dear R List, I noticed something odd when I started saving R graphs in pdf format and including them in LaTeX documents using (e.g.) \includegraphics{mygraphic.pdf}. A very thin dotted border is included in the LaTeX document around the graphic, and I cannot seem to make it go away. I searched Google as well as the R list archives but could not find anything on this. Note that this only seemed to start when I upgraded R to 2.6 or 2.7 -- I did...
2006 Jun 20
2
NLME: using the layout option with the plot command
Hi This is the 2nd time I am posting this question as I never got a reply the 1st time round - apologies to anybody who might take offense at this but I dont know what else to do. I am struggling to split up the plots of the grouped objects in nlme in a usable way. The standard plot command generates plots for each group on a single page. When there are many groups however this does not look
2007 Jul 17
2
Combine R2HTML and Rcmd BATCH?
Hi All, I have an R script that spawns output in the form of an HTML page. This is done by the R2HTML package. Now I want to run the same script using Rcmd BATCH. However, it seems that it is not possible to use R2HTML in this case. My script ends with this error message: ######################### Error in dev.print(png, file = AbsGraphFileName, width = Width, height = Height, : can only
2011 Nov 09
3
Help with tryCatch with a for loop
...me where to insert the tryCatch command) would be much appreciated!! Below is the script I am currently working on: data<-read.csv(file.choose(),sep=",",header=T) #File name is cbc.subset data$location.code = as.character(data$location.code) locs = unique(location.code) pdf("mygraphs.pdf",height=8, width=10) par(mfrow=c(3,4)) for(s in 1:length(locs)){ #To plot data from a particular stateroute: sub.ECDO<-data[data$location.code == locs[s],] plot(abund~year, data=sub.ECDO, main=locs[s]) #To plot the linear model for the specified location: lmodel<-lm(abun...
2003 Oct 07
1
plot width in Sweave
Hi I didn't find this in the manual: I need to change the width of a plot while I use sweave, so which command/parameters should I insert below, to change the width of a plot \begin{figure}[htbp] \begin{center} <<echo=TRUE, fig=TRUE>>= plot(Re(q),ylab ="",type="o",col="blue",lwd=1, sub=mystring) @ \caption{Original stick function (stimulus
2007 Oct 24
1
plot within a loop
Hi , I'm having problem with the following plot. Basically I have to do 51(length of d, see below) plots. I want 6 plots (say) in a page and rests are in different pages. win.graph() starts a plot in new page. But I'm not being able to combine par(mfrow = c(3,2)) and win.graph() within a loop. > d [1] 14.108 13.883 11.022 13.426 2.341 9.010 12.868 15.603 30.810 3.931 11.825
2011 Sep 18
2
graph bugs using R on MAC
This is has been bugging me for a long time. Nobody around me seems to have this problem. I hope someone on the forum could help me. When I generate a R graph and want to bring the image into Word. I cannot copy and paste it like many of my classmates can do. The "Select" in Edit menu have all options grayed out. So what I ended up doing is to save it as pdf file and bring it
2004 Jan 09
2
Letter Spacing
Hi All, I've been trying to make some adjustments to the graphics in a paper I wrote some time ago, for which the comments have been returned from the reviewers. I always use R for publication graphics...I think it does the best job available, for the things I am interested in. I could not get my graphics in R 181 to look the same as the old ones (completed 8 months ago), the text seemed
2010 Dec 06
2
ggplot2: Controlling line width of panel borders
Dear R-users, i encountered some problems when trying to adjust the line width of the axes and stripes in a plot created with ggplot2. I use the "barley" dataset of the lattice package to illustrate my problem: library(ggplot2) library(lattice) barley[["SD"]] <- 5 limits <- aes(ymax=barley$yield + barley$SD,ymin=barley$yield - barley$SD) p1 <-
2001 Nov 22
6
Editing R graphics
One of the few things that I miss from Splus is the ability of interactively add text and symbols to graphics that have been created by functions. I understand that the best solution in R is to create a graphic file and use external software for editing the graphic. I know what to use in the Win environment, but could anyone suggest what tools would be appropriate under Linux? Thanks Agus Dr.