Re: [R] Problem with starting and using R

2008-09-08 Thread Prof Brian Ripley
This reflects a problem in your locale (traditional Chinese): we cannot reproduce it. Try running R in a different locale (e.g. append LC_ALL=en to the target when you start R). On Sun, 7 Sep 2008, Thomas Lo wrote: Dear all, I encountered a problem on starting and using the R v 2.7.2

Re: [R] extracting max row from data matrix

2008-09-08 Thread Shubha Vishwanath Karanth
aggregate(x$weight,list(x$fruit),max) Group.1 x 1 apple 1.6 2 orange 1.6 Shubha Karanth | Amba Research Ph +91 80 3980 8031 | Mob +91 94 4886 4510 Bangalore * Colombo * London * New York * San José * Singapore * www.ambaresearch.com -Original Message- From: [EMAIL PROTECTED]

[R] ROC curve from logistic regression

2008-09-08 Thread gallon li
I know how to compute the ROC curve and the empirical AUC from the logistic regression after fitting the model. But here is my question, how can I compute the standard error for the AUC estimator resulting form logistic regression? The variance should be more complicated than AUC based on known

[R] How to preserve date format while aggregating

2008-09-08 Thread Erich Studerus
Hi I have a dataframe in which some subjects appear in more than one row. I want to extract the subject-rows which have the minimum date per subject. I tried the following aggregate function. attach(dataframe.xy) aggregate(Date,list(SubjectID),min) Unfortunately, the format of the Date-column

[R] Check out my Facebook profile

2008-09-08 Thread Giovanna Menardi
I set up a Facebook profile where I can post my pictures, videos and events and I want to add you as a friend so you can see it. First, you need to join Facebook! Once you join, you can also create your own profile. Thanks, Giovanna Here's the link:

[R] To find vector X under contraints

2008-09-08 Thread Shubha Vishwanath Karanth
Hi R, I have the variance-covariance matrix, V=matrix(c(0.09238, 0.002407527, 0.002407527, 0.020739401),2,2) I need to find a vector X=c(x1,x2), such that 1) X'VX is equal to a constant 2 (say) and 2) sum(x) should be equal to a another constant 1.5 (say). How do we do this

Re: [R] Problem with starting and using R

2008-09-08 Thread Prof Brian Ripley
On Mon, 8 Sep 2008, Prof Brian Ripley wrote: This reflects a problem in your locale (traditional Chinese): we cannot reproduce it. Try running R in a different locale (e.g. append LC_ALL=en to the target when you start R). Maybe I have found this as a bug in iconv. Please try a version of

Re: [R] another XML package question

2008-09-08 Thread Duncan Temple Lang
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Antje wrote: Hi there, does anybody know how to return the xmlPath from a node? For example, at several location in the xml file, I have nodes with the same name and I'd like to process only the nodes from a certain path. Any idea? As with

Re: [R] Problem with starting and using R

