[R] [ggplot2] Densityplot, grouping and NAs

2009-03-24 Thread Weiss, Bernd
Dear all, I do not fully understand how ggplot2 handles NAs. See the following example: library(ggplot2) x <- rnorm(150) g <- as.factor(c(rep(c(0,1,NA),50))) mydf <- data.frame(x,g) m <- ggplot(aes(x = x, group = g, color = g), data = mydf) m + geom_density() How do I get rid of the NAs (i.

[R] Longitudinal study with three treatments

2009-03-24 Thread Stats Wolf
Hi, I am comparing three treatments. The data come from a longitudinal study, and for each treatment I have only 1 case, on which the observations across 20 years are made. My main aim is to compare the three treatments, but the effect of time is of interest as well. Which of the many R functions

Re: [R] generalized Poisson regression

2009-03-24 Thread Umesh Srinivasan
Hi, Not exactly sure what you mean, but if you want to run a poisson regression and then look at the coefficients, then this is what you need: poisson.model <- glm(response ~ predictor, family = "poisson") summary(poisson.model) Will give you the intercept and slope. Since poisson regression us

Re: [R] Green and Byar (1980) Prostate Cancer Data set from Andrews and Herzberg - Data

2009-03-24 Thread Ravi Varadhan
Fine detective work, David. Now, you can see the reasons for my frustration - multiplicity of data sets combined with non-existent documentation of the source of data in journal articles (e.g. Kay 1986; Lunn and McNeil 1995). Best, Ravi.

Re: [R] glm.nb() giving strongly different results

2009-03-24 Thread Bill.Venables
>From what you tell us it is impossible even to see if there is a problem, let >alone what it might be if there is one. There are all kinds of reasons why >intercepts may change and it is only unexpected if you do not fully understand >what the intercept parameter really is. For example, if yo

[R] how to calcualte Jaccard Coefficient

2009-03-24 Thread Wen Gu
Does anyone have a good method for calculating Jaccard coefficients now that the dissimilarity() function is no longer an option? Wen Gu John Jay College of Criminal Justice445 West 59 StreetNew York, NY 10029 w...@gc.cuny.edu

Re: [R] Grouping Numbers

2009-03-24 Thread Jorge Ivan Velez
Dear Jason, Try this: # First case N<-10 X<-rnorm(N) # Groups g<-rep(1:(N/n),each=10) # The result tapply(X,g,mean) For the second case, just change each=10 by each=100 and run again the code above. HTH, Jorge On Tue, Mar 24, 2009 at 10:52 PM, Jason Rupert wrote: > > Ugh...This should

Re: [R] Grouping Numbers

2009-03-24 Thread David Winsemius
Look at the seq function's help page. -- David Winsemius On Mar 24, 2009, at 10:52 PM, Jason Rupert wrote: Ugh...This should be very simple, but evidently I am not searching for the proper term. Given the below: val_size<-10 x_vals<-rnorm(val_size) I would like to group them accord

[R] Grouping Numbers

2009-03-24 Thread Jason Rupert
Ugh...This should be very simple, but evidently I am not searching for the proper term. Given the below: val_size<-10 x_vals<-rnorm(val_size) I would like to group them according to the following x_vals_mean_tmp[1]<-mean(x_vals[1:10]) x_vals_mean_tmp[2]<-mean(x_vals[11:20]) ... x_vals_mea

Re: [R] Green and Byar (1980) Prostate Cancer Data set from Andrews and Herzberg - Data

2009-03-24 Thread David Winsemius
On Mar 24, 2009, at 8:57 PM, Rolf Turner wrote: On 25/03/2009, at 12:09 PM, Frank E Harrell Jr wrote: (2) Scrolling down to ``Byar and Green prostate cancer data'' appeared to get me to the right place. But I couldn't see any signs of any ``R binary files''. Please look aga

[R] glm.nb() giving strongly different results

2009-03-24 Thread David Croll
Dear colleagues, I have performed several dozens of glm.nb(response ~ variable) analyses weeks ago, and when I looked through the results today I saw that many of the results have quite different intercept values despite the response part remained the same. I'm quite sure I did same kind

[R] how to identify a symbol is defined from which package

2009-03-24 Thread hong shen
Hi list, I encountered a situation that a data frame is defined by two packages. Both of them are loaded by library(). My questions are 1. How could I tell the data frame is from which package? 2. If I want to reference the data frame from package A insted of B, how can I do it? Thanks! hshen

Re: [R] confidence interval or error of x intercept of a linear

2009-03-24 Thread Kevin J Emerson
I wanted to send out a quick thanks to all that replied to my query about estimating the confidence interval around the x-intercept of a linear regression. The method I was able to implement in the most straightforward way was taken from Section 3.2 of Draper and Smith (1998). Applied Regressio

[R] question about commodity prices

2009-03-24 Thread Erin Hodgess
Dear R People: I use the get.hist.quote function to get historical stock prices from finance.yahoo.com. Does anyone know of a website to get historical commodity prices, please? Thanks, Sincerely, Erin -- Erin Hodgess Associate Professor Department of Computer and Mathematical Sciences Univer

[R] position weight matrix

2009-03-24 Thread Bogdan Tanasa
Hi all, I am sorry to fill your inbox mail with a naive question, although I would really appreciate your opinion. I am looking for a R function that takes a set of aligned sequences, and transforms a position frequency matrix into a position weight matrix. Thanks a lot. -- bogdan [[alte

Re: [R] Green and Byar (1980) Prostate Cancer Data set from Andrews and Herzberg - Data

2009-03-24 Thread Rolf Turner
On 25/03/2009, at 12:09 PM, Frank E Harrell Jr wrote: (2) Scrolling down to ``Byar and Green prostate cancer data'' appeared to get me to the right place. But I couldn't see any signs of any ``R binary files''. Please look again. It's under the heading "R". Unfortunately I u

Re: [R] multiple paired t-tests

2009-03-24 Thread Dan Kortschak
That is a valid point, the number of samples I expect to be different is actually quite small, but it is supportable (or otherwise) by other experimental data. Unfortunately the question I really want answered is pretty much covered by doing this. thanks Dan On 25/03/2009, at 10:25 AM,

[R] Rmpi - send/receive multiple objects to slaves

2009-03-24 Thread Nathan S. Watson-Haigh
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 I've written a function that uses Rmpi to perform a calculation in parallel. It works fine, but I'm trying to improve efficiency in terms of memory usage and the amount of data being passed back and forth between mater and slaves. Calculations are per

Re: [R] multiple paired t-tests

2009-03-24 Thread Eik Vettorazzi
.. and you will end up - in your example- with 60 t-statistics and p-values (so you do bonforroni adjustment or something like that)?! Sometimes the question for "How do I ..." should be read as "What is the question I *really* want to be answered ...". You may consider doing some more sophis

[R] problem with Rscript

2009-03-24 Thread m.u.r.
Hi all, this is probably some tricky configuration file problem, but I figure someone here might have come across this in the past: In short, I've been using Rscript to run my scripts, usually successfully. But recently I've run into a strange problem, and the only function that causes an error i

Re: [R] Green and Byar (1980) Prostate Cancer Data set from Andrews and Herzberg - Data

2009-03-24 Thread Frank E Harrell Jr
Rolf Turner wrote: On 25/03/2009, at 10:04 AM, Frank E Harrell Jr wrote: Ravi Varadhan wrote: Hi, I am looking for a data set containing the information from a randomized trial evaluating the effect of DES (diethylsilbestrol) on multiple time-to-event endpoints, prostate cancer, CVD, and o

Re: [R] multiple paired t-tests

2009-03-24 Thread David Winsemius
?try ?tryCatch On Mar 24, 2009, at 6:04 PM, Dan Kortschak wrote: Hi Jorge, That is exactly what I wanted - I should have given a reasonable number of observations (my set has *almost* all paired observations, so it will still break with that approach unless I manicure the data set). Is there

Re: [R] generalized Poisson regression

2009-03-24 Thread David Winsemius
Consider: gls with family="poisson" On Mar 24, 2009, at 1:26 PM, Arafat Ud Zaman wrote: Dear sir, I want to know about R command for parameter estimation for generalized Poisson regression. yours faithfully Arafat Ud Zaman 4th year(Hons) Applied statistics University of Dhaka Mob- +880171

[R] Return value from a C program is different from the R console

2009-03-24 Thread Loïc Paulevé
Dear R-users, I'm trying to call the qgamma function from a C program. But I'm experiencing a strange issue: the value returned by the C function seems to be different from the value returned by a R console. I'm running on linux 2.6.27 (ubuntu), i686 arch; R version 2.7.1 (2008-06-23) (shipped b

[R] GLMM with poisson distribution (lme4)

2009-03-24 Thread Jan Michael Kaesler
Dear R-Users, I have a question to the GLMM via the lme4 package. I have 160 nest-boxes which are placed at 8 different localities. "Count" is the number of animals which were found inside the boxes during the observation time. The independent variables are factors which are supposed to influence

Re: [R] Green and Byar (1980) Prostate Cancer Data set from Andrewsand Herzberg - Data

2009-03-24 Thread Ravi Varadhan
Rolf, I was able to basically reproduce your problems. Also, when I open the ".xls" file, with Excel, I got an error message "file error: data may have been lost". When I saved the file as .csv and got it into R, I found that the data set only has 502 records, but the original dataset of Andre

Re: [R] multiple paired t-tests

2009-03-24 Thread Dan Kortschak
Hi Jorge, That is exactly what I wanted - I should have given a reasonable number of observations (my set has *almost* all paired observations, so it will still break with that approach unless I manicure the data set). Is there a way to fail nicely on a single one of the tests without the

Re: [R] Prediction-class ROCR

2009-03-24 Thread Regina Beretta Mazaro
Hi! First I want to say thanks for the material that you sent to me, it was of great help! And now I have anothers questions: reading the material, I figured out that my classifier is a discrete one, so the ROC curve for it is just a point. Is ROCR able to plot this point for me? Or ROCR just

Re: [R] Green and Byar (1980) Prostate Cancer Data set from Andrews and Herzberg - Data

2009-03-24 Thread Rolf Turner
On 25/03/2009, at 10:04 AM, Frank E Harrell Jr wrote: Ravi Varadhan wrote: Hi, I am looking for a data set containing the information from a randomized trial evaluating the effect of DES (diethylsilbestrol) on multiple time-to-event endpoints, prostate cancer, CVD, and other causes. Th

[R] Announcement: Introduction to R and other courses at the University of Texas Summer Statistics Institute

2009-03-24 Thread Nate Marti
All courses are held a the University of Texas campus in Austin between May 26th and May 29th For information on the Institute: http://ssc.utexas.edu/summer_institute/index.html [[alternative HTML version deleted]] __ R-help@r-project.org mail

Re: [R] Green and Byar (1980) Prostate Cancer Data set from Andrews and Herzberg - Data

2009-03-24 Thread Frank E Harrell Jr
Ravi Varadhan wrote: Hi, I am looking for a data set containing the information from a randomized trial evaluating the effect of DES (diethylsilbestrol) on multiple time-to-event endpoints, prostate cancer, CVD, and other causes. The original source of this data is Green and Byar (1980). This

[R] Discriminant analysis - stepwise procedure

2009-03-24 Thread Jose Antonio
Dear R users, I have some environmental variables and I need to find the best combination of them in order to separate two main groups (coded 1 and 2). I have performed a discriminant analysis using the stepclass function as a method for selecting the most relevant environmental variables. The pr

[R] repolr output

2009-03-24 Thread Prew, Paul
Hello all, I am unsure of how to interpret the output from a Generalized Estimating Equation analysis of an ordinal response. I hope someone can enlighten me. The analysis was done using package 'repolr'. The data consists of a Score on a 3-point scale from 56 Subjects after repeatedly washing

Re: [R] Executing an external executable from within R?

2009-03-24 Thread Gabor Grothendieck
shell("notepad") works for me. I am using Windows Vista. On Tue, Mar 24, 2009 at 4:14 PM, Jason Rupert wrote: > > For example, from within an R script I would like to be able to launch > NotePad.exe. > > Is there an R call for launching Notepad.exe from within R? > > I've tried the following, b

Re: [R] Green and Byar (1980) Prostate Cancer Data set from Andrews and Herzberg - Data

2009-03-24 Thread Ravi Varadhan
I just found it. Please disregrad my email. Ravi. Ravi Varadhan, Ph.D. Assistant Professor, Division of Geriatric Medicine and Gerontology School of Medicine Johns Hopkins University Ph. (410) 502-2619 email: rvarad...@jhm

Re: [R] Executing an external executable from within R?

2009-03-24 Thread Jorge Ivan Velez
Dear Jason, Try this: shell.exec('C:/WINDOWS/NotePad.exe') HTH, Jorge On Tue, Mar 24, 2009 at 4:14 PM, Jason Rupert wrote: > > For example, from within an R script I would like to be able to launch > NotePad.exe. > > Is there an R call for launching Notepad.exe from within R? > > I've tried t

[R] multiple paired t-tests

2009-03-24 Thread Dan Kortschak
Hi R users, I have a very large data set that has two conditioning variables for the test I want to perform. A toy set can be simulated: type<-sample(1:3,100,replace=TRUE) class<-sample(1:20,100,replace=TRUE) value<-rnorm(100) data<-cbind(type,class,value) (though type and class are alphanum)

[R] Executing an external executable from within R?

2009-03-24 Thread Jason Rupert
For example, from within an R script I would like to be able to launch NotePad.exe. Is there an R call for launching Notepad.exe from within R? I've tried the following, but they don't seem to work: > system(paste('"C:/WINDOWS/NOTEPAD.exe"'), wait = FALSE) > system("C:/WINDOWS/NOTEPAD.exe",

[R] Green and Byar (1980) Prostate Cancer Data set from Andrews and Herzberg - Data

2009-03-24 Thread Ravi Varadhan
Hi, I am looking for a data set containing the information from a randomized trial evaluating the effect of DES (diethylsilbestrol) on multiple time-to-event endpoints, prostate cancer, CVD, and other causes. The original source of this data is Green and Byar (1980). This is a popular competi

Re: [R] modelling probabilities instead of binary data with logistic regression

2009-03-24 Thread joris meys
Thank you all for the very fast answers. My proportions come from a factor analysis on a number of binary variables, in order to avoid having to fit 12 logistic regressions on the same dataset. By scaling the obtained scores to 0 and 1, I get weighted averages of the response combinations I'm inte

Re: [R] Testing for symbolic links

2009-03-24 Thread Rolf Turner
On 25/03/2009, at 6:29 AM, Gregoire Pau wrote: Hello, How can I test in R whether a file is a symbolic link or not ? I haven't found anything relevant in R-help but I may be wrong. Thanks ! Since symbolic links are a Unix thing, I assume you are working on a system that is sufficiently

[R] segfault when running heatmap()

2009-03-24 Thread Andrew Yee
Hi, I was wondering if someone in the mailing list has any insight into this segfault error that I consistently find when running a script containing heatmap() in R 2.8.1 and 2.8.0 on a Linux 64-bit machine. Some points: 1. This occurs when running heatmap(). 2. Interestingly, if I source() the s

[R] Probability trees

2009-03-24 Thread Waldir Leôncio
How can I create probability trees in R? I've searched everywhere I could and still have no clue. :-/ [[alternative HTML version deleted]] __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the post

[R] modelling probabilities instead of binary data with logistic regression

2009-03-24 Thread joris meys
Dear all, I have a dataset where I reduced the dimensionality, and now I have a response variable with probabilities/proportions between 0 and 1. I wanted to do a logistic regression on those, but the function glm refuses to do that with non-integer values in the response. I also tried lrm, but th

Re: [R] read in large data file (tsv) with inline filter?

2009-03-24 Thread David Reiss
Hi all, Thanks a lot for your responses. I forgot to mention in my posting that I also want to try to be as cross-platform as possible (and thus to avoid relying on external calls to UNIX programs such as grep). I like the idea from Thomas: You certainly don't want to use repeated reads from the s

Re: [R] Why na.rm=FALSE is the default

2009-03-24 Thread Greg Snow
The only reference that I can think of (a bit subtle/indirect) is: http://www.burns-stat.com/pages/Tutor/spreadsheet_addiction.html (look in the section on Propagation of Blanks). But I think that it really comes down to the following 2 variations on a rule: 1. Important decisions (such as thro

Re: [R] Summarizing each row into a frequency table

2009-03-24 Thread William Dunlap
Have you tried table(row(m), m) ? If there is a chance that m doesn't have at least 1 of each of c(-1,0,1) then force them into the table with table(row(m), factor(m, levels=c(-1,0,1))) Bill Dunlap TIBCO Software Inc - Spotfire Division wdunlap tibco.com -

Re: [R] Workspace Image

2009-03-24 Thread Dieter Menne
Yikan Liu anu.edu.au> writes: > > I'm wondering how to delete previously saved workspace in R. file.remove("mywork.rdata") Dieter __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http

[R] Search "Errors"

2009-03-24 Thread CE.KA
Hi R users, I have a big program So in Rgui I can t see all the execution of it Is there a way to ask R if there is "Errors" in my program Sincerely yours -- View this message in context: http://www.nabble.com/Search-%22Errors%22-tp22687080p22687080.html Sent from the R help mailing list archive

Re: [R] generalized Poisson regression

2009-03-24 Thread Rob Denniker
Not 100% sure what you are looking for, but have a look at the Generalized Event Count model in the Zelig package. It will also let you fit a Poisson and other event count models by MLE. > -Original Message- > From: azam...@isrt.ac.bd > Sent: Tue, 24 Mar 2009 23:26:59 +0600 > To: r-help

[R] Why na.rm=FALSE is the default

2009-03-24 Thread Adam D. I. Kramer
Dear Colleagues, I've been searching for a post or article or something which explains why having na.rm=FALSE or na.action=na.fail as the default is a better choice than TRUE or na.omit. I understand the basic argument: it does not make sense to average a nonexistance into an agg

[R] Workspace Image

2009-03-24 Thread Yikan Liu
Hello, I'm wondering how to delete previously saved workspace in R. Thank you. Regards, Yikan Liu [[alternative HTML version deleted]] __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the pos

[R] generalized Poisson regression

2009-03-24 Thread Arafat Ud Zaman
Dear sir, I want to know about R command for parameter estimation for generalized Poisson regression. yours faithfully Arafat Ud Zaman 4th year(Hons) Applied statistics University of Dhaka Mob- +8801715173176 E-mail: arafat.za...@yahoo.com azam...@isrt.ac.bd azam...@quantummet

[R] Testing for symbolic links

2009-03-24 Thread Gregoire Pau
Hello, How can I test in R whether a file is a symbolic link or not ? I haven't found anything relevant in R-help but I may be wrong. Thanks ! Greg --- Gregoire Pau Research Officer EMBL Heidelberg, Germany http://www.ebi.ac.uk/~gpau/ __ R-help@r-pr

Re: [R] Display Equation on plot

2009-03-24 Thread Matthieu Dubois
Douglas M. Hultstrand metstat.com> writes: > > Hello, > > I am using the lm to fit a linear model to data, I was wondering if > there is a way to display the equation on a plot using the extracted lm > coefficients? I am using the plot() function to create the plot/.png. > > Example: > lm_m

Re: [R] Display Equation on plot

2009-03-24 Thread Duncan Murdoch
On 3/24/2009 12:50 PM, Douglas M. Hultstrand wrote: Hello, I am using the lm to fit a linear model to data, I was wondering if there is a way to display the equation on a plot using the extracted lm coefficients? I am using the plot() function to create the plot/.png. Example: lm_mod <- lm(

[R] no snowfall on debian after lenny upgrade

2009-03-24 Thread Martin Renner
I feel like I've tried the works on something that should be obvious but I'm stuck. Package snowfall used to run just great under debian etch (amd-64, 2x quad-core). After upgrading to lenny (debian 5, reinstalled from scratch), I haven't been able to get snowfall running again. Password-le

Re: [R] Display Equation on plot

2009-03-24 Thread Uwe Ligges
Douglas M. Hultstrand wrote: Hello, I am using the lm to fit a linear model to data, I was wondering if there is a way to display the equation on a plot using the extracted lm coefficients? I am using the plot() function to create the plot/.png. Example: lm_mod <- lm(data1~data2) interce

[R] Display Equation on plot

2009-03-24 Thread Douglas M. Hultstrand
Hello, I am using the lm to fit a linear model to data, I was wondering if there is a way to display the equation on a plot using the extracted lm coefficients? I am using the plot() function to create the plot/.png. Example: lm_mod <- lm(data1~data2) intercept = 48.54 slope = 0.4856 I wan

Re: [R] r online

2009-03-24 Thread j verzani
Dirk Eddelbuettel debian.org> writes: > > > On 24 March 2009 at 12:06, Thomas Steiner wrote: > | Hi, > | I'd like to execute simple commands and functions in R through a > | website, is there any service like this somewhere? > | I only found http://www.osvisions.com/r-online/ but it does not wo

Re: [R] R: how to estimate multidimensional spectral measure of coherence

2009-03-24 Thread stephen sefick
Look at the function wco to see if you can use it. I don't have R on my work computer right now to test and see, but AI think you could look at this. I don't know what a slidding window is, but wavelets are time localized so I don't think this would be a problem. Also, you could easily slide the

Re: [R] confidence interval or error of x intercept of a linear

2009-03-24 Thread Peter Dalgaard
(Ted Harding) wrote: > On 24-Mar-09 03:31:32, Kevin J Emerson wrote: ... > When I have time for it (not today) I'll see if I can implement > this neatly in R. It's basically a question of solving > > (N-2)*(1 - R(X0))/R(X0) = qf(P,1,(N-1)) > > for X0 (two solutions, maybe one, if any exist).

Re: [R] how to do trend.test for subset data

2009-03-24 Thread David Winsemius
That question seems too vague to be answered. There should be no problem in doing such. Do you have a problem that you are encountering? -- David Winsemius On Mar 24, 2009, at 10:52 AM, Xin Shi wrote: Dear: I try to do the trend.test {pastecs} for a subset data. Anyone have this experienc

Re: [R] How to find the path or the current file?

2009-03-24 Thread William Dunlap
I sometimes deal with this problem by putting all the scripts into a package (in the inst/ directory if they don't fit elsewhere, perhaps in demo/) and then have them all use system.file(package="myPkg",...) to locate the related files. E.g., terms.conf <- system.file(package="myPkg","conf","t

[R] Hotteling Test

2009-03-24 Thread MarcioRibeiro
Hi listers, I would like to do a graphic of the power function of the Hotteling test (T2). T2~F(p,n-p;lambda), lambda is my paremeter of non-centrality. So I would like to do a graphic of the power of the test as a function of the parameter lambda. I also would like to define lambda varying betwee

[R] how to do trend.test for subset data

2009-03-24 Thread Xin Shi
Dear: I try to do the trend.test {pastecs} for a subset data. Anyone have this experience? Many thanks! Xin __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org

Re: [R] Do we have to control for block in block designs if it is insignificant?

2009-03-24 Thread Liaw, Andy
The short answer is "no" (meaning to leave the blocks in the model). As Frank Harrell said, you've spent your degrees of freedom. Go home and be happy. Best, Andy From: J S > Sent: Tuesday, March 24, 2009 9:49 AM > To: r-help@r-project.org > Subject: [R] Do we have to control for block in bloc

[R] Odp: error statement: missing value where TRUE/FALSE needed

2009-03-24 Thread Petr PIKAL
Hi r-help-boun...@r-project.org napsal dne 23.03.2009 15:38:49: > Hi list, > > I want to try Gibbs sampling as a method of estimating a markov-switching > model of a mean-deviating, pth-order autoregressive process with time > varying transition probabilities via R and am using a code origin

[R] Has someone connected R with ITK?

2009-03-24 Thread Brandon . J . Whitcher
Dear R users, I am curious to know if someone has connected R with the Insight Segmentation and Registration Toolkit (www.itk.org). From the website... ITK is an open-source, cross-platform system that provides developers with an extensive suite of software tools for image analysis. Developed

Re: [R] Random sampling based on the observations

2009-03-24 Thread Arup
Thank you Adrian. Its working.Thank you so much. Take care =^D=) Cheers Arup Pramanik Business Analyst Redwood Associates Bangalore,India. Adrian Dusa wrote: > > On Tuesday 24 March 2009, you wrote: >> Hello!I am having a problem with Random sampling in R. I have used a >> syntax: mydata.sub

[R] using residuals of binomial GLM

2009-03-24 Thread Yuval Sapir
Hi all, This is more a question in statistics, but I hope to get also the R practice for my question: I have an ancova model where the response variable is flowering (plant has a flower = 1, no flower = 0). The explanatory variables are leaf length, leaf thick (both continuous variables), and s

[R] Help with lattice

2009-03-24 Thread Steve_Friedman
Hello. I'm working on a windows XP machine with R 2.8.1 I'm working with lattice and I don't understand how to set the size of the text for the labels. Can anyone suggest a solution? I'm establishing a melted dataframe first and then setting a key and calling the plot as follows; > key.va

[R] as.list cannot handle an environment

2009-03-24 Thread Wacek Kusnierczyk
?as.list states that as.list can be used with environments as arguments (what is referred to there as the '"environment" method for as.list). indeed, e = globalenv() as.list(e) # $e # however, it seems to have problems with environment objects with a class attribute: e = st

Re: [R] How to find the path or the current file?

2009-03-24 Thread Marie Sivertsen
Thank you Gabor and Duncan for your replys. Mvh. Marie On Tue, Mar 24, 2009 at 1:00 PM, Gabor Grothendieck wrote: > See: > > https://stat.ethz.ch/pipermail/r-help/2009-January/184745.html > > On Tue, Mar 24, 2009 at 7:16 AM, Marie Sivertsen > wrote: > > Dear useRs, > > > > I have a collection

[R] Do we have to control for block in block designs if it is insignificant?

2009-03-24 Thread J S
I am wondering if in a block experimental design (ex. triple square lattice), the block effect was not significant, is it all right not to include the block effect in an empirical model (even though the sampling was done from different blocks)? Or we are forced to control for the block effe

Re: [R] Barplot With Selected X-Axis Region

2009-03-24 Thread Uwe Ligges
Gundala Viswanath wrote: Dear all, I have a data that looks like this: print(dat) V1 V2 1 -43342073 14 2 -433377304 3 -432846761 11372 75188572 11 11373 752061656 11374 75262720 24 What I want to do is to have a barplot where x-axis is

Re: [R] Random sampling based on the observations

2009-03-24 Thread Uwe Ligges
Arup wrote: Hello!I am having a problem with Random sampling in R. I have used a syntax: mydata.sub=sample(mydata,7,replace=FALSE,prob=NULL) which allows me to choose a random sample based on the variables(correct me if I am wrong!). Suppose I have 10 variable and if I use the above mentioned c

Re: [R] install.package("TinnR") - there is no package called 'TinnR' (RESOLVED)

2009-03-24 Thread Martin Tomko
Yes, will do. I just was not in need to upgrade as everything worked... An R is not my primary development environment - i.e., I need it a couple of times a year. But you are right, it is good to be on an updated version. Cheers Martin Duncan Murdoch wrote: On 3/24/2009 8:55 AM, Martin Tomko w

Re: [R] install.package("TinnR") - there is no package called 'TinnR' (RESOLVED)

2009-03-24 Thread Duncan Murdoch
On 3/24/2009 8:55 AM, Martin Tomko wrote: Hi Duncan, it is Win Xp with the 2.6.0 R-project version. Sorry, I should have included this before. Installing the TinnR package manually from a local zip file downloaded from CRAN helped. I am still not sure why the package was not picked in the repo

Re: [R] Calculating percentage Missing value for variables using one object

2009-03-24 Thread Gabor Grothendieck
Read in the data, aggregate it by month and then turn it into a monthly zoo object and plot using a custom X axis: Lines <- 'dos,variable1,variable2 May-06,1,"" May-06,2,"" June-06,"",2 June-06,1,4 July-06,1,4 July-06,1,4 August-06,1,4 August-06,1,4' DF <- read.table(textConnection(Lines), header

Re: [R] CONFIDENCE INTERVAL FOR GLMER MODEL

2009-03-24 Thread Douglas Bates
On Tue, Mar 24, 2009 at 5:25 AM, LiatL wrote: > I've built a poisson regression model for multiple subjects by using the > GLMER function. I've also developed some curves for defining its limits but > I did not succeed in developing confidence interval for the model's curve > (confint or predict

Re: [R] install.package("TinnR") - there is no package called 'TinnR' (RESOLVED)

2009-03-24 Thread Uwe Ligges
Martin Tomko wrote: Hi Duncan, it is Win Xp with the 2.6.0 R-project version. Sorry, I should have included this before. Installing the TinnR package manually from a local zip file downloaded from CRAN helped. I am still not sure why the package was not picked in the repositories. Can anyone

[R] RES: Plot Means Line with Standard Deviation as "Whiskers"

2009-03-24 Thread Rodrigo Aluizio
Thanks for the answer, I'll take a look at these, meanwhile I forged some data as an example of what I'll have soon. Sam.Vol. A1R179,40 A1R2102,09 A1R3102,09 A2R1124,78 A2R2158,81 A2R3153,13 A3R1226,87 A3R2164,48 A3R3153,13 A4R1181,49 A4R2175,82 A4R3

Re: [R] help: what are the basis functions in {mgcv}: gam?

2009-03-24 Thread oliviax
Thank you very much. I have downloaded your paper. Best regards. Olivia Simon Wood-4 wrote: > > If you can't get hold of the book, try appendix A of > http://www.maths.bath.ac.uk/~sw283/simon/papers/psm.pdf > -- what's described there is the "cr" basis > > best, > Simon > > > On Tuesday

Re: [R] install.package("TinnR") - there is no package called 'TinnR' (RESOLVED)

2009-03-24 Thread Martin Tomko
Hi Duncan, it is Win Xp with the 2.6.0 R-project version. Sorry, I should have included this before. Installing the TinnR package manually from a local zip file downloaded from CRAN helped. I am still not sure why the package was not picked in the repositories. Can anyone please see if the pack

Re: [R] Calculating percentage Missing value for variables using one object

2009-03-24 Thread David Winsemius
It looks to me that you should be using the table or the xtabs function. You have apparently already decided not to use NA for missing values, so the instances in which variable1 == "" you should get counts with those functions: dft <- data.frame(var1 = sample(c("", "this", "that", "and"),

Re: [R] install.package("TinnR") - there is no package called 'TinnR'

2009-03-24 Thread Duncan Murdoch
On 3/24/2009 7:05 AM, Martin Tomko wrote: I have troubles make TinnR 2.2.0.2 work, it seems that the dependency on the package TinnR that cannot be found (I tried also manual downloads, but I cannot find the package anywhere on any CRAN mirror). What R version are you using, on what platform?

Re: [R] install.package("TinnR") - there is no package called 'TinnR'

2009-03-24 Thread Martin Tomko
Patrick, Romain, thank you very much for your help! I have found the site of the package at http://r-forge.r-project.org/projects/tinnr/ , as Romain suggests, but when you try to download, iyou find that the package is actually not contributed to the repository, it is just a space holder for it!

Re: [R] Variogram with Gstat

2009-03-24 Thread ONKELINX, Thierry
Have a look at the examples in the helpfile for variogram from the gstat package. data(meuse) # no trend: coordinates(meuse) = ~x+y variogram(log(zinc)~1, meuse) # residual variogram w.r.t. a linear trend: variogram(log(zinc)~x+y, meuse) # directional variogram: variogram(log(zinc)~x+y, meuse, alp

[R] CONFIDENCE INTERVAL FOR GLMER MODEL

2009-03-24 Thread LiatL
I've built a poisson regression model for multiple subjects by using the GLMER function. I've also developed some curves for defining its limits but I did not succeed in developing confidence interval for the model's curve (confint or predict does not work - only for glm). Does anyone know how can

Re: [R] install.package("TinnR") - there is no package called 'TinnR'

2009-03-24 Thread Richardson, Patrick
Hi Martin, If all else fails, you could download the package from http://cran.r-project.org/web/packages/TinnR/index.html and install as a .zip file from within R. That is bizarre that R cannot find the package. I've had no problems downloading and installing. Best regards, Patrick -

Re: [R] r online

2009-03-24 Thread David Winsemius
Google with "rweb" -- David Winsemius On Mar 24, 2009, at 7:06 AM, Thomas Steiner wrote: Hi, I'd like to execute simple commands and functions in R through a website, is there any service like this somewhere? I only found http://www.osvisions.com/r-online/ but it does not work (last update 200

Re: [R] install.package("TinnR") - there is no package called 'TinnR'

2009-03-24 Thread Martin Tomko
David, that is not helpful. I KNOW that TinnR is a standalone editor. If you had a look at the Rprofile.site required by TinnR, you would notice the part of the code I send earlier: # check necesary packages necessary = c('TinnR', 'svSocket') installed = necessary %in% installed.packages()[, 'P

Re: [R] install.package("TinnR") - there is no package called 'TinnR'

2009-03-24 Thread David Winsemius
Tinn-R is not an R package. It is a standalone text editor: http://www.lmgtfy.com/?q=tinn-r -- David Winsemius On Mar 24, 2009, at 7:05 AM, Martin Tomko wrote: I have troubles make TinnR 2.2.0.2 work, it seems that the dependency on the package TinnR that cannot be found (I tried also

Re: [R] mvpart error

2009-03-24 Thread Gavin Simpson
On Sun, 2009-03-22 at 22:45 -0400, Josh Stumpf wrote: > Hello all, > > When attempting a classification tree using mvpart, I get the following > error: > > > thesis2.mvp=mvpart(bat_sp~., data=alltrees.df) > Error in all(keep) : > unused argument(s) (c(TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, T

Re: [R] read in large data file (tsv) with inline filter?

2009-03-24 Thread Dirk Eddelbuettel
Hi David, On 23 March 2009 at 15:09, Dylan Beaudette wrote: | On Monday 23 March 2009, David Reiss wrote: | > I have a very large tab-delimited file, too big to store in memory via | > readLines() or read.delim(). Turns out I only need a few hundred of those | > lines to be read in. If it were no

Re: [R] Legend containing maths symbol and values of variables

2009-03-24 Thread Daren Tan
Thanks, that works beautifully. Without your help, I will be struggling for a long time. On Tue, Mar 24, 2009 at 7:46 PM, Gabor Grothendieck wrote: > that should have been: > > L <- list(bquote("Up (" >= .(threshold) ~ ")"), "Normal", "Down", "NA") > legend("top", leg = as.expression(L)) > > > On

Re: [R] How to find the path or the current file?

2009-03-24 Thread Gabor Grothendieck
See: https://stat.ethz.ch/pipermail/r-help/2009-January/184745.html On Tue, Mar 24, 2009 at 7:16 AM, Marie Sivertsen wrote: > Dear useRs, > > I have a collection of source file and some of these call others.  The files > are distribute among a number of directories, and to know how to call some

Re: [R] r online

2009-03-24 Thread Dirk Eddelbuettel
On 24 March 2009 at 12:06, Thomas Steiner wrote: | Hi, | I'd like to execute simple commands and functions in R through a | website, is there any service like this somewhere? | I only found http://www.osvisions.com/r-online/ but it does not work | (last update 2003) and the links to releated websi

Re: [R] Change teh datatype from factor to double

2009-03-24 Thread David Winsemius
?read.table Consult the help file for the parameters: as.is =or stringsAsFactors = -- David Winsemius On Mar 24, 2009, at 4:22 AM, Maxl18 wrote: Hi all, I want to read a .txt dataset, but when I test the type, some of the data is a factor. How can I avoid them to get a factor or how

  1   2   >