similar to: sweave question

Displaying 20 results from an estimated 400 matches similar to: "sweave question"

2005 Nov 16
2
X11 error in png
Hi all, When I ran a script containing the following codes: png(paste(savepath,"a_rnaplot.png",sep = ""),width = fwidth, height = fheight,pointsize = fpointsize); data_deg <- AffyRNAdeg(data_cel) plotAffyRNAdeg(data_deg,col=cols,lty=1,lwd = "2") #a <- par("fin") legend("bottomright",sampleNames(data_cel),col=cols,lty=1)
2008 Nov 29
3
including Sweave tangled code in '.Rnw' document
Hello List, I have been using Sweave for my homework this last quarter and have been very impressed at how much time and effort it saves me. I, however, have run up against a problem which I have not been able to solve using any of the Sweave/LaTeX tricks I know. I work through my homework one problem at a time, typesetting equations and writing R code, etc. and occasionally use
2011 Nov 21
1
Sensitivity and Specificity Forest Plots
Dear R Users, Do you know of an existing function that allows the production of sensitivity and specificity forest plots? See the following for an example:
2009 Feb 02
2
Sweave
I'm trying to (re)learn Sweave and run into some problems. I use now ubuntu (8.10), emacs + ess. Slowly getting upto speed on ess. I have a complete (hopefully) .Rnw file, but the resulting .tex will not compile. The file does not contain anything exotic, but it produces pdf figures, and that is where the problems come: library(tools) > Sweave("varioCoo.Rnw") Writing to file
2012 Oct 30
1
print and execute functions in a package namespace
Let's say I have a package that consists of a set of functions, fig1(), fig2(), fig3() ..., each of which produces a plot, and perhaps some printed output, e.g., fig1 <- function() plot(1:10) fig2 <- function() plot(10:1) fig3 <- function() {y<-sample(1:10,10); plot(y); y} I'd like to produce a document (PDF or HTML) containing the listing of each function and its output,
2003 Aug 20
1
Five functions proposed for base
Dear r-devel, Among the R functions I have written and later shared with colleagues, there are five that I hope will become a part of the R base package. The tasks are neither specific nor marginal, so rather than creating one more 'misc' package, I would be happy if the R Development Core Team would adopt these functions and hammer them into shape. The functions are available from
2012 May 03
1
Identifying case by groups in a data frame
Hi everyone, I would like to identify the case by groups that is just bigger that avg plus sd. For example, using species as group and petal.wid as my variable in the iris data. What's the better way to doit? creating a function? So,the question is to identify the single element of each species that is just larger than a cut-off point (i.e. larger than mean + sd) I made this, but I can not
2011 Apr 08
4
Rpart decision tree
Dear useRs: I try to plot an rpart object but cannot get a nice tree structure plot. I am using plot.rpart and text.rpart (please see below) but the branches that connect the nodes overlap the text in the ellipses and rectangles. Is there a way to get a clean nice tree plot (as in the Rpart Mayo report)? I work under Windows and use R2.11.1 with rpart version 3.1-46. Thank you. Tudor ...
2010 Feb 16
3
error : unused argument(s) when boxplot
Dear all, I am a total beginner in R, so sorry if this is the wrong place. I am using R 2.10.1 on a Mac (Mac OS 10.6.2). I have this small dataset : growth sugar 75 C 72 C 73 C 61 F 67 F 64 F 62 S 63 S I have no problem reading the table, or getting the summary, but if I try boxplot(growth~sugar, ylab="growth", xlab="sugar", data=Dataset), I have the following error :
2007 Sep 28
1
errorbar il lattice plot
Hi Everyone, I would like to add errorbars to a lattice plot. I already have a function that adds error bars to a plot (originally written by George Gilchrist) which takes as arguments the coordinates of the point and then the size of the error bar. I would like to integrate it in my lattice code but I seem to be stumped. I can put the error bar function inside my code as if it were a panel
2005 Sep 22
7
Automatic creation of file names
Dear R-Help members, I have a question about how to save to the hard drive the one thousand datasets I generated in a simulation. The datasets are created in a "for" loop that repeatedly creates normally distributed datasets, such as the example below: Library(MASS) for (number in 1:1000) { dataset = mvrnorm(n = 400, mu = c(0,0,0), Sigma =
2006 Jan 23
1
too-large notches in boxplot (PR #7690)
PR #7690 points out that if the confidence intervals (+/-1.58 IQR/sqrt(n)) in a boxplot with notch=TRUE are larger than the hinges -- which is most likely to happen for small n and asymmetric distributions -- the resulting plot is ugly, e.g.: set.seed(1001) npts <- 5 X <- rnorm(2*npts,rep(3:4,each=npts),sd=1) f <- factor(rep(1:2,each=npts)) boxplot(X~f) boxplot(X~f,notch=TRUE) I can
2005 Oct 08
1
add leading 0s to %d from png() {was Automatic creation of file names}
Dear useRs, Is there a way to 'properly' format %d when plotting more than one page on png()? 'Properly' means to me with leading 0s, so that the PNGs become easy to navigate in a file/image browser. Lacking a better solution I ended up using the code below, but would much prefer something like png("test_%d.png",bg="white",width=1000,height=700) where %d
2005 Nov 22
2
(PR#8337) formatC adds leading space -- on some Windoze
>>>>> "KevinW" == Kevin Wright <kwright68 at gmail.com> >>>>> on Mon, 21 Nov 2005 18:13:36 +0100 (CET) writes: KevinW> Full_Name: Kevin Wright KevinW> Version: 2.2.0 KevinW> OS: Windows 2000 ^^^^^^^ this must be part of the problem KevinW> Submission from: (NULL) (170.54.58.4) KevinW> Apologies if
2010 Oct 19
2
ANOVA stuffs_How to save each result from FOR command?
Dear R experts, I'm new in R and a beginner in terms of statistics. It should be simple question, but definitely difficult to solve it by myself. I'd like to see main effect of group(gender: sample size is different(M:F=23:18) and one of condition(cond) and the interaction at each subset from 90 datasets So I perform anova 90 times using a command like below; for(i in 1:90)
2008 Mar 04
1
grid.layout?
platform x86_64-unknown-linux-gnu arch x86_64 os linux-gnu system x86_64, linux-gnu status major 2 minor 6.2 year 2008 month 02 day
2001 May 26
1
boxplots
Was there ever a convenient method provided to add boxplots to the current plot at specified x values? There was a question by Martin Maechler some time ago here, but I could seem to find any satisfactory resolution of it. I see that there is an add=T option to boxplot and bxp, but I don't see how to set the x-values. url: http://www.econ.uiuc.edu Roger Koenker email roger at
2005 Dec 06
2
Writing a list to a file !
Hi All, This may be trivial in R but I have been trying with out any success. I have a list of 100 elements each having a sub list of different length. I would like to write the list to a ASCII file. I tried with write.table(), after converting my list to a matrix. Now it looks like Robert c("90", "50", "30") John c("91", "20",
2003 Jan 22
1
self-split plot on multiple device
Hello! I would plot more than 10 (this number is always different) graphics on a figure with layout like 'mfrow=c(4,2)'. There is some existing function able to open the right number of device if number of graphics is done or I have to build it myself with some 'IF.....ELSE.....'? Thanks. A.S. ----------------------------
1999 Jun 29
1
text-plotting math & regular mixed ?
Maybe embarassing, but I can't quickly find out how to do this: Mix expression() text and regular text __in a variable__ for plotting: I can easily do plot(1,type="n",main=expression(paste("Plot of ", x ^ alpha, "; ", alpha==2.3) However, if alpha is really just in a variable, I don't know what to do alpha <- 2.3 ch.a <- format(alpha) and now