2008-09-08 Thread Prof Brian Ripley
On Mon, 8 Sep 2008, Duncan Murdoch wrote: On 08/09/2008 6:56 AM, Prof Brian Ripley wrote: On Mon, 8 Sep 2008, Prof Brian Ripley wrote: This reflects a problem in your locale (traditional Chinese): we cannot reproduce it. Try running R in a different locale (e.g. append LC_ALL=en to the

Re: [R] doubt

2008-09-08 Thread Uwe Ligges
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code. Uwe Ligges Kurapati, Ravichandra (Ravichandra) wrote: Hi Lets say Main(){

Re: [R] To find vector X under contraints

2008-09-08 Thread Uwe Ligges
Shubha Vishwanath Karanth wrote: Hi R, I have the variance-covariance matrix, V=matrix(c(0.09238, 0.002407527, 0.002407527, 0.020739401),2,2) I need to find a vector X=c(x1,x2), such that 1) X'VX is equal to a constant 2 (say) and 2) sum(x) should be equal to a another

[R] non-negative least squares

2008-09-08 Thread Terry Therneau
I have a problem whose solution requires non-negative least squares. That is minimize sum(y - Xbeta)^2 subject to beta =0 Splus has the nnls.fit command. Is there an R alternative? Terry Therneau __ R-help@r-project.org

[R] free workspace

2008-09-08 Thread GAF
Hi there, I have a very basic but still important question: How can I free my workspace COMPLETELY? I tried: rm(list = ls()) rm(list=ls(all=TRUE)) remove(list = conflicts(detail=TRUE)$.GlobalEnv) but I still have lots of conflicts() which I have never seen before. Thanx for the help. -- View

Re: [R] Question for help

2008-09-08 Thread Uwe Ligges
93354504 wrote: clotting - data.frame(u = c(5,10,15,20,30,40,60,80,100), lot1 = c(118,58,42,35,27,25,21,19,18), lot2 = c(69,35,26,21,18,16,13,12,12)); lot=c(clotting$lot1,clotting$lot2); uu=c(clotting$u,clotting$u); x=uu; y=lot; n=length(y); x=cbind(rep(1,n),x); c=2;

Re: [R] Problem with starting and using R

2008-09-08 Thread Duncan Murdoch
On 08/09/2008 6:56 AM, Prof Brian Ripley wrote: On Mon, 8 Sep 2008, Prof Brian Ripley wrote: This reflects a problem in your locale (traditional Chinese): we cannot reproduce it. Try running R in a different locale (e.g. append LC_ALL=en to the target when you start R). Maybe I have found

[R] help with R memory

2008-09-08 Thread shamsuk
Hi There! I am trying to read a grid file (.asc) file with readGDAL (library[rgdal]). The file has 7541 rows and 5247 columns and a size of 177 Mb. My laptop has 2 Gb of RAM and 150 Gb of total hard disk memory. Is it possible to open this raster file in R at all? Thanks, Shams -- View this

Re: [R] non-negative least squares

2008-09-08 Thread Tobias Verbeke
Terry Therneau wrote: I have a problem whose solution requires non-negative least squares. That is minimize sum(y - Xbeta)^2 subject to beta =0 Splus has the nnls.fit command. Is there an R alternative? There is a package nnls on CRAN by Kate Mullen and Ivo van Stokkum:

[R] doubt

2008-09-08 Thread Kurapati, Ravichandra (Ravichandra)
Hi Lets say Main(){ Fcaproxy(user=ravi,password=db,database=oracle,host=10.0.0.3) } Fcaproxy -Function(...,importlimit=){ Dbproxy(...) }

[R] another XML package question

2008-09-08 Thread Antje
Hi there, does anybody know how to return the xmlPath from a node? For example, at several location in the xml file, I have nodes with the same name and I'd like to process only the nodes from a certain path. Any idea? Antje __

[R] Question for help

2008-09-08 Thread 93354504
clotting - data.frame(u = c(5,10,15,20,30,40,60,80,100), lot1 = c(118,58,42,35,27,25,21,19,18), lot2 = c(69,35,26,21,18,16,13,12,12)); lot=c(clotting$lot1,clotting$lot2); uu=c(clotting$u,clotting$u); x=uu; y=lot; n=length(y); x=cbind(rep(1,n),x); c=2; neg_loglikehood=function(theta){

Re: [R] free workspace

2008-09-08 Thread Duncan Murdoch
On 08/09/2008 5:59 AM, GAF wrote: Hi there, I have a very basic but still important question: How can I free my workspace COMPLETELY? I tried: rm(list = ls()) rm(list=ls(all=TRUE)) remove(list = conflicts(detail=TRUE)$.GlobalEnv) but I still have lots of conflicts() which I have never seen

Re: [R] ROC curve from logistic regression

2008-09-08 Thread Frank E Harrell Jr
gallon li wrote: I know how to compute the ROC curve and the empirical AUC from the logistic regression after fitting the model. But here is my question, how can I compute the standard error for the AUC estimator resulting form logistic regression? The variance should be more complicated than

Re: [R] How to preserve date format while aggregating

2008-09-08 Thread jim holtman
Try changing the 'class' of the numeric result back to Date: x - as.Date('2008-09-08') x [1] 2008-09-08 y - as.numeric(x) y [1] 14130 str(y) num 14130 class(y) - Date y [1] 2008-09-08 str(y) Class 'Date' num 14130 On Mon, Sep 8, 2008 at 6:38 AM, Erich Studerus [EMAIL PROTECTED]

Re: [R] How to preserve date format while aggregating

2008-09-08 Thread Erich Studerus
Thanks, I've already tried that. The problem is, that the original date is not restored when I change the numeric back to date. I get a totally different date. Maybe it has something to do with the original date format. My data are directly imported from a SQL-database. The date column to which I

Re: [R] How to preserve date format while aggregating

2008-09-08 Thread jim holtman
Can you provide some actual data. It sounds like the columns you are are POSIXct, in which case you would want to do something like this: time - structure(time, class = c(POSIXt, POSIXct)) So it is important to know what your numeric values came from and what their actual values were. Which of

Re: [R] ROC curve from logistic regression

2008-09-08 Thread Pedro.Rodriguez
Hi Try the following reference: Comparison of Three Methods for Estimating the Standard Error of the Area under the Curve in ROC Analysis of Quantitative Data by Hajian-Tilaki and Hanley, Academic Radiology, Vol 9, No 11, November 2002. Below is a simple implementation that will return both the

Re: [R] another XML package question

2008-09-08 Thread Antje
Hi Duncan, thanks a lot for your explanations. I tried the following now to understand a bit more: data - getNodeSet(doc, //Data) xmlName(data[[1]]) xmlName(xmlRoot(data[[1]])) xpathApply(data[[1]], ./*, xmlName) Is it right that using data in the xpathApply() somehow sets the current node

Re: [R] ROC curve from logistic regression

2008-09-08 Thread Jorge Ivan Velez
Hi there, See ?lroc in the epicalc package. HTH, Jorge On Mon, Sep 8, 2008 at 4:02 AM, gallon li [EMAIL PROTECTED] wrote: I know how to compute the ROC curve and the empirical AUC from the logistic regression after fitting the model. But here is my question, how can I compute the

Re: [R] How to preserve date format while aggregating

2008-09-08 Thread Dr Eberhard Lisse
Erich, how does the data look, when it comes from SQL? And why not extract the data with SQL directly, so you don't have this issue in the first place? el on 9/8/08 3:15 PM Erich Studerus said the following: Thanks, I've already tried that. The problem is, that the original date is not

Re: [R] How to preserve date format while aggregating

2008-09-08 Thread Erich Studerus
Here's how the dates look like after the sql-query: Oav$Date[1:3] [1] 1991-11-22 00:45:00 CET 1991-12-13 00:01:00 CET 1992-02-06 00:45:00 CET class(oav$Date[1:3]) [1] POSIXt POSIXct x-as.numeric(oav$Date[1:3]) x [1] 690767100 692578860 697333500 class(x)-Date x [1] 3226-01-31 8186-07-07

Re: [R] free workspace

2008-09-08 Thread GAF
thanx for the quick reply! so this is what I get when I type in conflicts() [1] part buzz distance huid in_whistle interruptionsmatch [8] overlap part part_2 pause_dur pause_dur2

Re: [R] How to preserve date format while aggregating

2008-09-08 Thread Prof Brian Ripley
Those are not dates! They are date-times. aggregate is overkill for a single column. Something simple like DT - seq(Sys.time(), by=4 hours, len=24) grp - rbinom(24, 1, p=0.5) res - tapply(DT, grp, min) class(res) - class(DT) res would suffice. On Mon, 8 Sep 2008, Erich Studerus wrote:

Re: [R] free workspace

2008-09-08 Thread Duncan Murdoch
On 08/09/2008 7:45 AM, GAF wrote: thanx for the quick reply! so this is what I get when I type in conflicts() [1] part buzz distance huid in_whistle interruptionsmatch [8] overlap part part_2

[R] Saving functions

2008-09-08 Thread Williams, Robin
Hi, Appologies for the simple nature of this question, I am unable to find the answer in manuals (EG and introduciton to R). I have written a function in a text editor and saved it with an .R extension. It is saved in my working directory. How can I run it, do I need to use source? If so,

Re: [R] Saving functions

2008-09-08 Thread jim holtman
You can 'source' it in to define it and then call it as usual. No particular directory since you have control of that with the 'source' function. File extension is by convention and anyone will work since source is just going to read in an text file and execute it. On Mon, Sep 8, 2008 at 10:46

Re: [R] Saving functions

2008-09-08 Thread Marianne Promberger
On Monday, 08 September 2008, 15:46 (UTC+0100), Williams, Robin wrote: I have written a function in a text editor and saved it with an .R extension. It is saved in my working directory. How can I run it, do I need to use source? Just to add to Jim's reply: if you want to have this

Re: [R] another XML package question

2008-09-08 Thread Duncan Temple Lang
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Antje wrote: Hi Duncan, thanks a lot for your explanations. I tried the following now to understand a bit more: data - getNodeSet(doc, //Data) xmlName(data[[1]]) xmlName(xmlRoot(data[[1]])) xpathApply(data[[1]], ./*, xmlName) Is it

Re: [R] another XML package question

2008-09-08 Thread Antje
Duncan Temple Lang schrieb: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Antje wrote: Hi Duncan, thanks a lot for your explanations. I tried the following now to understand a bit more: data - getNodeSet(doc, //Data) xmlName(data[[1]]) xmlName(xmlRoot(data[[1]])) xpathApply(data[[1]],

[R] Vorticity and Divergence

2008-09-08 Thread Igor Oliveira
Hi all, I have some wind data (U and V components) and I would like to compute Vorticity and Divergence of these fields. Is there any R function that can easily do that? Thanks in advance for any help Igor Oliveira CSAG, Dept. Environmental Geographical Science, University of Cape Town,

[R] (no subject)

2008-09-08 Thread Jason Thibodeau
Hello all, I have a very large file (280k lines) containing three comma separated variables. The first variable is a 0 or 1 depicting a pass or fail. The other two are X and Y coordinates. Is there a good way I can represent this data in a chart/plot form other than using a 3d histogram? If I

Re: [R] (no subject)

2008-09-08 Thread Jason Thibodeau
I apologize, I forgot to type the title. On Mon, Sep 8, 2008 at 11:39 AM, Jason Thibodeau [EMAIL PROTECTED]wrote: Hello all, I have a very large file (280k lines) containing three comma separated variables. The first variable is a 0 or 1 depicting a pass or fail. The other two are X and Y

Re: [R] problem with Hmisc

2008-09-08 Thread Charles Dupont
Bob Flagg wrote: Dear All, I'm reading Frank Harrell's wonderful Regression Modeling Strategies book and ran into a problem following the example in Chapter 8. I'm working on platform: Ubuntu 8.04 (i486-pc-linux-gnu) R version: 2.7.2 (2008-08-25) and my command sequence was:

Re: [R] How to preserve date format while aggregating

2008-09-08 Thread Gabor Grothendieck
As requested in the last line to every message to r-help a cutdown version of the data should be posted with the question. Suppose such a cut down version is this: DF - data.frame(Date = ISOdatetime(2008, 1, c(1, 2, 5, 3, 4), 0, 0, 0), Subject = c(1, 1, 2, 2, 2)) # Then sort the data

[R] Question about multiple regression

2008-09-08 Thread Dimitri Liakhovitski
Dear R-list, maybe some of you could point me in the right direction: Are you aware of any FREE Fortran or Java libraries/actual pieces of code that are VERY efficient (time-wise) in running the regular linear least-squares multiple regression? More specifically, I have to run small regression

Re: [R] plot a list

2008-09-08 Thread stephen sefick
I have one more question. The below example is revised to better reflect the problem that I am running into. The two columns for each data frame in the list are named the same because they are subsets of the same site, which has the same name in the larger data set. So when xyplot plots the

Re: [R] Question about multiple regression

2008-09-08 Thread Gabor Grothendieck
I would test the speed before making such as assumption. Note that lm.fit is faster than lm and if they have the same x matrix then you can do many in one call by having y be a matrix. On Mon, Sep 8, 2008 at 12:05 PM, Dimitri Liakhovitski [EMAIL PROTECTED] wrote: Dear R-list, maybe some of you

Re: [R] Problem with starting and using R

2008-09-08 Thread Thomas Lo
Hi Brian and Duncan, Many thanks for your responses. Setting the 'Current format' in 'Regional and language options' under Control Panel to English (Singapore) solved the R usage problem for me. I will have a go at R-patched build 46507 after it is released. Regards, Thomas On Mon, Sep 8,

[R] question on extracting binary data from pdf image

2008-09-08 Thread Li, Xiaochun
Dear List, If I use the following code to generate a pdf, pdf(filename) image(x, y, !is.na(z), col=c(green,black)) dev.off() Can someone extract the 0-1 data (that is, is.na(z)) from the Adobe source? Thank you. Xiaochun [[alternative HTML version deleted]]

Re: [R] plot a list

2008-09-08 Thread Gabor Grothendieck
Add this after the zm- statement colnames(zm) - sapply(z.l, colnames) On Mon, Sep 8, 2008 at 12:09 PM, stephen sefick [EMAIL PROTECTED] wrote: I have one more question. The below example is revised to better reflect the problem that I am running into. The two columns for each data frame in

Re: [R] question on extracting binary data from pdf image

2008-09-08 Thread Prof Brian Ripley
On Mon, 8 Sep 2008, Li, Xiaochun wrote: Dear List, If I use the following code to generate a pdf, pdf(filename) image(x, y, !is.na(z), col=c(green,black)) dev.off() Can someone extract the 0-1 data (that is, is.na(z)) from the Adobe source? Yes (from the PDF file, which is not due to Adobe

Re: [R] Question about multiple regression

2008-09-08 Thread Prof Brian Ripley
Are you sure R's ways are not fast enough (there are many layers underneath lm)? For an example of how you might do this at C/Fortran level, see the function lqs() in MASS. On Mon, 8 Sep 2008, Dimitri Liakhovitski wrote: Dear R-list, maybe some of you could point me in the right direction:

Re: [R] Question about multiple regression

2008-09-08 Thread Dimitri Liakhovitski
Thank you for reminding me, Gabor. I forgot to mention: So far, I have run one test set of regressions using lm. It took R 270 sec. I need to run 1,800,000 of those, which would imply 15.4 years of computing time :) I have not done the same for lm.fit because I am not sure how to get model R

Re: [R] Question about multiple regression

2008-09-08 Thread Dimitri Liakhovitski
Yes, see my previous e-mail on how long R takes (270 seconds for one of the 1,800,000 sets I need) - using system.time. Not sure how to test the same for Fortran... On Mon, Sep 8, 2008 at 12:51 PM, Prof Brian Ripley [EMAIL PROTECTED] wrote: Are you sure R's ways are not fast enough (there are

[R] RMPI Question

2008-09-08 Thread tolga . i . uzuner
Dear R Users, I have a relatively simple rmpi question. My configation is: - R version 2.7.2 - rmpi 0.5-6 - Deino MPI 1.1.0 - Windows XP SP2 After succesfully spawning slaves, I am trying to assign values to variables in the environment of each slave and run some simple calcs. This appears

[R] fft: characteristic function to distribution

2008-09-08 Thread Jindan Zhou
Hello members! This question had been posted by Thomas Steiner in May, but I couldn't locate any followups thereafter, see: https://stat.ethz.ch/pipermail/r-help/2008-May/161483.html I want to raise up this question in a (hopefully) even simpler way: Given a random variable X, it's

Re: [R] Question about multiple regression

2008-09-08 Thread Bert Gunter
Disclaimer: I have **NO IDEA** of the details of what you want to do or why -- but I am willing to bet that there are better ways of doing it than 1.8 mm multiple refressions that take 270 secs each!! (which I find difficult to believe in itself -- are you sure you are doing things right?

Re: [R] Plot of large dataset

2008-09-08 Thread Duncan Murdoch
I'd start with scatterplots of the two subsets (pass vs fail), but with 280k points, those are likely to be fairly uninformative masses of black ink). However, there might be enough separation between them that you don't need anything else. If not, then a pair of hexbin plots (from the

Re: [R] how to draw a vertical line from points to x-axis

2008-09-08 Thread Nair, Murlidharan T
Anny, You can also do the following plot(0:10, 0:10, pch=16, type=h) Cheers../Murli -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Peter Alspach Sent: Sunday, September 07, 2008 5:10 PM To: Anny Huang; r-help@r-project.org Subject: Re: [R] how to draw

Re: [R] Question about multiple regression

2008-09-08 Thread Gabor Grothendieck
Try: sum(lm.fit(x, y)$residuals^2) On Mon, Sep 8, 2008 at 12:52 PM, Dimitri Liakhovitski [EMAIL PROTECTED] wrote: Thank you for reminding me, Gabor. I forgot to mention: So far, I have run one test set of regressions using lm. It took R 270 sec. I need to run 1,800,000 of those, which would

[R] Sort (indices only)

2008-09-08 Thread rkevinburton
I am using the function 'spectrum'. It returns two arrays that are interesting to me. One would be the wieght or density of a given frequency with the irequency given in another array. I would like to take the top 'n' weights which would be the top 'n' frequencies contributing to the signal.

Re: [R] (no subject)

2008-09-08 Thread milton ruser
Dear Jason, If I understood, you are looking for a way of represent a response surface. I know that there are other very interesting (and most indicated) solutions, but give a look at the akima package Best wishes, miltinho astronauta brazil === x-runif(100) y-rnorm(100)

Re: [R] Question about multiple regression

2008-09-08 Thread Dimitri Liakhovitski
Thank you everyone for your responses. I'll answer several questions. 1. Disclaimer: I have **NO IDEA** of the details of what you want to do or why -- but I am willing to bet that there are better ways of doing it than 1.8 mm multiple refressions that take 270 secs each!! (which I find

Re: [R] Question about multiple regression

2008-09-08 Thread Gabor Grothendieck
On Mon, Sep 8, 2008 at 1:47 PM, Dimitri Liakhovitski [EMAIL PROTECTED] wrote: Thank you everyone for your responses. I'll answer several questions. 1. Disclaimer: I have **NO IDEA** of the details of what you want to do or why -- but I am willing to bet that there are better ways of doing

[R] Beginner graphics device questions.

2008-09-08 Thread rkevinburton
Please forgive me if this has been asked before but I could not readily find an answer. First, from the example I was able to determine that graphics device commands such as plot can be redirected using 'png' and 'bmp' type commands. I tried this and it works as I understand it. The question is

Re: [R] Sort (indices only)

2008-09-08 Thread jim holtman
?order This will give you the indices that you can use. On Mon, Sep 8, 2008 at 1:38 PM, [EMAIL PROTECTED] wrote: I am using the function 'spectrum'. It returns two arrays that are interesting to me. One would be the wieght or density of a given frequency with the irequency given in another

[R] Read from url requiring authentication?

2008-09-08 Thread Damien
Hi all, I'm looking into opening an url on a server which requires authentication. After failing to find some kind of connection structure to fill in I turned to explicitly stating the credentials in the url itself (e.g. http://username:[EMAIL PROTECTED]). Sadly this didn't do the trick either

[R] mixed model MANCOVA

2008-09-08 Thread Erika Crispo
Hello, I need to perform a mixed-model (with nesting) MANCOVA, using Type III sums of squares. I know how to perform each of these types of tests individually, but I am not sure if performing a mixed-model MANCOVA is possible. Please let me know. Erika Erika

Re: [R] Articles about comparision between R and others softwares

2008-09-08 Thread ricardo13
Hi, There are more articles, papers, contents about statistical tools ??? (Perfomance, packages, Usability, difficulty in handling the software. something) Thank You Ricardo -- View this message in context:

Re: [R] RMPI Question

2008-09-08 Thread Martin Morgan
Hi Tolga -- [EMAIL PROTECTED] writes: Dear R Users, I have a relatively simple rmpi question. My configation is: - R version 2.7.2 - rmpi 0.5-6 - Deino MPI 1.1.0 - Windows XP SP2 After succesfully spawning slaves, I am trying to assign values to variables in the environment of each

[R] question on extracting binary data from pdf image

2008-09-08 Thread Li, Xiaochun
Dear List, If I use the following code to generate a pdf, pdf(filename) image(x, y, !is.na(z), col=c(green,black)) dev.off() Can someone extract the 0-1 data (that is, is.na(z)) from the Adobe source? Thank you. Xiaochun [[alternative HTML version deleted]]

[R] mixed model MANCOVA

2008-09-08 Thread Erika Crispo
Hello, I need to perform a mixed-model (with nesting) MANCOVA, using Type III sums of squares. I know how to perform each of these types of tests individually, but I am not sure if performing a mixed-model MANCOVA is possible. Please let me know. Erika

Re: [R] Beginner graphics device questions.

2008-09-08 Thread Marianne Promberger
On Monday, 08 September 2008, 10:59 (UTC-0700), [EMAIL PROTECTED] wrote: If I issue another 'plot' command will it also be redirected to the 'png' device? As long as that png device is the currently active device, yes. Does dev.off essentially reset the graphics device to the

Re: [R] RMPI Question

2008-09-08 Thread tolga . i . uzuner
Dear Martin, Many thanks. This is very useful, much appreciated. Regards, Tolga Martin Morgan [EMAIL PROTECTED] 08/09/2008 19:08 To [EMAIL PROTECTED] cc r-help@r-project.org Subject Re: [R] RMPI Question Hi Tolga -- [EMAIL PROTECTED] writes: Dear R Users, I have a relatively

[R] Modulous operator?

2008-09-08 Thread rkevinburton
Is there a mod (like C '%' operator) operator in 'R'? I tried to help.search(mod) and there were too many hits for the query to be useful. Kevin __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the

Re: [R] Modulous operator?

2008-09-08 Thread Csardi Gabor
?%% Gabor On Mon, Sep 08, 2008 at 11:58:45AM -0700, [EMAIL PROTECTED] wrote: Is there a mod (like C '%' operator) operator in 'R'? I tried to help.search(mod) and there were too many hits for the query to be useful. Kevin __

Re: [R] Question about multiple regression

2008-09-08 Thread Lucke, Joseph F
Although I along with the other believe there probably is an efficient R solution, the answer to your direct question can perhaps be found at http://www.fortran.com/. The free GNU G95 fortran compiler is at http://www.g95.org/ Joe -Original Message- From: [EMAIL PROTECTED]

Re: [R] Read from url requiring authentication?

2008-09-08 Thread Prof Brian Ripley
On Mon, 8 Sep 2008, Damien wrote: Hi all, I'm looking into opening an url on a server which requires authentication. After failing to find some kind of connection structure to fill in I turned to explicitly stating the credentials in the url itself (e.g. http://username:[EMAIL PROTECTED]).

Re: [R] Modulous operator?

2008-09-08 Thread Peter Dalgaard
Csardi Gabor wrote: ?%% Yup. Notice, by the way, that modulus [sic] is ambiguous: Mod(1+1i) [1] 1.414214 46 %% 7 [1] 4 Gabor On Mon, Sep 08, 2008 at 11:58:45AM -0700, [EMAIL PROTECTED] wrote: Is there a mod (like C '%' operator) operator in 'R'? I tried to help.search(mod) and

Re: [R] Pie chart and labels

2008-09-08 Thread Jorge Ivan Velez
Dear Mark, See argument labels in ?pie. x=c(11, 15, 16, 29, 31) pie(x,labels=x,col=c('orange','green','blue','red','purple')) HTH, Jorge On Mon, Sep 8, 2008 at 3:24 PM, polishookm [EMAIL PROTECTED]wrote: With a pie chart pie(c(11, 15, 16, 29, 31)) how can I generate labels for the

Re: [R] Modulous operator?

2008-09-08 Thread rkevinburton
Thank you. I definitely did not want Mod. Kevin Peter Dalgaard [EMAIL PROTECTED] wrote: Csardi Gabor wrote: ?%% Yup. Notice, by the way, that modulus [sic] is ambiguous: Mod(1+1i) [1] 1.414214 46 %% 7 [1] 4 Gabor On Mon, Sep 08, 2008 at 11:58:45AM -0700,

Re: [R] Pie chart and labels

2008-09-08 Thread polishookm
Thanks Jorge, that's perfect. Jorge Ivan Velez wrote: Dear Mark, See argument labels in ?pie. x=c(11, 15, 16, 29, 31) pie(x,labels=x,col=c('orange','green','blue','red','purple')) HTH, Jorge On Mon, Sep 8, 2008 at 3:24 PM, polishookm [EMAIL PROTECTED] mailto:[EMAIL PROTECTED]

Re: [R] Pie chart and labels

2008-09-08 Thread Marianne Promberger
On Monday, 08 September 2008, 15:24 (UTC-0400), polishookm wrote: With a pie chart pie(c(11, 15, 16, 29, 31)) how can I generate labels for the chart, such as orange: 11 green: 15 blue: 16 red: 29 purple: 31 pie(c(11, 15, 16, 29, 31),labels=c(what,ever,you,want,duh)) ?pie would

[R] cluster/snow question

2008-09-08 Thread tolga . i . uzuner
Dear R Users, I am attempting to use the snow package for clustering. Is there a way to identfy, in the environment of each node, a rank for that node and also, the total size of the cluster ? By way of analogy, I am looking for the functions in snow equivalent to mpi.comm.rank() and

[R] Forecast for stl?

2008-09-08 Thread rkevinburton
Once the series has been decomposed into the seasonal, trend, and remainder components with stl is there a 'predict' like function that I can use this data to forecast the next 'n' values? I didn't see one in the stl documentation. So if such a function does not exist I was wondering if I could

Re: [R] Read from url requiring authentication?

2008-09-08 Thread René Sachse
Damien schrieb: I'm looking into opening an url on a server which requires authentication. Under a Windows Operating System you could try to start R with the --internet2 option. This worked in my case. Best regards Rene __ R-help@r-project.org

[R] Time Series x-axis labeling

2008-09-08 Thread KarstenW
Hello, how is it possible to plot a time series of monthly data over several years such that the x-axis shows the first letter of the month and displays a grid line at every year? I am new to R and had no real success until now. I have: library(utils) oneMonth = 1.0 / 12.0 tsData =

Re: [R] Question about multiple regression

2008-09-08 Thread Dimitri Liakhovitski
Thanks a lot, everybody! On Mon, Sep 8, 2008 at 3:11 PM, Lucke, Joseph F [EMAIL PROTECTED] wrote: Although I along with the other believe there probably is an efficient R solution, the answer to your direct question can perhaps be found at http://www.fortran.com/. The free GNU G95 fortran

Re: [R] Request for advice on character set conversions (those damn Excel files, again ...)

2008-09-08 Thread Emmanuel Charpentier
On Mon, 08 Sep 2008 01:45:51 +0200, Peter Dalgaard wrote : Emmanuel Charpentier wrote: Dear list, [ Snip ... ] This looks reasonably sane, I think. The last loop could be d[] - lapply(d, conv1, from, to), but I think that is cosmetic. You can't really do much better because there

[R] Gumbell distribution - minimum case

2008-09-08 Thread Richard Gwozdz
Hello, I would like to sample from a Gumbell (minimum) distribution. I have installed package {evd} but the Gumbell functions there appear to refer to the maximum case. Unfortunately, setting the scale parameter negative does not appear to work. Is there a separate package for the Gumbell

Re: [R] Time Series x-axis labeling

2008-09-08 Thread Gabor Grothendieck
Try this: plot(tsData, ylab=Values, xlab=Zeit, xaxt = n) axis(1, time(tsData), rep(substr(month.abb, 1, 1), length = length(tsData)), cex.axis = .3, tcl = -.5) jan - time(tsData)[cycle(tsData) == 1] # january axis(1, jan, FALSE, tcl = -1) abline(v = jan, lty = 2) and also look at the

Re: [R] Test for equality of complicatedly related average correlations

2008-09-08 Thread Adam D. I. Kramer
Hi Ralph, My approach provides the same answer by asking a different question. Effectively, my approach tests whether the difference between timepoints is larger for X than for Y (and also gives you the main effects of whether X has a higher mean than Y and whether scores increase or decrease

Re: [R] ON MAC, how to copy a plot on to Word document?

2008-09-08 Thread Adam D. I. Kramer
For what it's worth, copy/paste between R and Word 2008 works perfectly. It doesn't work at all for Word 2004...so that's at least ONE improvement (the only one I've seen) in versions of Word. --Adam On Sun, 7 Sep 2008, Stefan Evert wrote: On 7 Sep 2008, at 16:57, John Kane wrote: I think

Re: [R] Averaging 'blocks' of data

2008-09-08 Thread Adam D. I. Kramer
Hi Steve, You probably want to check out ?by or ?aggregate, maybe using (rownames(df) %/% 60) : (colnames(df) %/% 60) as your index variable. --Adam On Sun, 7 Sep 2008, Steve Murray wrote: Dear all, I have a large dataset which I hope to reduce in size, to make it more useable. I

Re: [R] ON MAC, how to copy a plot on to Word document?

2008-09-08 Thread Frank E Harrell Jr
Word in Office 2003 (and I assume Office 2007) can insert encapsulated postscript with no problems on Windows, and display the graphic fine. Does this not work with Mac? Doesn't dragging a file into Word lose the full resolution of postscript? Frank Adam D. I. Kramer wrote: For what it's

Re: [R] how to draw a vertical line from points to x-axis

2008-09-08 Thread Adam D. I. Kramer
I think you want the ?lines function. To connect a point (x,y) to the x-axis, lines(x=c(x,x),y=c(y,0)) ...draws a line from that point to the x-axis. You may also want to specify pch=c(?,),type=b where ? is the original point type (which you don't want to run over) and is the pch for theline

Re: [R] nested ANOVA with fixed and random variables missing data

2008-09-08 Thread Adam D. I. Kramer
On Mon, 8 Sep 2008, [EMAIL PROTECTED] wrote: I have a nested ANOVA, with a fixed factor tmt nested within site (random). There are missing values in the data set. aeucs, tmt and site have been defined as objects I have tried: model1=lme(aeucs~tmt,random=~1|tmt/site) I think you want

Re: [R] ON MAC, how to copy a plot on to Word document?

2008-09-08 Thread stephen sefick
word 2004 post script (plot created with postscript()) does not work but pdf graphics work on the mac. I suggest not copying and pasting because, in my expreience, the output is not as good as pdf et al. On Mon, Sep 8, 2008 at 6:19 PM, Frank E Harrell Jr [EMAIL PROTECTED] wrote: Word in Office

Re: [R] extracting max row from data matrix

2008-09-08 Thread Adam D. I. Kramer
Hi Srini, This may be as simple as tapply(weight,fruit,max) or t(that) if you want it as you specified. --Adam On Sun, 7 Sep 2008, Srinivas Iyyer wrote: dear group, i have a data matrix with some replicate items with different values. I want to extract the row with max value. for example:

Re: [R] Request for advice on character set conversions (those damn Excel files, again ...)

2008-09-08 Thread Peter Dalgaard
Emmanuel Charpentier wrote: On Mon, 08 Sep 2008 01:45:51 +0200, Peter Dalgaard wrote : Emmanuel Charpentier wrote: Dear list, [ Snip ... ] This looks reasonably sane, I think. The last loop could be d[] - lapply(d, conv1, from, to), but I think that is cosmetic.

Re: [R] How to preserve date format while aggregating

2008-09-08 Thread Adam D. I. Kramer
Hi Erich, Since min() is defined for numbers and not dates, the problem is in the min() function. min() is converting from date format to number format. Your best bet is to make this conversion explicit...such that it is reversable. So, convert the date into UTC, then UTC to seconds since

  1   2   >