[R] displaying percentage in bar plot

2009-04-24 Thread Nattu
Hi, I have a query regarding barplot I have a following data AIS LEvel 1 23 body regionA 10 15 20 B 15 25 15 Now I want to plot a barplot and in each bar

Re: [R] issue building my own package... moving from Apple OS to Windows

2009-04-24 Thread ronggui
Yeah, you have to build a binary package for windows, unless you just want to simply source all the functions into R. 2009/4/24 Daryl Morris dar...@u.washington.edu: Hello, I have written my own very simple package.  On an Apple, I was able to run through the R CMD build and R CMD check

[R] prediction intervals (alpha and beta) for model average estimates from binomial glm and model.avg (library=dRedging)

2009-04-24 Thread Michelle Ensbey
Hi all, I was wondering if there is a function out there, or someone has written code for making confidence intervals around model averaged predictions (y~á+âx). The model average estimates are from the dRedging library? It seems a common thing but I can't seem to find one via the search

[R] Terminology: Multiple Regression versus multivariate Regression

2009-04-24 Thread strinz
Hello R-Members, can anyone explain the difference between multiple and multivariate regression to me in terms of the terminology and eventually its respect to the mathematical foundation respectively ? Is multiple regression perhaps more related to GLM and multivariate Regression rather

Re: [R] issue building my own package... moving from Apple OS to Windows

2009-04-24 Thread Uwe Ligges
Daryl Morris wrote: Hello, I have written my own very simple package. On an Apple, I was able to run through the R CMD build and R CMD check successfully. I have also installed the package, and successfully loaded the library on my Apple. This package is written entirely in R and

Re: [R] power.t.test formula

2009-04-24 Thread Karl Ove Hufthammer
Peter Dalgaard: Does anyone of you knows a reference for the formula used in power.t.test function? And also why it uses the Student's distribution instead of Normal. (I know both of them can be used but don't see whether choose one or the other) It is a straightforward first-principles

Re: [R] Terminology: Multiple Regression versus multivariate Reg

2009-04-24 Thread Ted Harding
On 24-Apr-09 08:14:34, str...@freenet.de wrote: Hello R-Members, can anyone explain the difference between multiple and multivariate regression to me in terms of the terminology and eventually its respect to the mathematical foundation respectively ? Is multiple regression perhaps more

Re: [R] displaying percentage in bar plot

2009-04-24 Thread Richard . Cotton
I have a following data AIS LEvel 1 23 body regionA 10 15 20 B 15 25 15 Now I want to plot a barplot and in each bar (corresponding a body region),

Re: [R] Terminology: Multiple Regression versus multivariate Reg

2009-04-24 Thread Peter Dalgaard
(Ted Harding) wrote: There is an unfortunate (in my view) tendency for people to use multivariate regression whden talking about what I call multiple regression above (i.e. more than 1 independent variable). I think this should be reserved for regression where the left-hand side is

Re: [R] Can't install package glmnet

2009-04-24 Thread Uwe Ligges
Liang Zhang wrote: Hi, I was trying to install package glmnet in R, but failed and it show such messages: * Installing *source* package glmnet ... This package has only been tested with gfortran. So some checks are needed. R_HOME is /home/username/R/R-2.9.0 Attempting to determine

Re: [R] Box-counting dimension and package 'fdim'

2009-04-24 Thread Uwe Ligges
Remko Duursma wrote: Dear R-helpers, I am looking for an implementation of the box-counting algorithm to estimate the box dimension of a cloud of points in 3D (aka fractal dimension, or similarity dimension). The package 'fdim' might be doing this, but the documentation is awful and I don't

Re: [R] suffix convention?

2009-04-24 Thread Uwe Ligges
Sebastian P. Luque wrote: Hi, Is there some convention for choosing 'RData' or 'rda' for binary files written by save() or save.image()? I don't think so, I'd prefer RData myself. The docs treat these interchangeably. Thanks. Indeed. Best, Uwe Ligges Cheers,

[R] How to see the content of geepack package

2009-04-24 Thread Cetinyürek Aysun
Dear list members, I need to see the content of the functions in package geepack. It uses some C functions in the computation they are not available in the package directory. How can I see the content of C functions? Kind Regards, Thank you, Aysun Cetinyurek

[R] Array

2009-04-24 Thread Bronagh Grimes
Hi there, Just wondering if anyone has any tips for using arrays? I am trying to convert the following SAS code to R: data A2; set A1; by subject_id; retain BX1-BX10i; array b(1:10) BX1-BX10 ; if first.subject_id then do ; do j=1 to 10; b(j) =

