Re: [R] Different missing links on Windows in 'check' vs. 'install'

2004-03-09 Thread Prof Brian Ripley
Note that on Windows only packages in the same library are checked for links, as on Windows the HTML help cannot link across libraries. (This is done under Unix via symbolic links.) By default check installs in a private library, so you may well see (correct) reports of missing links under

[R] (no subject)

2004-03-09 Thread Andrew Abel
Hi, I keep getting this error code when I try to run an R file that reads in data from another file. I know the file is there. source(C:/R_Data/typhoon.r) Error in file(file, r) : unable to open connection In addition: Warning message: cannot open file `typhoon.txt' I hope you can help.

Re: [R] Different missing links on Windows in 'check' vs. 'install'

2004-03-09 Thread Prof Brian Ripley
On Mon, 8 Mar 2004, Duncan Murdoch wrote: On Mon, 8 Mar 2004 18:20:29 -0500 (EST), you wrote: In trying to figure out how these things are determiend, I noticed that in Windows there was a difference in the reported missing links when one does 'Rcmd check' vs 'Rcmd install' (or 'Rcmd

RE: [R] Decision Trees

2004-03-09 Thread Ko-Kang Kevin Wang
Hi, -Original Message- WEKA includes a re-implementation of the ideas behind C4.5, but not C4.5. If my memory serves me right, WEKA people called this re-implementation J4.8. Kevin Ko-Kang Kevin Wang, MSc(Hon) Statistics Workshops

Re: [R] Monte Carlo p-value (was question)

2004-03-09 Thread Prof Brian Ripley
1/(B+1) is the significance level of the Monte Carlo test if the data give the most extreme value. (E.g. Ripley, 1987, p. 171.) This is a calculation, not a convention, and assumes a continuously distributed statistic. On Mon, 8 Mar 2004, Spencer Graves wrote: What is the standard

Re: [R] Am failing on making lagged residual after regression

2004-03-09 Thread Prof Brian Ripley
If you have missing data in your data frame and want residuals for all observations, you need to use na.action=na.exclude, not the default na.omit. As for lag, its description says Description: Compute a lagged version of a time series, shifting the time base back by a given number

[R] maxima

2004-03-09 Thread Z P
Dear all, suppose I have a bi-variate function f(x,y), I want to find the maxima. I define x and y vector, and get matrix z=f(x,y). how can I get which (x0,y0) makes z become the maxima? I can do two loops to get the x0 and y0, but I think there may exist a function to do this.

[R] SVM unbalanced classes

2004-03-09 Thread Frank Gerrit Zoellner
Hi! I am using R 1.8.1 and the svm of the e1071 package for classification. The problem is that I have unbalanced classes e.g. the first one is much bigger than the second one and therfore the svm is biased to the first class. If I manually adjust the class size the bias disappears. The question

RE: [R] (no subject)

2004-03-09 Thread Liaw, Andy
Make sure you either use full path to `typhoon.txt' as you did with `typhoon.r', or setwd() to the directory where `typhoon.txt' lives before reading it. [Please use an informative subject for your message.] Andy From: Andrew Abel Hi, I keep getting this error code when I try to run an R

Re: [R] (no subject)

2004-03-09 Thread asemeria
May be you aren't on the right working dir: getwd(),setwd(). Your R-script are able to find the thyphoon.txt path? Best! A.S. Alessandro Semeria Models and Simulations Laboratory Montecatini Environmental Research Center (Edison Group), Via Ciro Menotti 48,

Re: [R] SVM unbalanced classes

2004-03-09 Thread Christian Schulz
Hi, SVM have got the option class.weights to put the apriori-distribution for your target variable. To oversample, or undersample a specific class you have imho write a own function!? Perhaps it helps ,christian Am Dienstag, 9. März 2004 11:29 schrieb Frank Gerrit Zoellner: Hi! I am

Re: [R] Different missing links on Windows in 'check' vs. 'install'

2004-03-09 Thread Duncan Murdoch
On Tue, 9 Mar 2004 08:03:44 + (GMT), you wrote: No, both will find links in the same library as installing into (plus those which are fixed up on installation, e.g. to the base package). Several of us have looked for years for a fix, and this is the best scheme we have come up with. You

[R] asking for information

2004-03-09 Thread Miguel Ángel Gómez-Nieto
Dear Sir: I am interesting in to use some R functions in some of our developments. But I have a problem which I have not found information in R documentation, for that I ask for help. Can I to call R functions from a C (or another language) program ?. ANd if the answer if yes, could you help

[R] levelplot problems !!!

2004-03-09 Thread Hernan Dopazo
Dear R users, I have changed my R version to the new 1.8.1 and some problems appears when using the previous levelplot code. This is a simple example: a -1:10 b -11:20 j - rnorm(100) grid-expand.grid(a = a, b = b) levelplot(j~a*b, grid) Normaly in my previous vs this was suffice to produce

RE: [R] error() and C++ destructors

2004-03-09 Thread Lennart . Borgman
I am sending this reply on behalf of Erik (who is not a member of this list). - Lennart -Original Message- From: Källen, Erik Sent: 9 mars 2004 11:37 To: Borgman, Lennart Subject: RE: [R] error() and C++ destructors I would do something like: class error_exception { public:

Re: [R] asking for information

2004-03-09 Thread Angel Lopez
Hola, Yes you can call R from C and viceversa, you should read the manual Writing R extensions: available in the section manuals from the r-project website http://cran.r-project.org/doc/manuals/R-exts.pdf Suerte, Angel Miguel Ángel Gómez-Nieto wrote: Dear Sir: I am interesting in to use some R

RE: [R] error() and C++ destructors

2004-03-09 Thread Lennart . Borgman
And maybe I stressed Erik a bit, because he corrected himself some minutes later (when I was no longer looking over his shoulder). Again on behalf of Erik. - Lennart -Original Message- From: Källen, Erik Sent: 9 mars 2004 13:40 To: Borgman, Lennart Subject: RE: [R] error() and C++

Re: [R] Different missing links on Windows in 'check' vs. 'install'

2004-03-09 Thread Robert Gentleman
On Tue, Mar 09, 2004 at 12:38:33PM +, Prof Brian Ripley wrote: On Tue, 9 Mar 2004, Duncan Murdoch wrote: On Tue, 9 Mar 2004 08:03:44 + (GMT), you wrote: No, both will find links in the same library as installing into (plus those which are fixed up on installation, e.g. to the

Re: [R] memory problem

2004-03-09 Thread James MacDonald
How many chips you can read is a function of how much RAM you have and what chip it is. On a unix/linux box you will be able to read in and process 143 of the HG-u95aV2 chips if you have about 2 Gb RAM. For the larger U133A chips (RAE/MOE are about the same size), you will probably need almost

[R] SVM unbalanced classes

2004-03-09 Thread David Meyer
You might consider using the `weight' argument of svm(). Best, David. Hi! I am using R 1.8.1 and the svm of the e1071 package for classification. The problem is that I have unbalanced classes e.g. the first one is much bigger than the second one and therfore the svm is biased to the first

Re: [R] levelplot problems !!!

2004-03-09 Thread Martin Maechler
Hernan == Hernan Dopazo [EMAIL PROTECTED] on Tue, 9 Mar 2004 12:46:51 +0100 writes: Hernan Dear R users, Hernan I have changed my R version to the new 1.8.1 and some problems appears when Hernan using the previous levelplot code. Hernan This is a simple example: after

Re: [R] levelplot problems !!!

2004-03-09 Thread Deepayan Sarkar
On Tuesday 09 March 2004 05:46, Hernan Dopazo wrote: Dear R users, I have changed my R version to the new 1.8.1 and some problems appears when using the previous levelplot code. This is a simple example: a -1:10 b -11:20 j - rnorm(100) grid-expand.grid(a = a, b = b) levelplot(j~a*b,

[R] Package cclust error

2004-03-09 Thread Sebastien Durand
Hello, here is my problem, After looking at the mail archives, I found a description of the error I get when I use this package. At first I even tought that they were showing how to solve it. But the thing is that by saying the programmer forgot drop=FALSE doesn't show me how I should get

[R] New Ranking Scheme - Help

2004-03-09 Thread S P
Hi all, I am a biostatistician and I have developed my own ranking system for clinical data. I would like to test the efficiency of it w.r.t. to other ranking systems. I would like to simulate the data and after assigning ranks to my observed scores(after neglecting dropouts), observe the type I

[R] aic calculation

2004-03-09 Thread Stephen Dicey
hello, could somebody refer me to the reason R uses -2*loglik + 2*(#param)+2 to calculate AIC? thank you -- Stoyan Iliev __ [EMAIL PROTECTED] mailing list https://www.stat.math.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide!

[R] Significance of differences in RMS?

2004-03-09 Thread Jonas Beskow
Greetings, I have the following problem: I want to compare a parameter trajectory, i.e. a series of real numbers (representing equidistant samples of a time-varying parameter) produced by some model, to a reference trajectory, measured from the real world, in order to get a rating of how good

[R] How to ascertain the number of clusters automatically?

2004-03-09 Thread Fucang Jia
Hi, everyone, There is many small cells which can be classified into several big cells from the scanned image. K-means clustering does not work well in this condition. I have done hierarchical clustering on cells successfully which uses shortest distance between classes. The number of clusters

Re: [R] aic calculation

2004-03-09 Thread Prof Brian Ripley
AIC is calculated in many places in R, but I do not believe any use that formula. Here is a guess as to your confusion: in linear models there are p coefficients plus sigma^2 to be estimated and hence there is often an extra 2 associated with the scale parameter. For example, in

Re: [R] aic calculation

2004-03-09 Thread Jens Schumacher
R calculates AIC = -2*loglik + 2*(#param) but you probably missed the variance parameter when counting the parameters. Jens Schumacher -- Dr. Jens Schumacher Max-Planck-Institut f. Biogeochemie Winzerlaer Str. 10 D-07745 Jena Germany Tel: +49

[R] use of split lines in ess

2004-03-09 Thread David Andel
Hi all I am very astonished that R generates a syntax error when I want to split up a line with a backslash, which usually works in any shell script. R itself generates the + symbols at the beginning of following lines in a splitted line so I've tried with them as well, but also without

Re: [R] aic calculation

2004-03-09 Thread Spencer Graves
That quantity is called the Akaike Information Criterion. It dates back to original work of Akaike. For more recent discussions and citations to earlier literature see, e.g.: Brian Ripley (1996) Pattern Recognition and Neural Networks (Cambridge U. Pr.) Burnham and Anderson

Re: [R] use of split lines in ess

2004-03-09 Thread Douglas Bates
David Andel [EMAIL PROTECTED] writes: I am very astonished that R generates a syntax error when I want to split up a line with a backslash, which usually works in any shell script. One way to diminish the astonishment factor when using software is to try reading the documentation. :-) The

Re: [R] Different missing links on Windows in 'check' vs. 'install'

2004-03-09 Thread Duncan Murdoch
On Tue, 9 Mar 2004 12:38:33 + (GMT), Prof Brian Ripley [EMAIL PROTECTED] wrote : On Tue, 9 Mar 2004, Duncan Murdoch wrote: Here's a proposal: All of check and build and install should default to the same library location. Check and build aren't meant to be permanent installs, so if the

[R] Error message - what does it mean???

2004-03-09 Thread Monica Palaseanu-Lovejoy
Hi, I am trying to calculate mahalanobis distances for a matrix x with n*p variables. I am getting the following error: md2 - mahalanobis(x, center, cov) Error in solve.default(cov, tol = tol.inv) : system is computationally singular: reciprocal condition number = 2.11165e-009 What

[R] R and tmp directroy

2004-03-09 Thread Martin Olivier
Hi all, When I start R, it gives mkdir: Ne peut créer le répertoire `/home/mart/tmp/Rtmp11729'.: No such file or directory (I specify that my home path is /home/mart and the R version is 1.7.1) How I have to configure R to use the directory /tmp instead of /home/mart/tmp ? What is utility of

Re: [R] Error message - what does it mean???

2004-03-09 Thread Prof Brian Ripley
On Tue, 9 Mar 2004, Monica Palaseanu-Lovejoy wrote: Hi, I am trying to calculate mahalanobis distances for a matrix x with n*p variables. I am getting the following error: md2 - mahalanobis(x, center, cov) Error in solve.default(cov, tol = tol.inv) : system is computationally

[R] how to use conditional statements to handle exceptions?

2004-03-09 Thread Susan Lin
Hello, I have a problem to handle the following statements. for(i in [1:3]) { file=paste(file, i, .dat) bb - read.table(file) x11() plot(bb) dev.off() } When the input .dat file is empty, the program stops running and an error message appears. Could someone tell me

RE: [R] Decision Trees

2004-03-09 Thread Benjamin . STABLER
Thanks for the insight. I think we will try both CART (rpart) and C4.5 (J4.8) and see what happens. As always, the R community is so helpful. Thanks, Ben -Original Message- From: Ko-Kang Kevin Wang [mailto:[EMAIL PROTECTED] Sent: Tuesday, March 09, 2004 12:08 AM To: 'Prof Brian

Re: [R] use of split lines in ess

2004-03-09 Thread A.J. Rossini
it looks like you are wondering about something with ESS. Could you be more precise about the exact conditions? Also, the ess-help mailing list might be a better place to post. Version #'s of R, and if it is an ESS problem, ESS and (X)Emacs would be useful. David Andel [EMAIL PROTECTED]

Re: [R] how to use conditional statements to handle exceptions?

2004-03-09 Thread Roger D. Peng
Take a look at try(). -roger Susan Lin wrote: Hello, I have a problem to handle the following statements. for(i in [1:3]) { file=paste(file, i, .dat) bb - read.table(file) x11() plot(bb) dev.off() } When the input .dat file is empty, the program stops running and

[R] Creating its own family

2004-03-09 Thread Stephane DRAY
Hello, I would like to create my own family for glm modelling If we consider a matrix Y, I would like to model Yij/var(Yj) with an inverse variance link. I have create my own family inspired by the negative.binomial of MASS: #

RE: [R] how to use conditional statements to handle exceptions?

2004-03-09 Thread Andy Bunn
If you mean to put a check in to see if the file exists then something like this would work: for(i in 1:3){ aFile - paste(file, i, .dat, sep = ) if(file.exists(aFile) == T){ bb - read.table(aFile, header = F) x11() plot(bb) dev.off() } } If you

Re: [R] R and tmp directroy

2004-03-09 Thread Martin Olivier
Finally, i found the answer for my question... it is only necessary to add setenv TMPDIR /tmp/ in my .cshrc Martin Olivier wrote: Hi all, When I start R, it gives mkdir: Ne peut créer le répertoire `/home/mart/tmp/Rtmp11729'.: No such file or directory (I specify that my home path is

RE: [R] error() and C++ destructors

2004-03-09 Thread Vadim Ogranovich
One shortcoming of Erik's solution is that it can only catch the exceptions of type error_exception. For example it won't work if my code calls some third party library that can throw exceptions of some other types. In case it's of interest to someone here is the boilerplate that I ended up

Re: [R] R and tmp directroy

2004-03-09 Thread Prof Brian Ripley
Probably you have TMPDIR set in your enviroment to point to /home/mart/tmp and that does not exist or is not writable. Solution: don't have variables pointing to inappropriate places? On Tue, 9 Mar 2004, Martin Olivier wrote: When I start R, it gives mkdir: Ne peut créer le répertoire

Re: [R] how to use conditional statements to handle exceptions?

2004-03-09 Thread Prof Brian Ripley
On Tue, 9 Mar 2004, Susan Lin wrote: I have a problem to handle the following statements. for(i in [1:3]) { file=paste(file, i, .dat) Don't you mean paste(file, i, .dat, sep=) ? Or are your files called `file 1 .dat'? bb - read.table(file) x11() plot(bb)

[R] read.table() question

2004-03-09 Thread Susan Lin
Hi, In the following code, I got an error meesage if an input file is empty, and the program stopped running. Could someone to tell me how to handle this problem. I want the program to keep running. Thanks. for i in [1:3] { file=paste(file, i, .dat) x - read.data(file) x(11)

Re: [R] Creating its own family

2004-03-09 Thread Prof Brian Ripley
I think you want linkfun - function(mu){mu/varcol} linkinv - function(eta){eta*varcol)} etc, that is a function of a single argument. Also, you can use lexical scope to capture varcol, as in the above: it will be in the environment of linkfun/inv. You did not set its environment as MASS

RE: [R] how to use conditional statements to handle exceptions?

2004-03-09 Thread Henrik Bengtsson
For R v1.8.0 you can use tryCatch() (it's great) to catch objects of class 'condition' and just print() them (instead of letting them generate errors) like this: for(i in 1:3) { file - paste(file, i, .dat, sep=) tryCatch({ bb - read.table(file) x11() plot(bb) dev.off() },

[R] how to continue develop package

2004-03-09 Thread Vadim Ogranovich
Hi, I have completed a prototype of a package, say FOO, and now I want to start using it as an ordinary R package, i.e. attach it via library(FOO). On the other hand I will be adding functionality and fixing bugs so the code is going to change a lot. There is a couple of problems that don't know

[R] Adding data.frames together

2004-03-09 Thread John Sweval
I have a series of data frames that are identical structurally, i.e. - made with the same code, but I need to add them together so that they become one, longer, data frame, i.e. - each of the slot vectors are increased in length by the length of the added data frame vectors. So if I have df1 with

Re: [R] years from as.POSIXlt

2004-03-09 Thread Thomas Petzoldt
Prof Brian Ripley wrote: See ?julian, which says Note: Other components such as the day of the month or the year are very easy to computes: just use 'as.POSIXlt' and extract the relevant component. Hello, unfortunately not all mentioned functions work on all machines. Where

Re: [R] Slow reshape from 5x600000 to 6311 x 132

2004-03-09 Thread Christopher Austin-Lane
Thanks for the info - it inspired me to keep tweaking. R --min-vsize=400M --min-nsize=6M allowed me to run in a few minutes - I had been trying larger values of --min-vsize (600M) (I have 1 Gig of RAM, but a lot of stuff running), but that was evidentally causing R to swap during the reshape,

RE: [R] how to continue develop package

2004-03-09 Thread Liaw, Andy
My suggestion is to treat the installed package as `binary', even if the code is purely in R. This way you will only make modifications to the _source_ and make up the `binary' as needed. It's really not burdensome. Your second question has nothing to do with ESS. When you modify objects on

Re: [R] years from as.POSIXlt

2004-03-09 Thread Thomas Petzoldt
as.numeric(format(x, f=%j)) which is the right code, works perfectly, too. Thomas P. __ [EMAIL PROTECTED] mailing list https://www.stat.math.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html

RE: [R] Adding data.frames together

2004-03-09 Thread Liaw, Andy
Use rbind() (for row-bind). Here are some examples: d1 - data.frame(x=1, y=1) d2 - data.frame(x=1:2, y=1:2) d3 - data.frame(x=3, y=3) rbind(d1,d2,d3) x y 1 1 1 11 1 1 2 2 2 12 3 3 do.call(rbind, list(d1,d2,d3)) x y 1 1 1 11 1 1 2 2 2 12 3 3 [or even this:] do.call(rbind,

[R] corARMA and ACF in nlme

2004-03-09 Thread Jeff Jorgensen
Hi R-sters, Just wondering what I might be doing wrong. I'm trying to fit a multiple linear regression model, and being ever mindful about the possibilities of autocorrelation in the errors (it's a time series), the errors appear to follow an AR1 process (ar(ts(glsfit$residuals)) selected

Re: [R] Adding data.frames together

2004-03-09 Thread Tom Blackwell
John - The function rbind() operates on pairs of data frames, and (somewhat arcane and definitely NOT for beginning users) do.call(rbind, list(df1, df2, df3, df4, df5))) will combine any number (in this case 5) of data frames. As of February 2003, the do.call() approach did not deal

Re: [R] Adding data.frames together - correction

2004-03-09 Thread Tom Blackwell
Correction to my reply below: If my memory serves correctly, one year and many projects later, I wanted to keep character data as character, not factors, throughout. The gyrations were to maintain this despite using rbind(), not because rbind() behaved badly with factors. Please excuse my

Re: [R] Adding data.frames together

2004-03-09 Thread Tony Plate
Actually, rbind() operates on any number of arguments, as stated in the documentation ?rbind. (If it only operated on pairs of arguments, the do.call() approach wouldn't get around that anyway. The do.call() approach can be very useful when one has a list of data frames to be rbind'ed

[R] accuracy of chi-square distribution approximations

2004-03-09 Thread Victoria Stodden
Hi there, How accurate is the aproximation R makes to the Chi-Square distribution? For example, if I run: qchisq(1/100,6) [1] 0.03650857 how accurate is 0.0365 compared to the theoretical percentile? What kind of approximations have been made in the software's algorithm? It woudl be

[R] How to use MLE-class?

2004-03-09 Thread YIHSU CHEN
Hi there, I had successfully use MLE function to solve my problem. Is there anyone knows how to get related information? i.e., value of likelihood function, information matrix, and etc. I know MLE-class can do it but I can not find any information tells me how to do it. Thanks a billions,

[R] Re: R-help Digest, Vol 13, Issue 9

2004-03-09 Thread David Duffy
Cédric Finet wrote: I thank you for your answer but I do not understand yet why the Fisher´s exact test does not work. And why is a negative key. Cédric Finet Running the original TOMS643 fortran code (R uses an f2c translation of this) says: FEXACT ERROR: 30 Stack length exceeded in

RE: [R] How to use MLE-class?

2004-03-09 Thread Liaw, Andy
Do you mean mle() in the package `mle'? If so, see ?mle-class for a description. Andy From: YIHSU CHEN Hi there, I had successfully use MLE function to solve my problem. Is there anyone knows how to get related information? i.e., value of likelihood function, information matrix, and

Re: [R] Adding data.frames together

2004-03-09 Thread kjetil
On 9 Mar 2004 at 14:41, John Sweval wrote: If you have the dataframes as components of a list dfs, maybe you can do something like do.call(cbind, dfs) Kjetil Halvorsen I have a series of data frames that are identical structurally, i.e. - made with the same code, but I need to add them

Re: [R] How to use MLE-class?

2004-03-09 Thread Spencer Graves
Have you read Pinheiro and Bates (2000) Mixed-Effects Models in S and S-Plus (Springer)? I learned much from that book. Also, help.search(lme) gave interesting results. hope this helps. spencer graves YIHSU CHEN wrote: Hi there, I had successfully use MLE function to solve my

[R] AutoResponse - Email Returned SAXK (KMM44933619V84198L0KM)

2004-03-09 Thread PayPal Customer Service 1
Thank you for contacting PayPal Customer Service. In an effort to assist you as quickly and efficiently as possible, please direct all customer service inquires through our website. Click on the hyperlink below to go to the PayPal website. After entering your email address and password

[R] Rcmd BATCH command line arguments

2004-03-09 Thread Benjamin . STABLER
I want to run Rcmd BATCH with R_DEFAULT_PACKAGE=base so it doesn't load any packages, but it seems to reject this argument because it does not start with a '-' or '--'. Is there a different argument that will work? Thanks. Benjamin Stabler Transportation Planning Analysis Unit Oregon Department

Re: [R] years from as.POSIXlt

2004-03-09 Thread Gabor Grothendieck
If you search the mail archives for fromchar there are a number of discussions of similar bugs that all seem to come from German or other European users, suggesting locale problems. I suspect it won't be easy for others to reproduce this so you might try to see what you can track down

Re: [R] years from as.POSIXlt

2004-03-09 Thread Prof Brian Ripley
On Wed, 10 Mar 2004, Thomas Petzoldt wrote: as.numeric(format(x, f=%j)) which is the right code, works perfectly, too. but the recommended procedure is on the help page ?julian, and of course works perfectly. Just use 1+x$yday if you want 1-based day of the year. -- Brian D. Ripley,

[R] help

2004-03-09 Thread Christine Tuleau
Hello, I am a new member, and I need your help. For my work (thesis), I use the package rpart to construct trees. But, to continu my studies, I need to calcule the 'variable importance'. But, I don't find a program to do this in the implementation of R. Is there someone who know if there exist

Re: [R] years from as.POSIXlt

2004-03-09 Thread Prof Brian Ripley
On Wed, 10 Mar 2004, Thomas Petzoldt wrote: (without copying me) Prof Brian Ripley wrote: See ?julian, which says Note: Other components such as the day of the month or the year are very easy to computes: just use 'as.POSIXlt' and extract the relevant