Re: [R] Nonlinear regression help

2009-04-24 Thread Uwe Ligges
Taylor Hermes wrote: I seek help with nonlinear regression for my data. I've run intro trouble fitting a model to my data as follows: rate_parameter stable_population 75 1996.1277 100 1623.2979 125 1362.3475 150 1164.6738 175 1014.8227 200 892.0851 225 794.1844 250 710.1489 275 639.6738

Re: [R] How to see the content of geepack package

2009-04-24 Thread Dimitris Rizopoulos
you can download the source code of the package from: http://cran.r-project.org/web/packages/geepack/index.html and inspect it; you probably want to look at the 'src' directory. I hope it helps. Best, Dimitris Cetinyürek Aysun wrote: Dear list members, I need to see the content of the

Re: [R] How to see the content of geepack package

2009-04-24 Thread Uwe Ligges
For example, read Ligges, U. (2006): R Help Desk: Accessing the Sources. R News 6 (4), 43-45. http://cran.r-project.org/doc/Rnews/Rnews_2006-4.pdf Best, Uwe Ligges Cetinyürek Aysun wrote: Dear list members, I need to see the content of the functions in package geepack. It uses some C

Re: [R] Array

2009-04-24 Thread Peter Dalgaard
Bronagh Grimes wrote: Just wondering if anyone has any tips for using arrays? You're presupposing that R works like SAS. It doesn't. This looks like a job for reshape (either Hadley Wickham's package or the built-in function). I am trying to convert the following SAS code to R: data A2;

Re: [R] Array

2009-04-24 Thread Bronagh Grimes
Thanks for this, will have a look now. Much appreciated, -Original Message- From: Peter Dalgaard [mailto:p.dalga...@biostat.ku.dk] Sent: 24 April 2009 11:40 To: Bronagh Grimes Cc: r-help@r-project.org Subject: Re: [R] Array Bronagh Grimes wrote: Just wondering if anyone has any tips

[R] stata == R - error messages

2009-04-24 Thread Rob Bakker
Dear Sirs, I am just starting with R and I think it is a great system. Now, I want to import Stata datasets (.dta) with read.dta, but receive errormessages like: Error in grep(^(http|ftp|https)://, file) : object Rklein not found Error in read.dta(Rklein) : unable to open file: 'No such file

Re: [R] Failing to print mer object in an RData image

2009-04-24 Thread Robert Zimbardo
Have you load lme4 before you print the object? Yes, I have. If yes, it may be caused by the change of representation of mer class. That may be so (although the image was saved on 12/19/2008, i.e. AFTER the release data of the lmer version I have now. But maybe I did that on a different

Re: [R] Generalized 2D list/array/whatever?

2009-04-24 Thread Duncan Murdoch
Toby wrote: I'm trying to figure out how I can get a generalized 2D list/array/matrix/whatever working. Seems I can't figure out how to make the variables the right type. I always seem to get some sort of error... out of bounds, wrong type, wrong dim, etc. Very confused... :) x[[some label,

Re: [R] Stuck using constrOptim

2009-04-24 Thread dre968
I'm very interested. If you wouldn't mind I would love to see it. Thank you for the help. dre968 wrote: Trying to use constrOptim to minimize the sum of squared deviations. I put the objective function in as: sum((x %*% Y - Z)^2) so i'm trying to get values for x to minimize the sum

Re: [R] deleting rows provisionally

2009-04-24 Thread onyourmark
Hi. Thanks very much for the reply and the good suggestion. It works well. But I don't get why the for loop is not deleting anything or making any assignments? Or I should say, doesn't answer3[-i,] delete entries from answer3 when the if condition is true? Also, in your first solution

Re: [R] displaying percentage in bar plot

2009-04-24 Thread Nattu
Hi Jim, Thank you for the help. Along with the bars I wanted to show the respective percentage as well. Is that possible ? Regards, Nataraju GM On Fri, Apr 24, 2009 at 4:38 PM, Jim Lemon j...@bitwrit.com.au wrote: Nattu wrote: Hi, I have a query regarding barplot I have a following data

[R] [R-help]Remove error data and clustering analysis

2009-04-24 Thread guodong wang
Hi, all, I’d like to do the clustering analysis in my dataset. The example data are as follows: Dataset 1: 500, 490, 486, 490, 491, 493, 480, 461, 504, 476, 434, 500, 470, 495, 3116, 3142, 12836, 3062, 3091, 3141, 3177, 3150, 3114, 3149; Dataset 2: 506, 473, 495, 494, 434, 459, 445, 475, 476,

Re: [R] stata == R - error messages

2009-04-24 Thread Jim Lemon
Rob Bakker wrote: Dear Sirs, I am just starting with R and I think it is a great system. Now, I want to import Stata datasets (.dta) with read.dta, but receive errormessages like: Error in grep(^(http|ftp|https)://, file) : object Rklein not found Error in read.dta(Rklein) : unable to open

Re: [R] stata == R - error messages

2009-04-24 Thread Duncan Murdoch
On 24/04/2009 7:42 AM, Peter Dalgaard wrote: Jim Lemon wrote: Rob Bakker wrote: Dear Sirs, I am just starting with R and I think it is a great system. Now, I want to import Stata datasets (.dta) with read.dta, but receive errormessages like: Error in grep(^(http|ftp|https)://, file) : object

Re: [R] iteration limit error in gamm and notExp2

2009-04-24 Thread Simon Wood
Isidora, What is the actual model structure that you are trying to fit? It's not clear to me that modifying the nonExp2 defaults will help convergence here, but it may be that some slight modifications of the model itself will sort things out, which is why it would be good to know what the

[R] Almost ideal demand system with ADL

2009-04-24 Thread Marie Vandresse
As anyone knows how to estimate an almost ideal demand system with autoregressive distributed las? Thanks! Marie - Le Bureau federal du Plan fete ses 50 ans en 2009. Het Federaal Planbureau viert zijn 50-ste

Re: [R] Terminology: Multiple Regression versus multivariate Reg

2009-04-24 Thread Dimitris Rizopoulos
Peter Dalgaard wrote: (Ted Harding) wrote: There is an unfortunate (in my view) tendency for people to use multivariate regression whden talking about what I call multiple regression above (i.e. more than 1 independent variable). I think this should be reserved for regression where the

Re: [R] How to see the content of geepack package

2009-04-24 Thread Duncan Murdoch
Cetinyürek Aysun wrote: Dear list members, I need to see the content of the functions in package geepack. It uses some C functions in the computation they are not available in the package directory. How can I see the content of C functions? You need to download the source of the package from

Re: [R] deleting rows provisionally

2009-04-24 Thread Hans Ekbrand
On Fri, Apr 24, 2009 at 04:50:48AM -0700, onyourmark wrote: Hi. Thanks very much for the reply and the good suggestion. It works well. But I don't get why the for loop is not deleting anything or making any assignments? Or I should say, doesn't answer3[-i,] delete entries from answer3 when

Re: [R] stata == R - error messages

2009-04-24 Thread Peter Dalgaard
Jim Lemon wrote: Rob Bakker wrote: Dear Sirs, I am just starting with R and I think it is a great system. Now, I want to import Stata datasets (.dta) with read.dta, but receive errormessages like: Error in grep(^(http|ftp|https)://, file) : object Rklein not found Error in

Re: [R] stata == R - error messages

2009-04-24 Thread Peter Dalgaard
Rob Bakker wrote: Dear Peter, Also thank you for your quick reply. I did the following with no positive result: library(foreign) read.dta(choose.file(C:\Rklein)) Error: unexpected input in read.dta(choose.file(C:\ read.dta(choose.file(C:\Rklein)) Error in grep(^(http|ftp|https)://,

Re: [R] displaying percentage in bar plot

2009-04-24 Thread Jim Lemon
Nattu wrote: Hi, I have a query regarding barplot I have a following data AIS LEvel 1 23 body regionA 10 15 20 B 15 25 15 Now I want to plot a barplot

Re: [R] deleting rows provisionally

2009-04-24 Thread David Winsemius
On Apr 24, 2009, at 7:50 AM, onyourmark wrote: Hi. Thanks very much for the reply and the good suggestion. It works well. But I don't get why the for loop is not deleting anything or making any assignments? Or I should say, doesn't answer3[-i,] delete entries from answer3 when the if

Re: [R] Generalized 2D list/array/whatever?

2009-04-24 Thread hadley wickham
On Fri, Apr 24, 2009 at 5:50 AM, Duncan Murdoch murd...@stats.uwo.ca wrote: Toby wrote: I'm trying to figure out how I can get a generalized 2D list/array/matrix/whatever working.  Seems I can't figure out how to make the variables the right type.  I always seem to get some sort of error...

Re: [R] prediction intervals (alpha and beta) for model average estimates from binomial glm and model.avg (library=dRedging)

2009-04-24 Thread David Winsemius
In R, the predict family of functions provides that facility. If you want the code it will be in the particular function associated with the model type. ?predict ?predict.glm # the example illustrates creation of prediction curves on the response scale for a specific range of data. #

Re: [R] power.t.test formula

2009-04-24 Thread Usuario R
Hello, Thank you, but can you understand this result? first I calculate the sd for n = 2 and then n with that sd. It should give me 2 right? FC = 1.5 alfa = 0.01 power = 0.85 sd1 - power.t.test( n = 2, delta = FC, sig.level = alfa, +power = power, type = two.sample, sd =

Re: [R] Array

2009-04-24 Thread Erik Iverson
Bronagh Grimes wrote: Hi there, Just wondering if anyone has any tips for using arrays? I am trying to convert the following SAS code to R: You're probably going to get more useful responses in general if, instead of posting code from SAS to be ported to R, you describe what the

Re: [R] Generalized 2D list/array/whatever?

2009-04-24 Thread Duncan Murdoch
On 24/04/2009 8:48 AM, hadley wickham wrote: On Fri, Apr 24, 2009 at 5:50 AM, Duncan Murdoch murd...@stats.uwo.ca wrote: Toby wrote: I'm trying to figure out how I can get a generalized 2D list/array/matrix/whatever working. Seems I can't figure out how to make the variables the right type.

Re: [R] power.t.test formula

2009-04-24 Thread Peter Dalgaard
Usuario R wrote: Hello, Thank you, but can you understand this result? first I calculate the sd for n = 2 and then n with that sd. It should give me 2 right? FC = 1.5 alfa = 0.01 power = 0.85 sd1 - power.t.test( n = 2, delta = FC, sig.level = alfa, +power = power,

[R] plot() - thicker points when pair exist more than 1 time?

2009-04-24 Thread Knut Krueger
Hi to all, is it possible to show in anyway that point 1,1 is existing more than 1one time? f.e.: f- data.frame(x=c(1,3,5,6,1),y=c(1,2,3,4,1)) plot(f) Regards Knut __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help

Re: [R] plot() - thicker points when pair exist more than 1 time?

2009-04-24 Thread Marc Schwartz
On Apr 24, 2009, at 8:09 AM, Knut Krueger wrote: Hi to all, is it possible to show in anyway that point 1,1 is existing more than 1one time? f.e.: f- data.frame(x=c(1,3,5,6,1),y=c(1,2,3,4,1)) plot(f) Regards Knut Several options: # See ?sunflowerplot sunflowerplot(f) # See

Re: [R] plot() - thicker points when pair exist more than 1 time?

2009-04-24 Thread baptiste auguie
on suitable devices, you could consider transparency, plot(f,col=alpha(grey,0.8),pch=19) baptiste On 24 Apr 2009, at 14:09, Knut Krueger wrote: f- data.frame(x=c(1,3,5,6,1),y=c(1,2,3,4,1)) plot(f) __ R-help@r-project.org mailing list

Re: [R] Interpreting the results of Friedman test

2009-04-24 Thread doerte . apelt
Hello, Peter Dalgaard wrote: Not necessarily, but the first suspicion one gets is that what you're doing with Friedman is not equivalent to what you're doing with ANOVA, could you show us the code and data (or an outline of it)? Please find attached the R script and the data input files. The

[R] Dealing with unix signal

2009-04-24 Thread Jong
Hi all, I'm wondering if there is any module or function in R can deal with unix signals such as SIGXCPU. In this way, when I get a signal from OS, I like to do something (such as saving current variables or terminating gracefully) by interrupting current execution of R. Thank you for your help

Re: [R] My surprising experience in trying out REvolution's R

2009-04-24 Thread Jason Liao
David, thanks for following this through. I do not know how big a matrix needs to be before the multi-core multi-threading will start save time. But it seems useful to build this protection in your distribution so that it will not do multi-core when multi-threading is more likely to do harm.

Re: [R] RES: How to force axis to have the same range

2009-04-24 Thread Sebastien Bihorel
Thanks to Greg and Deepayan for their answers. *Sebastien Bihorel, PharmD, PhD* PKPD Scientist Cognigen Corp Email: sebastien.biho...@cognigencorp.com mailto:sebastien.biho...@cognigencorp.com Phone: (716) 633-3463 ext. 323 Greg Snow wrote: For variables named my.x and my.y try: plot(

Re: [R] stata == R - error messages

2009-04-24 Thread Rob Bakker
Dear Duncan, Peter and Jim, Thank you very much!! It worked! Best regards, Rob Bakker 2009/4/24 Duncan Murdoch murd...@stats.uwo.ca On 24/04/2009 7:42 AM, Peter Dalgaard wrote: Jim Lemon wrote: Rob Bakker wrote: Dear Sirs, I am just starting with R and I think it is a great system.

Re: [R] stata == R - error messages

2009-04-24 Thread Rob Bakker
Dear Peter, Also thank you for your quick reply. I did the following with no positive result: library(foreign) read.dta(choose.file(C:\Rklein)) Error: unexpected input in read.dta(choose.file(C:\ read.dta(choose.file(C:\Rklein)) Error in grep(^(http|ftp|https)://, file) : could not find

Re: [R] Interpreting the results of Friedman test

2009-04-24 Thread Peter Dalgaard
doerte.ap...@gmx.de wrote: Hello, Peter Dalgaard wrote: Not necessarily, but the first suspicion one gets is that what you're doing with Friedman is not equivalent to what you're doing with ANOVA, could you show us the code and data (or an outline of it)? Please find attached the R

Re: [R] My surprising experience in trying out REvolution's R

2009-04-24 Thread David M Smith
You can always turn the multi-threading off with: setMKLthreads(1) We tested your code with this setting, and it ran in exactly the same time as CRAN R. # David Smith On Fri, Apr 24, 2009 at 7:34 AM, Jason Liao jl...@hes.hmc.psu.edu wrote: David, thanks for following this through. I do not

Re: [R] Interpreting the results of Friedman test

2009-04-24 Thread Doerte
Hello again, it seems, the R script has been filtered from the previous posting. Thus, I include is as text here: dataForANOVA - read.csv(C:/R/dataForANOVA.dat, sep=|, as.is=T, na.strings=.,

[R] Text Contrast in a Plot

2009-04-24 Thread Rodrigo Aluizio
Hi List, I would appreciate any suggestion on how can I make a text I’ve inserted in a plot show some contrast? With this I mean that I have a white text on a plot and I would like to make a tiny border around it in black, so even being small sized and the entire graphic being small in the text

Re: [R] stata == R - error messages

2009-04-24 Thread Hans Ekbrand
On Fri, Apr 24, 2009 at 01:50:04PM +0200, Rob Bakker wrote: Dear Peter, Also thank you for your quick reply. I did the following with no positive result: library(foreign) read.dta(choose.file(C:\Rklein)) a) quote the filename b) include the suffix rklein - read.dta(C:\Rklein.dta) --

[R] use of input in system()

2009-04-24 Thread Mike Miller
First, it looks like there is bug in the documentation... According to the documentation for system(): http://stat.ethz.ch/R-manual/R-patched/library/base/html/system.html input if a character vector is supplied, this is copied one string per line to a temporary file, and the

Re: [R] stata == R - error messages

2009-04-24 Thread Duncan Murdoch
On 4/24/2009 10:18 AM, Hans Ekbrand wrote: On Fri, Apr 24, 2009 at 01:50:04PM +0200, Rob Bakker wrote: Dear Peter, Also thank you for your quick reply. I did the following with no positive result: library(foreign) read.dta(choose.file(C:\Rklein)) a) quote the filename b) include the suffix

Re: [R] use of input in system()

2009-04-24 Thread Duncan Murdoch
On 4/24/2009 10:29 AM, Mike Miller wrote: First, it looks like there is bug in the documentation... According to the documentation for system(): http://stat.ethz.ch/R-manual/R-patched/library/base/html/system.html input if a character vector is supplied, this is copied one string per

Re: [R] Interpreting the results of Friedman test

2009-04-24 Thread Doerte
Anyways, Friedman's test is a replacement for a two-way ANOVA and you are comparing it to a one-way analysis, and the latter is likely just wrong. Okay. Thanks for the hint. Try anova(lm(AUC~as.factor(Condition)+as.factor(Observer),data=dataForANOVA)) This results in p-value = 0.37969.

[R] the puzzle of eigenvector and eigenvalue

2009-04-24 Thread Abelian
Dear all I am so glad the R can provide the efficient calculate about eigenvector and eigenvalue. However, i have some puzzle about the procedure of eigen. Fristly, what kind of procedue does the R utilize such that the eigen are obtained? For example, A=matrix(c(1,2,4,3),2,2) we can define the

Re: [R] Using JRI and Java 1.6 on MAC OS X

2009-04-24 Thread Phil Robinson
if you wish to use jni with java 1.6 on a mac you have to compile the native code as a 64 bit application (-m64 on a gcc command line) hope this helps [[alternative HTML version deleted]] __ R-help@r-project.org mailing list

[R] use of input in system()

2009-04-24 Thread Mike Miller
First, it looks like there is bug in the documentation... According to the documentation for system(): http://stat.ethz.ch/R-manual/R-patched/library/base/html/system.html input if a character vector is supplied, this is copied one string per line to a temporary file, and the

Re: [R] use of input in system()

2009-04-24 Thread Mike Miller
On Fri, 24 Apr 2009, Mike Miller wrote: I am running bash, but system calls go to sh. I want to be able to put that input string (0005) into a variable and do something like this: system( i=`cat /dev/stdin` ; run_script file${i}.out , input=sprintf(%04d, i) ) In sh, both of these

Re: [R] Interpreting the results of Friedman test

2009-04-24 Thread Peter Dalgaard
Doerte wrote: Anyways, Friedman's test is a replacement for a two-way ANOVA and you are comparing it to a one-way analysis, and the latter is likely just wrong. Okay. Thanks for the hint. Try anova(lm(AUC~as.factor(Condition)+as.factor(Observer),data=dataForANOVA)) This results in

[R] what is this experimental design (mixed-effects model)?

2009-04-24 Thread J S
Dear R community, I am wondering what experimental design I am dealing with? I study the effect of daily air temperature on daily body temperature of the overwintering turtles (i.e. sleeping in soil). The model is a cosine wave with the air temperature as a covariate. Objects are 19

Re: [R] the puzzle of eigenvector and eigenvalue

2009-04-24 Thread Duncan Murdoch
On 4/24/2009 10:30 AM, Abelian wrote: Dear all I am so glad the R can provide the efficient calculate about eigenvector and eigenvalue. However, i have some puzzle about the procedure of eigen. Fristly, what kind of procedue does the R utilize such that the eigen are obtained? For example,

[R] lagged variable in a dataframe

2009-04-24 Thread Cecilia Carmo
Hi! I have the following dataframe which represents a financial variable: revenue firm year revenue id 10.1 500194670 2007 27725 10 10.2 500194670 2006 9717 10 10.3 500194670 2005 125621 10 10.4 500194670 2004 84837 10 12.1 500278725 2007 308532 12 12.2 500278725 2006 493755

[R] function returns R object with name based on input

2009-04-24 Thread Jennifer Brea
I wanted to ask how I can make a for loop or a function return an R object with a unique name based on either some XX of the for loop or some input for the function. For example if I have a function: fn-function(data,year){ which does does some stuff } How do I return an object from the

Re: [R] function returns R object with name based on input

2009-04-24 Thread David Winsemius
On Apr 24, 2009, at 11:56 AM, Jennifer Brea wrote: I wanted to ask how I can make a for loop or a function return an R object with a unique name based on either some XX of the for loop or some input for the function. For example if I have a function: fn-function(data,year){ which does

[R] argument 'exclude' in function xtabs

2009-04-24 Thread Matthieu Lesnoff
Dear all I was willing to use argument 'exclude' in function xtabs to remove some levels of factors (xtabs help page says 'exclude: a vector of values to be excluded when forming the set of levels of the classifying factors). I tried: mydata - data.frame( treatment = c(B, A, C, C, B, B,

Re: [R] argument 'exclude' in function xtabs

2009-04-24 Thread Erik Iverson
I was willing to use argument 'exclude' in function xtabs to remove some levels of factors (xtabs help page says 'exclude: a vector of values to be excluded when forming the set of levels of the classifying factors). I think I see what's happening, and it's a little confusing to me, too.

[R] How to custom the tick and type in bwplot

2009-04-24 Thread Guanghong Zuo
Dear R users I use bwplot to plot some figures. There are two troubles: 1. How to change the dot of the mean to a line, like the style in boxplot 2. How to hide some tick marks. For example, I have seven tick: A, B, C, D, E, F, G, but I want show four marks: A, C, E, G on the x-axis.

[R] By= levels with the Hmisc summarize function.

2009-04-24 Thread Lane, Jim
Hi, All I have a data frame as follows: attach(mf) names(mf) [1] centre complex appl pool monthalloc_gb I want to summarize this as follows: agg-summarize(alloc_gb,by=llist(centre,complex,appl,month),FUN=sum, na.rm=TRUE) That seems to run fine but there something odd about

Re: [R] what is this experimental design (mixed-effects model)?

2009-04-24 Thread Dieter Menne
J S-19 wrote: I am wondering what experimental design I am dealing with? I study the effect of daily air temperature on daily body temperature of the overwintering turtles (i.e. sleeping in soil). The model is a cosine wave with the air temperature as a covariate. Not sure if I

Re: [R] Text Contrast in a Plot

2009-04-24 Thread Mark Difford
Hi Rodrigo, I would appreciate any suggestion on how can I make a text I’ve inserted in a plot show some contrast? There are quite a few approaches, but why not try legend? Best, Mark. Rodrigo Aluizio wrote: Hi List, I would appreciate any suggestion on how can I make a text I’ve

[R] omit empty cells in crosstab?

2009-04-24 Thread sjaffe
Perhaps this is a common question but I haven't been able to find the answer. I have data with many factors, each taking many values. However, only relatively few combinations appear in the data, ie have nonzero counts, in other words the resulting table is sparse. Say we have 10 factors each

Re: [R] omit empty cells in crosstab?

2009-04-24 Thread hadley wickham
Hi Steve, The general answer is yes, but the specific will depend on your problem. Could you provide a small reproducible example to illustrate your problem? Hadley On Fri, Apr 24, 2009 at 1:19 PM, sjaffe sja...@riskspan.com wrote: Perhaps this is a common question but I haven't been able to

Re: [R] use of input in system()

2009-04-24 Thread Mike Miller
On Fri, 24 Apr 2009, Mike Miller wrote: On Fri, 24 Apr 2009, Mike Miller wrote: I am running bash, but system calls go to sh. I want to be able to put that input string (0005) into a variable and do something like this: system( i=`cat /dev/stdin` ; run_script file${i}.out ,

[R] Problem with greek beta symbol in plot using CairoPDF (Windows)

2009-04-24 Thread Michal Figurski
Dear R-Helpers, I have a problem with displaying the greek beta symbol in PDF files using Cairo library - it displays as an empty box. The same also happens for a dash symbol in subscript. Both symbols are displayed correctly if the plot is produced on screen (outside of CairoPDF). The

Re: [R] How to custom the tick and type in bwplot

2009-04-24 Thread David Winsemius
On Apr 24, 2009, at 1:33 PM, Guanghong Zuo wrote: Dear R users I use bwplot to plot some figures. There are two troubles: 1. How to change the dot of the mean to a line, like the style in boxplot Sometimes you need to refer the the help page for panel.type of plot, in this case:

[R] font size relative to graphic

2009-04-24 Thread Mike Miller
I am printing numbers onto horizontal bars in a bar plots, but I am finding it difficult to make the number always the right size. If there are more bars, the bars get narrower and the font is too big. I also find that if I change the size of the graph, the bars will get wider or narrower

Re: [R] Can't install package glmnet

2009-04-24 Thread Uwe Ligges
Liang Zhang wrote: I am just wondering how to solve this installation problem. As I said, ask your admin to install suitable compilers. Uwe Thanks, Liang From: Uwe Ligges lig...@statistik.tu-dortmund.de To: Liang Zhang zhangl...@yahoo.com Cc:

Re: [R] font size relative to graphic

2009-04-24 Thread David Winsemius
On Apr 24, 2009, at 3:14 PM, Mike Miller wrote: I am printing numbers onto horizontal bars in a bar plots, but I am finding it difficult to make the number always the right size. If there are more bars, the bars get narrower and the font is too big. I also find that if I change the size

Re: [R] omit empty cells in crosstab?

2009-04-24 Thread Dieter Menne
sjaffe sjaffe at riskspan.com writes: I have data with many factors, each taking many values. However, only relatively few combinations appear in the data, ie have nonzero counts, in other words the resulting table is sparse. Say we have 10 factors each with 10 levels. The result of table()

[R] Invert Deviance Residuals

2009-04-24 Thread BillJones
I have a vector of deviance residuals, r, a vector of fitted values, yhat and I need to solve for a vector of actuals, y. The deviance residual formula is r={2(c ln c - c + 1)}^1/2. c=y/yhat. Since this can't be solved in closed form, I believe that I should be able to solve this numerically

Re: [R] omit empty cells in crosstab?

2009-04-24 Thread Peter Dalgaard
Dieter Menne wrote: sjaffe sjaffe at riskspan.com writes: I have data with many factors, each taking many values. However, only relatively few combinations appear in the data, ie have nonzero counts, in other words the resulting table is sparse. Say we have 10 factors each with 10 levels. The

Re: [R] Can't install package glmnet

2009-04-24 Thread Liang Zhang
I am just wondering how to solve this installation problem. Thanks, Liang From: Uwe Ligges lig...@statistik.tu-dortmund.de Cc: r-help@r-project.org Sent: Friday, April 24, 2009 2:50:00 AM Subject: Re: [R] Can't install package glmnet Liang Zhang wrote:

[R] saved workspace

2009-04-24 Thread bogdanno
I saved the workspace once and now it automatically restore it whenever I open R How can I turn off this? Thank you __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide

Re: [R] saved workspace

2009-04-24 Thread Sarah Goslee
Assuming you are starting R from a terminal window, you can use R --no-restore or change to a different directory first. If you are starting R in some other fashion, it will depend on what you are doing, a piece of information you neglected to provide (along with OS, which could be relevant, and

Re: [R] font size relative to graphic

2009-04-24 Thread Mike Miller
On Fri, 24 Apr 2009, David Winsemius wrote: On Apr 24, 2009, at 3:14 PM, Mike Miller wrote: I am printing numbers onto horizontal bars in a bar plots, but I am finding it difficult to make the number always the right size. If there are more bars, the bars get narrower and the font is too

Re: [R] omit empty cells in crosstab?

2009-04-24 Thread sjaffe
small example: a-c(1.1, 2.1, 9.1) b-cut(a,0:10) c-data.frame(b,b) d-table(c) dim(d) ##result: c(10, 10) But only 9 of the 100 cells are non-zero. If there were 10 columns, the table have 10 dimensions each of length 10, so have 10^10 elements, too much even to fit in memory Dieter Menne

Re: [R] update.packages(checkBuilt=TRUE) returns Error: invalid version specification NA in 2.9.0

2009-04-24 Thread Uwe Ligges
Just a guess: We had an issues with malformed PACKAGES files in the Windows repositories. Maybe you are affected here. Can you please try in 24 hours from now to do that again using the mirror in Austria. If the problem persists, please let me know. Thank you, Uwe Ligges

Re: [R] saved workspace

2009-04-24 Thread David Winsemius
One could also move the file out of the R search path, or rename it with an extension that prevents R from seeing it.( Some operating systems may not allow you to see it in their default mode, however.) -- David On Apr 24, 2009, at 4:07 PM, Sarah Goslee wrote: Assuming you are starting R

Re: [R] rounding problem + sprintf

2009-04-24 Thread Wacek Kusnierczyk
Prof Brian Ripley wrote: I think your subject line should read 'Excel bug'. From the R help for round() Note that for rounding off a 5, the IEC 60559 standard is expected to be used, '_go to the even digit_'. In case you did not recognize it, IEC 60559 is an international

Re: [R] font size relative to graphic

2009-04-24 Thread David Winsemius
On Apr 24, 2009, at 4:10 PM, Mike Miller wrote: On Fri, 24 Apr 2009, David Winsemius wrote: On Apr 24, 2009, at 3:14 PM, Mike Miller wrote: I am printing numbers onto horizontal bars in a bar plots, but I am finding it difficult to make the number always the right size. If there are

Re: [R] How to custom the tick and type in bwplot

2009-04-24 Thread Deepayan Sarkar
On 4/24/09, David Winsemius dwinsem...@comcast.net wrote: On Apr 24, 2009, at 1:33 PM, Guanghong Zuo wrote: Dear R users I use bwplot to plot some figures. There are two troubles: 1. How to change the dot of the mean to a line, like the style in boxplot Sometimes you need to

Re: [R] power.t.test formula

2009-04-24 Thread Greg Snow
Look at the pwr package, it has functions for 2 samples of different sizes. Hope this helps, -- Gregory (Greg) L. Snow Ph.D. Statistical Data Center Intermountain Healthcare greg.s...@imail.org 801.408.8111 -Original Message- From: r-help-boun...@r-project.org

Re: [R] issue building my own package... moving from Apple OS to Windows

2009-04-24 Thread Daryl Morris
Thanks for the various responses. It was easier than I thought to get all the tools together and setup Windows paths for the build process. I've been successful now on Windows. BUT... how do I make a package which DOES NOT require R CMD INSTALL to install? Obviously, it should not be

  1   2   >