[R] (sans objet)

2004-12-14 Thread francoisromain

Hello,

Just look at the examples in ?persp.
There is a function called trans3d defined in it that will traduce your 3D
coordinates to 2D, and so you will be able to draw lines with lines function.

Romain.

Corey Bradshaw a écrit :

>I've created a perspective plot using 'persp' in the graphics package.
>I'd like to add a second plane of z values to the existing plot, but I
>cannot seem to do this using 'persp'. Is there an analogue to 'lines' or
>'points' for perspectives?
>
>Corey.
>[EMAIL PROTECTED]
>
--
Romain FRANCOIS : [EMAIL PROTECTED]
page web : http://addictedtor.free.fr/  (en construction)
06 18 39 14 69 / 01 46 80 65 60
___
Etudiant en 3eme année
Institut de Statistique de l'Université de Paris (ISUP)
Filière Industrie et Services
http://www.isup.cicrp.jussieu.fr/

__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


[R] Problem with German special characters

2004-12-14 Thread Wolf, Michael
Dear list!

When using the German special characters I didn't see all characters in the 
correct way. Let's take the command

ff <- "äöüßÄÖÜ"   # (for those ones who can't see this in the correct way \"a, 
\"ö, \"ü
  # \ss (?), \"A, \"O and \"U in LaTeX commands

'ff' will show the output text "\344\366üß\304\326\334" on Rconsole. So only 
"ü" ("\u) and "ß" (\ss) are shown in the correct way. The other characters are 
coded in the "\" form.

I found out that this problem doesn't occur when exporting 'ff' to a text file 
with 'writeLines'. When opening this file with a text editor you can see all 
characters in the correct way.

What can I do to get the correct output of the special characters?

Thanks for your help in advance!

Mit freundlichen Grüßen

Dr. Michael Wolf
Bezirksregierung Münster
Dezernat 61
Domplatz 1-348161 Münster
Tel.:   ++ 49 (02 51) / 4 11 - 17 95
Fax.:   ++ 49 (02 51) / 4 11 - 8 17 95
E-Mail: [EMAIL PROTECTED]

__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


[R] RE: adding perspectives to existing persp plots

2004-12-14 Thread Corey Bradshaw
Thanks, Romain. I've certainly used that to draw lines and points in the plots 
produced by 'persp'; however, my problem is that I need to incorporate an 
entirely new z function (not just a plane) onto the same plot (i.e., using the 
same x and y values).

Corey

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, December 15, 2004 4:30 PM
To: Corey Bradshaw
Cc: [EMAIL PROTECTED]
Subject: 


Hello,

Just look at the examples in ?persp.
There is a function called trans3d defined in it that will traduce your 3D
coordinates to 2D, and so you will be able to draw lines with lines function.

Romain.

Corey Bradshaw a écrit :

>I've created a perspective plot using 'persp' in the graphics package.
>I'd like to add a second plane of z values to the existing plot, but I
>cannot seem to do this using 'persp'. Is there an analogue to 'lines' or
>'points' for perspectives?
>
>Corey.
>[EMAIL PROTECTED]
>
--
Romain FRANCOIS : [EMAIL PROTECTED]
page web : http://addictedtor.free.fr/  (en construction)
06 18 39 14 69 / 01 46 80 65 60
___
Etudiant en 3eme année
Institut de Statistique de l'Université de Paris (ISUP)
Filière Industrie et Services
http://www.isup.cicrp.jussieu.fr/

__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


[R] How to generate random number from grouped data?

2004-12-14 Thread ximing wu
Hi there, I need help on the following problem. Any suggestions will be 
much appreciated.

Let x be an i.i.d. random sample of a continuous variable. For some fixed 
numbers a1
1) the frequency of x falls in each interval (a1, a2], (a2, a3], (a3, a4],...
2) the conditional mean of x within each interval, mu1, mu2, mu3,...

Is there a way to generate a random sample based on the grouped information 
on frequency and mean of each interval?

Thanks for the help.
Ximing
__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


[R] how to fit a weighted logistic regression?

2004-12-14 Thread Kerry Bush
I tried lrm in library(Design) but there is always
some error message. Is this function really doing the
weighted logistic regression as maximizing the
following likelihood:

\sum w_i*(y_i*\beta*x_i-log(1+exp(\beta*x_i)))

Does anybody know a better way to fit this kind of
model in R?

FYI: one example of getting error message is like:
> x=runif(10,0,3)
> y=c(rep(0,5),rep(1,5))
> w=rep(1/10,10)
> fit=lrm(y~x,weights=w)
Warning message: 
currently weights are ignored in model validation and
bootstrapping lrm fits in: lrm(y ~ x, weights = w) 

although the model can be fit, the above output
warning makes me uncomfortable. Can anybody explain
about it a little bit?

Best wishes,
Feixia

__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


Re: [R] classification for huge datasets: SVM yields memory troubles

2004-12-14 Thread John Maindonald
While it is true that the large number of variables relative to
the number of observations restricts what can be inferred,
the situation is not as hopeless as Bert seems to suggest.
If it were, attempts at the analysis of expression array data
would be a waste to time.  Methods developed to that
general area may well be relevant to other data where the
number of variables is similarly far larger than the number
of observations.
See Ambroise, C. and Mclachlan, G.J. 2002.  Selection bias
in gene extraction on the basis of microarray gene-expression
data.  PNAS 99: 6562--6566.
This discusses some of the literature on the use of SVMs.
The selection bias that these authors discuss also affects
plots, even principal components and other ordination-base
plots where features have been selected on the basis of their
ability to separate into known groups.  I have draft versions
of code that addresses this selection bias as it affects the
plotting of graphs, which (along a paper that has been
submitted for inclusion in a conference proceedings) I am
happy to make available to anyone who wants to experiment.
Another good place to look, as a starting point, may be
Gordon Smyth's LIMMA User's Guide.  This can be a bit
hard to find. With limma installed, type help.start().
After some time a browser window should open. Click on
Packages | limma | Overview | LIMMA User's Guide (pdf)
John Maindonald email: [EMAIL PROTECTED]
phone : +61 2 (6125)3473fax  : +61 2(6125)5549
Centre for Bioinformation Science, Room 1194,
John Dedman Mathematical Sciences Building (Building 27)
Australian National University, Canberra ACT 0200.
On 14 Dec 2004, at 10:09 PM, [EMAIL PROTECTED] wrote:
From: Berton Gunter <[EMAIL PROTECTED]>
Date: 14 December 2004 9:23:08 AM
To: "'Andreas'" <[EMAIL PROTECTED]>, <[EMAIL PROTECTED]>
Cc: Subject: RE: [R] classification for huge datasets: SVM yields 
memory troubles

" I have a matrix with 30 observations and roughly 3
variables, ... "
Comment: This is ** not ** a "huge" data set -- it is a tiny one with a
large number of covariates. The difference is: If it were truly huge, 
SVM
and/or LDA or ... might actually be able to produce useful results. 
With so
few data and so many variables, it is hard to see how any approach 
that one
uses is not simply a fancy random number generator.

John Maindonald email: [EMAIL PROTECTED]
phone : +61 2 (6125)3473fax  : +61 2(6125)5549
Centre for Bioinformation Science, Room 1194,
John Dedman Mathematical Sciences Building (Building 27)
Australian National University, Canberra ACT 0200.
__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


[R] adding perspectives to existing persp plots

2004-12-14 Thread Corey Bradshaw
I've created a perspective plot using 'persp' in the graphics package.
I'd like to add a second plane of z values to the existing plot, but I
cannot seem to do this using 'persp'. Is there an analogue to 'lines' or
'points' for perspectives?

Corey.
[EMAIL PROTECTED]

__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


RE: [R] Re: [S] using Hmisc and Design library

2004-12-14 Thread array chip
sorry, I had a typo there, it's datadist(b) for the
analysis of data frame "b".

--- Robert Balshaw <[EMAIL PROTECTED]> wrote:

> Not sure if this will help, but did you mean to use
> datadist(a) for
> the analysis of B?
> 
> Rob
> 
> > -Original Message-
> > From: [EMAIL PROTECTED]
> > [mailto:[EMAIL PROTECTED] Behalf
> Of array chip
> > Sent: Tuesday, December 14, 2004 4:28 PM
> > To: [EMAIL PROTECTED];
> [EMAIL PROTECTED]
> > Subject: [R] Re: [S] using Hmisc and Design
> library
> >
> >
> > actually data frame "b" has 177 rows, the script
> ran
> > ok on the first 166 rows as a subset, but started
> to
> > break down if subset of the first 177 rows were
> used
> > as the dataset, or the first 166 rows plus 168th
> row,
> > 
> >
> > the data in those rows are:
> > time status scores
> > 165  172  0 -123.3
> > 166  105  0 -138.4
> > 167  166  0 -128.8
> > 168  140  0 -114.2
> > 169  163  0 -117.0
> > 170  141  0 -115.8
> >
> > please advise!
> >
> >
> > --- array chip <[EMAIL PROTECTED]> wrote:
> >
> > > Hi, I encountered a weird problem when using the
> > > Design and Hmisc problem. I have 2 data frame
> called
> > > "a" and "b", both have 3 columns: "time",
> "status"
> > > and
> > > "scores", a sample of the data frame is like:
> > >
> > > data frame "a":
> > >   time status scores
> > > 1   21  1  99.61
> > > 2   38  0 101.11
> > > 3   51  0 100.62
> > > 4   48  0  87.52
> > > 5   78  0  97.18
> > >
> > > data frame "b":
> > >   time status scores
> > > 1   27  0 -126.7
> > > 2   24  0 -135.6
> > > 3   30  0 -139.5
> > > 4   49  0 -137.6
> > > 5   27  0 -136.9
> > >
> > > when I ran the following using data frame "a",
> > > everything is ok.
> > >
> > > > library(Hmisc,T);library(Design,T)
> > > > dd <- datadist(a)
> > > > options(datadist='dd')
> > > > fit <- cph(Surv(time,status) ~ scores,
> > > data=a,surv=T, x=T, y=T)
> > > > fit
> > > Cox Proportional Hazards Model
> > >
> > > cph(formula = Surv(time, status) ~ scores, data
> =
> > > data.combined.testing.set.scores, x = T, y = T,
> > >   surv = T)
> > >
> > >  Obs Events Model L.R. d.f.  P Score Score P
> > > R2
> > >
> > >   85 31   7.471 0.0063  7.21  0.0072
> > > 0.088
> > >
> > >
> > >  coef se(coef)z   p
> > > scores 0.0766   0.0287 2.67 0.00752
> > >
> > >
> > > but when I ran the same script using data frame
> "b",
> > > even though no error message was produced, no
> fit
> > > object was generated:
> > >
> > > > rm(fit)
> > > > library(Hmisc,T);library(Design,T)
> > > > dd <- datadist(a)
> > > > options(datadist='dd')
> > > > fit <- cph(Surv(time,status) ~ scores,
> > > data=a,surv=T, x=T, y=T)
> > > > fit
> > > Problem: Object "fit" not found, while calling
> > > subroutine S_agsurv2
> > > Use traceback() to see the call stack
> > >
> > > can anyone tell me why? no missing value is
> present
> > > in
> > > either data frame.
> > >
> > > Thanks
> > >
> > >
> > >
> > >
> > >
> > > __
> > > Do you Yahoo!?
> > > The all-new My Yahoo! - What will yours do?
> > > http://my.yahoo.com
> > >
> >
>
--
> > --
> > > This message was distributed by
> > > [EMAIL PROTECTED]  To
> > > unsubscribe send e-mail to
> > > [EMAIL PROTECTED] with
> >
> > >
> >
> >
> >
> >
> > __
> >
> > Dress up your holiday email, Hollywood style.
> Learn more.
> >
> > __
> > [EMAIL PROTECTED] mailing list
> > https://stat.ethz.ch/mailman/listinfo/r-help
> > PLEASE do read the posting guide!
> http://www.R-project.org/posting-guide.html
> 
> 




__ 

Jazz up your holiday email with celebrity designs. Learn more.

__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


RE: [R] Re : Save result in a For Loop

2004-12-14 Thread Liaw, Andy
Is there anything wrong with vectorized calculation?  E.g.,

dd <- (M-10):M
r <- 0.5 * (1 - exp(-2 * (32 - dd) / 100))
round(r, 4)

Andy

> From: bogdan romocea
> 
> Not sure if it's the best way, but you could do it this way:
> all.results <- vector(mode="numeric")
> for (i in 1:100)
>   {
>   ...
>   this.run <- ...
>   all.results <- c(all.results,this.run)
>   }
> At this point all.results contains the values of this.run from the
> whole loop. If this.run is not a vector/number but a data frame look
> at rbind/cbind.
> 
> Or, create a vector/matrix first and then populate it from the for
> loop:
> all.results <- vector()/matrix()/data.frame()
> for (i in 1:100)
>   for(j ...)
>   {
>   ...
>   all.results[i] <- this.run  ,OR
>   all.results[i,] <- this.run  , OR
>   all.results[i,j] <- this.run
>   }
> 
> HTH,
> b.
> 
> 
> -Original Message-
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, December 14, 2004 2:44 PM
> To: [EMAIL PROTECTED]
> Subject: [R] Re : Save result in a For Loop
> 
> 
> Hiya,
> 
> I have been struggling to save the result from the FOR loop. What is
> the
> best way to do it, as I need the result to merge with another dataset
> for
> further analysis ?
> 
> for (dd in ((M-10):M)){
> + dist<-(32-dd)
> + r<-1/2*(1-exp(-2*dist/100))
> + map<-c(dd,round(r,4))
> + print(map)
> + next
> + }
> 
> Thanks. Stella
> __
> _
> This message, including attachments, is confidential. If\\...{{dropped}}

__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


[R] Re: [S] using Hmisc and Design library

2004-12-14 Thread array chip
actually data frame "b" has 177 rows, the script ran
ok on the first 166 rows as a subset, but started to
break down if subset of the first 177 rows were used
as the dataset, or the first 166 rows plus 168th row,


the data in those rows are:
time status scores 
165  172  0 -123.3
166  105  0 -138.4
167  166  0 -128.8
168  140  0 -114.2
169  163  0 -117.0
170  141  0 -115.8

please advise!


--- array chip <[EMAIL PROTECTED]> wrote:

> Hi, I encountered a weird problem when using the
> Design and Hmisc problem. I have 2 data frame called
> "a" and "b", both have 3 columns: "time", "status"
> and
> "scores", a sample of the data frame is like:
> 
> data frame "a":
>   time status scores 
> 1   21  1  99.61
> 2   38  0 101.11
> 3   51  0 100.62
> 4   48  0  87.52
> 5   78  0  97.18
> 
> data frame "b":
>   time status scores 
> 1   27  0 -126.7
> 2   24  0 -135.6
> 3   30  0 -139.5
> 4   49  0 -137.6
> 5   27  0 -136.9
> 
> when I ran the following using data frame "a",
> everything is ok.
> 
> > library(Hmisc,T);library(Design,T)
> > dd <- datadist(a)
> > options(datadist='dd')
> > fit <- cph(Surv(time,status) ~ scores,
> data=a,surv=T, x=T, y=T)
> > fit
> Cox Proportional Hazards Model
> 
> cph(formula = Surv(time, status) ~ scores, data =
> data.combined.testing.set.scores, x = T, y = T,
>   surv = T)
> 
>  Obs Events Model L.R. d.f.  P Score Score P   
> R2
> 
>   85 31   7.471 0.0063  7.21  0.0072
> 0.088
> 
> 
>  coef se(coef)z   p 
> scores 0.0766   0.0287 2.67 0.00752
> 
> 
> but when I ran the same script using data frame "b",
> even though no error message was produced, no fit
> object was generated:
> 
> > rm(fit)
> > library(Hmisc,T);library(Design,T)
> > dd <- datadist(a)
> > options(datadist='dd')
> > fit <- cph(Surv(time,status) ~ scores,
> data=a,surv=T, x=T, y=T)
> > fit
> Problem: Object "fit" not found, while calling
> subroutine S_agsurv2 
> Use traceback() to see the call stack
> 
> can anyone tell me why? no missing value is present
> in
> either data frame.
> 
> Thanks
> 
> 
> 
> 
>   
> __ 
> Do you Yahoo!? 
> The all-new My Yahoo! - What will yours do?
> http://my.yahoo.com 
>

> This message was distributed by
> [EMAIL PROTECTED]  To
> unsubscribe send e-mail to
> [EMAIL PROTECTED] with

> 




__ 

Dress up your holiday email, Hollywood style. Learn more.

__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


[R] using Hmisc and Design library

2004-12-14 Thread array chip
Hi, I encountered a weird problem when using the
Design and Hmisc problem. I have 2 data frame called
"a" and "b", both have 3 columns: "time", "status" and
"scores", a sample of the data frame is like:

data frame "a":
  time status scores 
1   21  1  99.61
2   38  0 101.11
3   51  0 100.62
4   48  0  87.52
5   78  0  97.18

data frame "b":
  time status scores 
1   27  0 -126.7
2   24  0 -135.6
3   30  0 -139.5
4   49  0 -137.6
5   27  0 -136.9

when I ran the following using data frame "a",
everything is ok.

> library(Hmisc,T);library(Design,T)
> dd <- datadist(a)
> options(datadist='dd')
> fit <- cph(Surv(time,status) ~ scores,
data=a,surv=T, x=T, y=T)
> fit
Cox Proportional Hazards Model

cph(formula = Surv(time, status) ~ scores, data =
data.combined.testing.set.scores, x = T, y = T,
surv = T)

 Obs Events Model L.R. d.f.  P Score Score PR2

  85 31   7.471 0.0063  7.21  0.0072 0.088


 coef se(coef)z   p 
scores 0.0766   0.0287 2.67 0.00752


but when I ran the same script using data frame "b",
even though no error message was produced, no fit
object was generated:

> rm(fit)
> library(Hmisc,T);library(Design,T)
> dd <- datadist(a)
> options(datadist='dd')
> fit <- cph(Surv(time,status) ~ scores,
data=a,surv=T, x=T, y=T)
> fit
Problem: Object "fit" not found, while calling
subroutine S_agsurv2 
Use traceback() to see the call stack

can anyone tell me why? no missing value is present in
either data frame.

Thanks

__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


Re: [R] make check-all failed on SLES8 for x86_64

2004-12-14 Thread Peter Dalgaard
"Liaw, Andy" <[EMAIL PROTECTED]> writes:

> Hi all,
> 
> I've only now noticed that on our Opteron boxes running Suse Enterprise
> Server 8 that R-2.0.1 did not pass make chek-all.  It bombed in
> tests/lapack.R at:
> 
> > eigenok <- function(A, E, Eps = 1000 * .Machine$double.eps) {
> V <- E$vect
> lam <- E$values
> stopifnot(abs(A %*% V - V %*% diag(lam)) < Eps,   [TRUNCATED] 
> 
> > Ceigenok <- function(A, E, Eps = 1000 * .Machine$double.eps) {
> V <- E$vect
> lam <- E$values
> stopifnot(Mod(A %*% V - V %*% diag(lam)) < Eps,  [TRUNCATED] 
> 
> > sm <- cbind(1, 3:1, 1:3)
> 
> > eigenok(sm, eigen(sm))
> Error: abs(A %*% V - V %*% diag(lam)) < Eps is not TRUE
> 
> This is using:
> ~/R-2.0.1> gcc -v
> Reading specs from /opt/gcc33/lib64/gcc-lib/x86_64-suse-linux/3.3/specs
> Configured with: ../configure --enable-threads=posix --prefix=/opt/gcc33
> --with-local-prefix=/usr/local --infodir=/opt/gcc33/share/info
> --mandir=/opt/gcc33/share/man --libdir=/opt/gcc33/lib64
> --enable-languages=c,c++,f77,objc,java,ada --disable-checking
> --enable-libgcj --with-gxx-include-dir=/opt/gcc33/include/g++
> --with-slibdir=/lib64 --with-system-zlib --enable-shared
> --enable-__cxa_atexit x86_64-suse-linux
> Thread model: posix
> gcc version 3.3 20030312 (prerelease) (SuSE Linux)
> 
> compiled with the following setting:
> 
> R is now configured for x86_64-unknown-linux-gnu
> 
>   Source directory:  .
>   Installation directory:/usr/local
> 
>   C compiler:gcc  -g -O2
>   C++ compiler:  g++  -g -O2
>   Fortran compiler:  g77  -g -O2
> 
>   Interfaces supported:  X11, tcltk
>   External libraries:readline
>   Additional capabilities:   PNG, JPEG
>   Options enabled:   R profiling
> 
>   Recommended packages:  yes
> 
> Actually, I've only noticed this when the samething happens on a RH-based
> box (same hardware), using:
> $ gcc -v
> Reading specs from /usr/lib/gcc-lib/x86_64-redhat-linux/3.2.3/specs
> Configured with: ../configure --prefix=/usr --mandir=/usr/share/man
> --infodir=/usr/share/info --enable-shared --enable-threads=posix
> --disable-checking --with-system-zlib --enable-__cxa_atexit
> --enable-languages=c,c++,objc,java,f77 --host=x86_64-redhat-linux
> Thread model: posix
> gcc version 3.2.3 20030502 (Red Hat Linux 3.2.3-24)
> 
> I'd very much appreciate any pointers!

Hmm. Not the first time we see eigen() in that role... First thing to
check is of course whether it is a case of "Eps too low" or true
miscomputation. For the record, it is not happening for me with SuSE
9.1 on Opteron:

> sm <- cbind(1, 3:1, 1:3)
> A <- sm
> E <- eigen(sm)
> V <- E$vect
> lam <- E$values
> abs(A %*% V - V %*% diag(lam))
 [,1] [,2] [,3]
[1,] 0.00e+00 1.110223e-16 3.354246e-16
[2,] 2.220446e-15 8.326673e-17 2.712063e-16
[3,] 8.881784e-16 0.00e+00 3.267174e-16
> .Machine$double.eps
[1] 2.220446e-16

[EMAIL PROTECTED]:~> gcc -v
Reading specs from /usr/lib64/gcc-lib/x86_64-suse-linux/3.3.3/specs
Configured with: ../configure --enable-threads=posix --prefix=/usr
--with-local-prefix=/usr/local --infodir=/usr/share/info
--mandir=/usr/share/man --enable-languages=c,c++,f77,objc,java,ada
--disable-checking --libdir=/usr/lib64 --enable-libgcj
--with-gxx-include-dir=/usr/include/g++ --with-slibdir=/lib64
--with-system-zlib --enable-shared --enable-__cxa_atexit
x86_64-suse-linux
Thread model: posix
gcc version 3.3.3 (SuSE Linux)


Compile settings similar to yours, except that I have -O3.

-- 
   O__   Peter Dalgaard Blegdamsvej 3  
  c/ /'_ --- Dept. of Biostatistics 2200 Cph. N   
 (*) \(*) -- University of Copenhagen   Denmark  Ph: (+45) 35327918
~~ - ([EMAIL PROTECTED]) FAX: (+45) 35327907

__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


RE: [R] make check-all failed on SLES8 for x86_64

2004-12-14 Thread Liaw, Andy
Thanks for reminding me of that thread, Roger.  I've forgotten all about
it...

Strangely, several people reported no problem with optimized BLAS, but I
tried linking against the latest version (0.96, threaded), and got the same
failure.  I will try to see if I can upgrade GCC.

Best,
Andy

> From: Roger D. Peng 
> 
> Martin Maechler brought this up a while back (and added the 
> regression 
> test).  I believe it was a compiler problem and upgrading to 
> gcc 3.4.1 
> fixed it.
> 
> See the thread starting here:
> 
> https://stat.ethz.ch/pipermail/r-devel/2004-July/030260.html
> 
> -roger
> 
> Liaw, Andy wrote:
> > Hi all,
> > 
> > I've only now noticed that on our Opteron boxes running 
> Suse Enterprise
> > Server 8 that R-2.0.1 did not pass make chek-all.  It bombed in
> > tests/lapack.R at:
> > 
> > 
> >>eigenok <- function(A, E, Eps = 1000 * .Machine$double.eps) {
> > 
> > V <- E$vect
> > lam <- E$values
> > stopifnot(abs(A %*% V - V %*% diag(lam)) < Eps,   
> [TRUNCATED] 
> > 
> > 
> >>Ceigenok <- function(A, E, Eps = 1000 * .Machine$double.eps) {
> > 
> > V <- E$vect
> > lam <- E$values
> > stopifnot(Mod(A %*% V - V %*% diag(lam)) < Eps,  
> [TRUNCATED] 
> > 
> > 
> >>sm <- cbind(1, 3:1, 1:3)
> > 
> > 
> >>eigenok(sm, eigen(sm))
> > 
> > Error: abs(A %*% V - V %*% diag(lam)) < Eps is not TRUE
> > 
> > This is using:
> > ~/R-2.0.1> gcc -v
> > Reading specs from 
> /opt/gcc33/lib64/gcc-lib/x86_64-suse-linux/3.3/specs
> > Configured with: ../configure --enable-threads=posix 
> --prefix=/opt/gcc33
> > --with-local-prefix=/usr/local --infodir=/opt/gcc33/share/info
> > --mandir=/opt/gcc33/share/man --libdir=/opt/gcc33/lib64
> > --enable-languages=c,c++,f77,objc,java,ada --disable-checking
> > --enable-libgcj --with-gxx-include-dir=/opt/gcc33/include/g++
> > --with-slibdir=/lib64 --with-system-zlib --enable-shared
> > --enable-__cxa_atexit x86_64-suse-linux
> > Thread model: posix
> > gcc version 3.3 20030312 (prerelease) (SuSE Linux)
> > 
> > compiled with the following setting:
> > 
> > R is now configured for x86_64-unknown-linux-gnu
> > 
> >   Source directory:  .
> >   Installation directory:/usr/local
> > 
> >   C compiler:gcc  -g -O2
> >   C++ compiler:  g++  -g -O2
> >   Fortran compiler:  g77  -g -O2
> > 
> >   Interfaces supported:  X11, tcltk
> >   External libraries:readline
> >   Additional capabilities:   PNG, JPEG
> >   Options enabled:   R profiling
> > 
> >   Recommended packages:  yes
> > 
> > Actually, I've only noticed this when the samething happens 
> on a RH-based
> > box (same hardware), using:
> > $ gcc -v
> > Reading specs from /usr/lib/gcc-lib/x86_64-redhat-linux/3.2.3/specs
> > Configured with: ../configure --prefix=/usr --mandir=/usr/share/man
> > --infodir=/usr/share/info --enable-shared --enable-threads=posix
> > --disable-checking --with-system-zlib --enable-__cxa_atexit
> > --enable-languages=c,c++,objc,java,f77 --host=x86_64-redhat-linux
> > Thread model: posix
> > gcc version 3.2.3 20030502 (Red Hat Linux 3.2.3-24)
> > 
> > I'd very much appreciate any pointers!
> > 
> > Best,
> > Andy
> > 
> > 
> > Andy Liaw, PhD
> > Biometrics Research  PO Box 2000, RY33-300 
> > Merck Research Labs   Rahway, NJ 07065
> > andy_liaw  merck.com  732-594-0820
> > 
> > __
> > [EMAIL PROTECTED] mailing list
> > https://stat.ethz.ch/mailman/listinfo/r-help
> > PLEASE do read the posting guide! 
> http://www.R-project.org/posting-guide.html
> > 
> 
> -- 
> Roger D. 
> Peng
> http://www.biostat.jhsph.edu/~rpeng/
> 
>

__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


Re: [R] switching to Linux, suggestions?

2004-12-14 Thread Ulises M. Alvarez
Again, I have to tell...

Take a look at Ubuntu
http://www.ubuntulinux.org/

When I get tired of MAC OSX, I installed the ppc version of Ubuntu on my
IBook. It's great and it's based on Debian. 


On Mon, 2004-12-13 at 12:35 -0500, doktora v wrote:
> I'm using SUSE with success on intel laptop and AMD desktop. You get
> the best of both worlds: rpm and source. I can easily get the rpm
> packages i need, and compile on my own the things that i can spend
> time on (such as R 2.0.1 -- compiles out of the box on suse).
> 
> BTW, I'm looking to switch to Mac platform. Anyone had any experience
> with that? I'm expecting on a power G4 laptop later this week hope
> R behaves...
> 
> -- doktora
> 
> 
> On Mon, 13 Dec 2004 09:05:54 -0800 (PST), bogdan romocea
> <[EMAIL PROTECTED]> wrote:
> > Before choosing a GNU/Linux distribution look into the package
> > management issue.
> > http://distrowatch.com/
> > I would suggest that you avoid all RPM-based distributions (Mandrake,
> > Fedora, SuSE), and consider Debian (+ those based on it) & the
> > source-based distributions (such as Gentoo). I've been using Mandrake
> > for a couple of years but got tired of RPM.
> > 
> > HTH,
> > b.
> > 
> > 
> > -Original Message-
> > From: Thomas W Volscho [mailto:[EMAIL PROTECTED]
> > Sent: Sunday, December 12, 2004 3:24 PM
> > To: [EMAIL PROTECTED]
> > Subject: [R] switching to Linux, suggestions?
> > 
> > Dear List,
> > I have acquired a new desktop and wanted to put a free OS on it.  I
> > am trying Fedora Core 1, but not sure what the best Linux OS is for
> > using R 2.0.1?
> > 
> > Thank you in advance for your input,
> > Tom Volscho
> > 
> > 
> > Thomas W. Volscho
> > Graduate Student
> > Dept. of Sociology U-2068
> > University of Connecticut
> > Storrs, CT 06269
> > Phone: (860) 486-3882
> > http://vm.uconn.edu/~twv1
> > 
> > __
> > [EMAIL PROTECTED] mailing list
> > https://stat.ethz.ch/mailman/listinfo/r-help
> > PLEASE do read the posting guide!
> > http://www.R-project.org/posting-guide.html
> > 
> > __
> > 
> > Dress up your holiday email, Hollywood style. Learn more.
> > 
> > __
> > [EMAIL PROTECTED] mailing list
> > https://stat.ethz.ch/mailman/listinfo/r-help
> > PLEASE do read the posting guide! 
> > http://www.R-project.org/posting-guide.html
> >
> 
> __
> [EMAIL PROTECTED] mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html

__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


[R] Multivariate multipl regression

2004-12-14 Thread Julianno Sambatti
I am trying to find Multivariate Multiple Regression documentation for R. Could 
somebody please indicate me some, if available at all.

Thanks


[[alternative HTML version deleted]]

__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


Re: [R] drawing a rectangle through multiple plots

2004-12-14 Thread Paul Murrell
Hi
Dr Carbon wrote:
How do I draw a rectangle across multiple plots on a device?
E.g.,
def.par <- par(no.readonly = TRUE)
par(mfrow = c(3, 1))
plot(1:10, rnorm(10), ylim = c(-4,4), type = "l")
plot(1:10, rnorm(10), ylim = c(-4,4), type = "l")
plot(1:10, rnorm(10), ylim = c(-4,4), type = "l")
rect(2, -4, 3, 4)
par(def.par)
I want the rectangle to extend across the whole device. How do I get
at those coordinates? Is this a case where I should be using grid or
gridBase?

You could use grid and gridBase (and grid.moveto() and grid.line.to)), 
but if your real example is as straightforward as this toy one, then you 
can "fake it" by drawing overlapping lines deliberately beyond the 
extent of each plot to create what looks like a rectangle across the 
three plots --- par(xpd=NA) means that the lines are not clipped to each 
plot region ...

par(mfrow = c(3, 1))
par(xpd=NA)
plot(1:10, rnorm(10), ylim = c(-4,4), type = "l")
# "top" of rectangle
lines(c(2, 2, 3, 3), c(-10, 4, 4, -10))
plot(1:10, rnorm(10), ylim = c(-4,4), type = "l")
# "sides" of rectangle
lines(c(2, 2), c(-10, 10))
lines(c(3, 3), c(-10, 10))
plot(1:10, rnorm(10), ylim = c(-4,4), type = "l")
# "bottom" of rectangle
lines(c(2, 2, 3, 3), c(10, -4, -4, 10))
HTH
Paul
--
Dr Paul Murrell
Department of Statistics
The University of Auckland
Private Bag 92019
Auckland
New Zealand
64 9 3737599 x85392
[EMAIL PROTECTED]
http://www.stat.auckland.ac.nz/~paul/
__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


Re: [R] Advice on parsing formulae

2004-12-14 Thread Chuck Berry
Claus Dethlefsen  math.aau.dk> writes: 
 
>  
> Dear list 
>  
> I would like to be able to group terms in a formula using a function that I 
> will call tvar(), eg. the formula 
>  
> Y ~ 1 + tvar(x:A) + tvar(z) + u + tvar(B) + tvar(poly(v,3)) 
>  
> where x,u and v are numeric and A and B are factors - binary, say. 
>  
> As output, I want the model.matrix as if tvar had not been there at all. In 
> addition, I would like to have information on the grouping, as a vector as 
> long as ncol( model.matrix ) with zeros corresponding to terms outside tvar 
> and with an index grouping the terms inside each tvar(). In the (sick) 
 
 
Since you want to single out terms with 'tvar' in them, something like 
 
tvar.terms <- terms( your.formula.above, specials = "tvar" ) 
 
will likely be what you want. You'll want to study 
 
?terms 
?terms.object 
 
and then 
 
print( tvar.terms ) 
 
And likely 'deparse' will help, too. 
 
> example: 
[rest deleted]

__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


[R] r-mathlib and ruby-rmathlib

2004-12-14 Thread Damien Joly
Hi all,

I am trying to set up r-mathlib so I can access R
functions from Ruby using ruby-rmathlib, and for the
life of me I can't find an rpm or source code for
r-mathlib (I can find debian packages ...).  I'm using
Red Hat Enterprise Linux WS (V 3) (EM_64 bit
processor) and R version 1.9.1.

Thanks for any help,

Damien

__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


RE: [R] Re : Save result in a For Loop

2004-12-14 Thread bogdan romocea
Not sure if it's the best way, but you could do it this way:
all.results <- vector(mode="numeric")
for (i in 1:100)
{
...
this.run <- ...
all.results <- c(all.results,this.run)
}
At this point all.results contains the values of this.run from the
whole loop. If this.run is not a vector/number but a data frame look
at rbind/cbind.

Or, create a vector/matrix first and then populate it from the for
loop:
all.results <- vector()/matrix()/data.frame()
for (i in 1:100)
  for(j ...)
{
...
all.results[i] <- this.run  ,OR
all.results[i,] <- this.run  , OR
all.results[i,j] <- this.run
}

HTH,
b.


-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: Tuesday, December 14, 2004 2:44 PM
To: [EMAIL PROTECTED]
Subject: [R] Re : Save result in a For Loop


Hiya,

I have been struggling to save the result from the FOR loop. What is
the
best way to do it, as I need the result to merge with another dataset
for
further analysis ?

for (dd in ((M-10):M)){
+ dist<-(32-dd)
+ r<-1/2*(1-exp(-2*dist/100))
+ map<-c(dd,round(r,4))
+ print(map)
+ next
+ }

Thanks. Stella
___
This message, including attachments, is confidential. If\ yo...{{dropped}}

__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


RE: [R] Multivariate multipl regression

2004-12-14 Thread Berton Gunter
?aov or ?manova

-- Bert Gunter
Genentech Non-Clinical Statistics
South San Francisco, CA
 
"The business of the statistician is to catalyze the scientific learning
process."  - George E. P. Box
 
 

> -Original Message-
> From: [EMAIL PROTECTED] 
> [mailto:[EMAIL PROTECTED] On Behalf Of 
> Julianno Sambatti
> Sent: Tuesday, December 14, 2004 1:09 PM
> To: [EMAIL PROTECTED]
> Subject: [R] Multivariate multipl regression
> 
> I am trying to find Multivariate Multiple Regression 
> documentation for R. Could somebody please indicate me some, 
> if available at all.
> 
> Thanks
> 
> 
>   [[alternative HTML version deleted]]
> 
> __
> [EMAIL PROTECTED] mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide! 
> http://www.R-project.org/posting-guide.html
> 
__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html

[R] looking for Chebyshev I low pass filter

2004-12-14 Thread Christian Jost
I am looking for a simple implementation of a Chebyshev type I 
low-pass filter in R. Searching through the R web site I only found 
similar requests but never an answer pointing to a package providing 
such standard filters (Chebyshev, Butterworth). Any idea where I 
might find this?

Thanks, Christian.
__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


Re: [R] switching to Linux, suggestions?

2004-12-14 Thread Ulises M. Alvarez
A little bit late, but I have to tell...

Take a look at Ubuntu

http://www.ubuntulinux.org

Is both comfortable to install and maintain; plus easy to expand.

__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


[R] Re : Save result in a For Loop

2004-12-14 Thread ssim
Hiya,

I have been struggling to save the result from the FOR loop. What is the
best way to do it, as I need the result to merge with another dataset for
further analysis ?

for (dd in ((M-10):M)){
+ dist<-(32-dd)
+ r<-1/2*(1-exp(-2*dist/100))
+ map<-c(dd,round(r,4))
+ print(map)
+ next
+ }

Thanks. Stella
___
This message, including attachments, is confidential. If you...{{dropped}}

__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


[R] drawing a rectangle through multiple plots

2004-12-14 Thread Dr Carbon
How do I draw a rectangle across multiple plots on a device?

E.g.,

def.par <- par(no.readonly = TRUE)
par(mfrow = c(3, 1))
plot(1:10, rnorm(10), ylim = c(-4,4), type = "l")
plot(1:10, rnorm(10), ylim = c(-4,4), type = "l")
plot(1:10, rnorm(10), ylim = c(-4,4), type = "l")
rect(2, -4, 3, 4)
par(def.par)

I want the rectangle to extend across the whole device. How do I get
at those coordinates? Is this a case where I should be using grid or
gridBase?

Thanks.

__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


RE: [R] linear regression: evaluating the result Q

2004-12-14 Thread Liaw, Andy
It looks just like the classical F-test for lack-of-fit, using estimate of
`pure errors' from replicates, doesn't it?  This should be in most applied
regression books.  The power (i.e., probability of finding lack-of-fit when
it exists) of such tests will depend on the data.

Andy

> From: RenE J.V. Bertin
> 
> Hello,
> 
> I'd like to come back to this question I obtained some 
> valuable help with a while ago.
> 
> I just came across a paper applying a seemingly rather 
> clever/elegant technique to assess the extent to which a 
> linear fit is appropriate, given once data. These authors 
> apply an ANOVA to the residuals, and take a NS result as an 
> indication that the fitted relationship is indeed 
> (sufficiently) linear.
> 
> But is this a clever/elegant technique, and is it good and robust?
> A rather pathological example where it fails (I think):
> 
> ##> kk<-data.frame( ordered(factor( rep( 1:25, each=11))), 
> ordered(factor(rep( 0:10, 25))), sin( pi*jitter(rep(0:10,25))) )
> ##> names(kk)<-c("s","x","y")
> ##> summary( aov(y~x+Error(s), data=kk) )
> 
> Error: s
>   Df Sum Sq Mean Sq F value Pr(>F)
> Residuals 24  2.592   0.108   
> 
> Error: Within
>Df Sum Sq Mean Sq F value Pr(>F)
> x  10  1.174   0.117   0.974  0.467
> Residuals 240 28.924   0.121   
> 
> (it doesn't fail when using a cosine instead of a sine, of course).
> 
> And if so, before I reinvent the wheel in implementing it 
> myself: is anyone here aware of an existing implementation of 
> a test that does just that?
> 
> Thanks,
> RenE Bertin
> 
> __
> [EMAIL PROTECTED] mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide! 
> http://www.R-project.org/posting-guide.html
> 
>

__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


Re: [R] make check-all failed on SLES8 for x86_64

2004-12-14 Thread Roger D. Peng
Martin Maechler brought this up a while back (and added the regression 
test).  I believe it was a compiler problem and upgrading to gcc 3.4.1 
fixed it.

See the thread starting here:
https://stat.ethz.ch/pipermail/r-devel/2004-July/030260.html
-roger
Liaw, Andy wrote:
Hi all,
I've only now noticed that on our Opteron boxes running Suse Enterprise
Server 8 that R-2.0.1 did not pass make chek-all.  It bombed in
tests/lapack.R at:

eigenok <- function(A, E, Eps = 1000 * .Machine$double.eps) {
V <- E$vect
lam <- E$values
stopifnot(abs(A %*% V - V %*% diag(lam)) < Eps,   [TRUNCATED] 


Ceigenok <- function(A, E, Eps = 1000 * .Machine$double.eps) {
V <- E$vect
lam <- E$values
stopifnot(Mod(A %*% V - V %*% diag(lam)) < Eps,  [TRUNCATED] 


sm <- cbind(1, 3:1, 1:3)

eigenok(sm, eigen(sm))
Error: abs(A %*% V - V %*% diag(lam)) < Eps is not TRUE
This is using:
~/R-2.0.1> gcc -v
Reading specs from /opt/gcc33/lib64/gcc-lib/x86_64-suse-linux/3.3/specs
Configured with: ../configure --enable-threads=posix --prefix=/opt/gcc33
--with-local-prefix=/usr/local --infodir=/opt/gcc33/share/info
--mandir=/opt/gcc33/share/man --libdir=/opt/gcc33/lib64
--enable-languages=c,c++,f77,objc,java,ada --disable-checking
--enable-libgcj --with-gxx-include-dir=/opt/gcc33/include/g++
--with-slibdir=/lib64 --with-system-zlib --enable-shared
--enable-__cxa_atexit x86_64-suse-linux
Thread model: posix
gcc version 3.3 20030312 (prerelease) (SuSE Linux)
compiled with the following setting:
R is now configured for x86_64-unknown-linux-gnu
  Source directory:  .
  Installation directory:/usr/local
  C compiler:gcc  -g -O2
  C++ compiler:  g++  -g -O2
  Fortran compiler:  g77  -g -O2
  Interfaces supported:  X11, tcltk
  External libraries:readline
  Additional capabilities:   PNG, JPEG
  Options enabled:   R profiling
  Recommended packages:  yes
Actually, I've only noticed this when the samething happens on a RH-based
box (same hardware), using:
$ gcc -v
Reading specs from /usr/lib/gcc-lib/x86_64-redhat-linux/3.2.3/specs
Configured with: ../configure --prefix=/usr --mandir=/usr/share/man
--infodir=/usr/share/info --enable-shared --enable-threads=posix
--disable-checking --with-system-zlib --enable-__cxa_atexit
--enable-languages=c,c++,objc,java,f77 --host=x86_64-redhat-linux
Thread model: posix
gcc version 3.2.3 20030502 (Red Hat Linux 3.2.3-24)
I'd very much appreciate any pointers!
Best,
Andy
Andy Liaw, PhD
Biometrics Research  PO Box 2000, RY33-300 
Merck Research Labs   Rahway, NJ 07065
andy_liaw  merck.com  732-594-0820

__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
--
Roger D. Peng
http://www.biostat.jhsph.edu/~rpeng/
__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


[R] make check-all failed on SLES8 for x86_64

2004-12-14 Thread Liaw, Andy
Hi all,

I've only now noticed that on our Opteron boxes running Suse Enterprise
Server 8 that R-2.0.1 did not pass make chek-all.  It bombed in
tests/lapack.R at:

> eigenok <- function(A, E, Eps = 1000 * .Machine$double.eps) {
V <- E$vect
lam <- E$values
stopifnot(abs(A %*% V - V %*% diag(lam)) < Eps,   [TRUNCATED] 

> Ceigenok <- function(A, E, Eps = 1000 * .Machine$double.eps) {
V <- E$vect
lam <- E$values
stopifnot(Mod(A %*% V - V %*% diag(lam)) < Eps,  [TRUNCATED] 

> sm <- cbind(1, 3:1, 1:3)

> eigenok(sm, eigen(sm))
Error: abs(A %*% V - V %*% diag(lam)) < Eps is not TRUE

This is using:
~/R-2.0.1> gcc -v
Reading specs from /opt/gcc33/lib64/gcc-lib/x86_64-suse-linux/3.3/specs
Configured with: ../configure --enable-threads=posix --prefix=/opt/gcc33
--with-local-prefix=/usr/local --infodir=/opt/gcc33/share/info
--mandir=/opt/gcc33/share/man --libdir=/opt/gcc33/lib64
--enable-languages=c,c++,f77,objc,java,ada --disable-checking
--enable-libgcj --with-gxx-include-dir=/opt/gcc33/include/g++
--with-slibdir=/lib64 --with-system-zlib --enable-shared
--enable-__cxa_atexit x86_64-suse-linux
Thread model: posix
gcc version 3.3 20030312 (prerelease) (SuSE Linux)

compiled with the following setting:

R is now configured for x86_64-unknown-linux-gnu

  Source directory:  .
  Installation directory:/usr/local

  C compiler:gcc  -g -O2
  C++ compiler:  g++  -g -O2
  Fortran compiler:  g77  -g -O2

  Interfaces supported:  X11, tcltk
  External libraries:readline
  Additional capabilities:   PNG, JPEG
  Options enabled:   R profiling

  Recommended packages:  yes

Actually, I've only noticed this when the samething happens on a RH-based
box (same hardware), using:
$ gcc -v
Reading specs from /usr/lib/gcc-lib/x86_64-redhat-linux/3.2.3/specs
Configured with: ../configure --prefix=/usr --mandir=/usr/share/man
--infodir=/usr/share/info --enable-shared --enable-threads=posix
--disable-checking --with-system-zlib --enable-__cxa_atexit
--enable-languages=c,c++,objc,java,f77 --host=x86_64-redhat-linux
Thread model: posix
gcc version 3.2.3 20030502 (Red Hat Linux 3.2.3-24)

I'd very much appreciate any pointers!

Best,
Andy


Andy Liaw, PhD
Biometrics Research  PO Box 2000, RY33-300 
Merck Research Labs   Rahway, NJ 07065
andy_liaw  merck.com  732-594-0820

__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


RE: [R] plot with dates

2004-12-14 Thread Gabor Grothendieck


Halldor Björnsson  vedur.is> writes:

: 
: Hi,
: I am trying to understand the behaviour of the plot function.
: If I have
: 
:   novdate <- as.Date("2001/11/1") + (0:29)
:   y <- 1:30
:   b <- data.frame(novdate,y)
: 
: then plot(b$novdate,b$y) will produce a plot where the x-ticmarks are 
: given as dates (Nov 04, Nov 09 etc), but plot(b) will produce a plot
: where the x-tickmars are integer values (#day since Jan 1st 1970)
: 
: In the first case plot is getting a an x-vector of class Date, and 
: y-vector of class integer.  In the second case plot gets an object of 
: class data.frame (but with components of class Date and integer).
: 
: I am new to R so I may be wrong about this, but it seems to me that
: different plotting methods are invoked. methods(plot) yields a list of
: plot methods, but I cannot access most of them.

If you issue the command plot(x, ...whatever...) it will
wind up calling plot.foo if class(x) is "foo".  You can find
the possibilities via:

methods(plot)

To view the starred ones on the output from the above
you have to do somethingk like this assuming you want
to look at the source for plot.acf:

stats:::plot.acf

(since plot.acf is from the stats package).

: 
: Is there a way to guide plot(b) to using the method used by 
: plot(b$novdate,b$y), - or is that a bad idea?...
: 
: Sincerely,
: Halldór
: 


This really looks like a time series so you probably really want
to treat it that way, not as a data frame.

library(zoo)
z <- zoo(y, novdate)
plot(z)

__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


Re: [R] increase thr range in R

2004-12-14 Thread Spencer Graves
Sebastian: 

 I routinely deal with situations like that in one of two ways: 

 (1) Can you work with log(besselI)?  If yes, that should solve the 
problem. 

 (2) What do you do with the numbers returned from besselI?  I 
assume they are later used to compute numbers in a more sensible range 
by division or differencing.  There are many asymptotic approximations, 
etc., that should work quite well to simplify the computations in those 
extreme cases. 

 hope this helps.  spencer graves

Earl F. Glynn wrote:
IEEE floating point provides a "double-extended" type often called a long
double.  The exact size of a double-extended can vary but the minimum
specified by the spec is 80 bits.  A PC with the IEEE extended type gives an
approximate range from 3.4E-4932 to 1.1E4932, which would give you the range
you want.  Other architectures, such as a Tru64 alpha, give an even larger
extended.
Reference:  See the "IEEE Standard" in
"What Every Computer Scientist Should Know About Floating-Point Arithmetic"
http://docs.sun.com/source/806-3568/ncg_goldberg.html
The "note" under R's ?numeric help says "All real numbers are stored in
double precision format," so R apparently does not yet support the extended
type.
str(.Machine) in R gives a sizeof.longdouble, but I don't know how to use
such a longdouble in native R -- perhaps someone else could enlighten us.  C
or C++ (or other languges) would support the long double type and the
computations you'd like to do.
efg
Earl F. Glynn
Stowers Institute for Medical Research
=
"Sebastian Kaiser" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
Hello Everybody in order to get some needed results out of my function i
need to get my besselI function evaluated at some values which normally gave
Inf or 0 (expon.scaled NAN) back. So I would like to increase the range in R
from approxamittly 1e+320 to aabout 1e+500 or something like that. Is there
any possibility or pacckage to do this easily?
Thank You
Sebastian Kaiser
Institut for Statistics in Munich Germany
__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
 

--
Spencer Graves, PhD, Senior Development Engineer
O:  (408)938-4420;  mobile:  (408)655-4567
__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


Re: [R] plot with dates

2004-12-14 Thread Brian D Ripley
On Tue, 14 Dec 2004, [ISO-8859-1] Halldor Björnsson wrote:

>
> Hi,
> I am trying to understand the behaviour of the plot function.
> If I have
>
>   novdate <- as.Date("2001/11/1") + (0:29)
>   y <- 1:30
>   b <- data.frame(novdate,y)
>
> then plot(b$novdate,b$y) will produce a plot where the x-ticmarks are
> given as dates (Nov 04, Nov 09 etc), but plot(b) will produce a plot
> where the x-tickmars are integer values (#day since Jan 1st 1970)
>
> In the first case plot is getting a an x-vector of class Date, and
> y-vector of class integer.  In the second case plot gets an object of
> class data.frame (but with components of class Date and integer).
>
>
> I am new to R so I may be wrong about this, but it seems to me that
> different plotting methods are invoked. methods(plot) yields a list of
> plot methods, but I cannot access most of them.

You would be able to had you read the help page for methods().  E.g. use
getS3method("plot", "data.frame")  Or try ?plot.data.frame.

> Is there a way to guide plot(b) to using the method used by
> plot(b$novdate,b$y), - or is that a bad idea?...

It's the natural way to do so.  The plot method for data frames is really
designed for a quick look at multi-column numeric data frames.

-- 
Brian D. Ripley,  [EMAIL PROTECTED]
Professor of Applied Statistics,  http://www.stats.ox.ac.uk/~ripley/
University of Oxford, Tel:  +44 1865 272861 (self)
1 South Parks Road, +44 1865 272866 (PA)
Oxford OX1 3TG, UKFax:  +44 1865 272595

__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


[R] plot with dates

2004-12-14 Thread Halldor Björnsson
Hi,
I am trying to understand the behaviour of the plot function.
If I have
 novdate <- as.Date("2001/11/1") + (0:29)
 y <- 1:30
 b <- data.frame(novdate,y)
then plot(b$novdate,b$y) will produce a plot where the x-ticmarks are 
given as dates (Nov 04, Nov 09 etc), but plot(b) will produce a plot
where the x-tickmars are integer values (#day since Jan 1st 1970)

In the first case plot is getting a an x-vector of class Date, and 
y-vector of class integer.  In the second case plot gets an object of 
class data.frame (but with components of class Date and integer).

I am new to R so I may be wrong about this, but it seems to me that
different plotting methods are invoked. methods(plot) yields a list of
plot methods, but I cannot access most of them.
Is there a way to guide plot(b) to using the method used by 
plot(b$novdate,b$y), - or is that a bad idea?...

Sincerely,
Halldór
--
Halldor Bjornsson   ([EMAIL PROTECTED])
Vedurstofa Islands (Icelandic Met. Office)
Bustadavegur 9, IS-150, Reykjavik, Iceland
__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


Re: [R] amd 64 ??

2004-12-14 Thread Peter Dalgaard
Hu Chen <[EMAIL PROTECTED]> writes:

> Hi, I got a amd 64 + debian/pure64 system.
> R is installed by apt-get so it's no doubt that R is for 64bit.
> My question is, for those packages, for example, ipred, it's difficult
> to find in which official debian packages they are. How could I
> install them? if I used install.packages in R, the packges I get are
> 64 bit or 32 bit?

If they work, they're 64 bit...

install.packages build from source, so you should be OK provided your
toolchain is complete.

-- 
   O__   Peter Dalgaard Blegdamsvej 3  
  c/ /'_ --- Dept. of Biostatistics 2200 Cph. N   
 (*) \(*) -- University of Copenhagen   Denmark  Ph: (+45) 35327918
~~ - ([EMAIL PROTECTED]) FAX: (+45) 35327907

__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


RE: [R] sort() leaves row names unaffected

2004-12-14 Thread Liaw, Andy
I don't see how this is the `same' question at all.  The object Martin has
doesn't look like a data frame (can you tell why?), so I believe is
unrelated to what you asked before.

Andy

ps: Why is this copied to [EMAIL PROTECTED]


> From: bogdan romocea
> 
> I asked the same question a few weeks ago. See
> http://tolstoy.newcastle.edu.au/R/help/04/11/6775.html
> 
> 
> -Original Message-
> From: Martin Wegmann
> Sent: Tuesday, December 14, 2004 6:23 AM
> To: [EMAIL PROTECTED]
> Subject: [R] sort() leaves row names unaffected
> 
> 
> Hello, 
> 
> I wonder if I ran into a bug. If I do 
> 
> summary(df1$X1) -> df1.y
> 
> df1.y
> a  b   c   d  e
> [1,] 50.74627 8.955224 17.91045 19.40299 2.985075
> 
> sort(df1.y) 
>a  b   c   d  e
> [1,] 2.985075 8.955224 17.91045 19.40299 50.74627
> 
> my numbers are sorted but do not anymore correspond to the rownames. 
> For me it is counterintuitive that solely the numbers are sorted and
> not the 
> names. Is there a way to sort names + numbers or is this behaviour of
> sort() 
> unintended?
> 
> Martin
> 
> R 2.0.1-1 debian reposit.
> 
> __
> [EMAIL PROTECTED] mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide!
> http://www.R-project.org/posting-guide.html
> 
> 
> 
>   
> __ 
> 
> Dress up your holiday email, Hollywood style. Learn more.
> 
> __
> [EMAIL PROTECTED] mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide! 
> http://www.R-project.org/posting-guide.html
> 
>

__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


RE: [R] sort() leaves row names unaffected

2004-12-14 Thread Liaw, Andy
The problem, I think, boils down to the following:

> x <- matrix(c(3, 1, 2), ncol=3, dimnames=list(NULL, letters[1:3]))
> x
 a b c
[1,] 3 1 2
> sort(x)
 a b c
[1,] 1 2 3
> y <- rbind(x, c(1,1,2))
> y
 a b c
[1,] 3 1 2
[2,] 1 1 2
> sort(y)
 a b c
[1,] 1 1 2
[2,] 1 2 3

I.e., I'm guessing your `df1.y' is a matrix with one row and column names
`a' through `e'.  When you sort() a matrix, sort() simply treat it as a
vector (as a matrix in R is just a vector with a dim attribute) and sort
that (by stacking columns).  The output is sorted, but with the original
dimension and dimnames as the input.

Perhaps sort() should be made generic with methods for
matrix/array/data.frame, but one needs to think about what the logical thing
to do if no other argument is given...  In any case, it shouldn't give you
the result you're expecting (at least not by default): you are expecting the
result to be sorted columns, which hardly makes sense if there are more than
one row.

Andy

> From: Martin Wegmann
> 
> Hello, 
> 
> I wonder if I ran into a bug. If I do 
> 
> summary(df1$X1) -> df1.y
> 
> df1.y
> a  b   c   d  e
> [1,] 50.74627 8.955224 17.91045 19.40299 2.985075
> 
> sort(df1.y) 
>a  b   c   d  e
> [1,] 2.985075 8.955224 17.91045 19.40299 50.74627
> 
> my numbers are sorted but do not anymore correspond to the rownames. 
> For me it is counterintuitive that solely the numbers are 
> sorted and not the 
> names. Is there a way to sort names + numbers or is this 
> behaviour of sort() 
> unintended?
> 
> Martin
> 
> R 2.0.1-1 debian reposit.
> 
> __
> [EMAIL PROTECTED] mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide! 
> http://www.R-project.org/posting-guide.html
> 
>

__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


Re: [R] Several questions in R

2004-12-14 Thread antonio rodríguez
El Martes, 14 de Diciembre de 2004 12:30, jing tang escribió:
> Hi,
> I have several small question in R,
> 1) How to display all the variables in current workspace?

ls()

> 2) How to write a long command in two lines. Suppose one command line is
> long to be put within one line.

just push 'Enter' key, a '+' will appear so you can continue

antonio

> Thanks!
> tang
>
> __
> [EMAIL PROTECTED] mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide!
> http://www.R-project.org/posting-guide.html

__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


RE: [R] Moving standard deviation?

2004-12-14 Thread Martin Maechler
> "bogdan" == bogdan romocea <[EMAIL PROTECTED]>
> on Mon, 13 Dec 2004 12:26:46 -0800 (PST) writes:

bogdan> A simple for loop does the job. Why not write your own function?

 movsd <- function(series,lag)
 {
 movingsd <- vector(mode="numeric")
 for (i in lag:length(series))
 {
 movingsd[i] <- sd(series[(i-lag+1):i])
 }
 assign("movingsd",movingsd,.GlobalEnv)
 }

bogdan> This is very efficient: it takes (much) less time to write from
bogdan> scratch than to look for an existing function.

yes, it's fine, but the assign() line is really something so
much not-recommendable `` I can't let go through '' :

Your  movsd() provides a function with ``side effect'' : it
"suddenly" creates a global variable 'movingsd' {overwriting
another one, if there was one} instead of doing
the most natural thing for an S (or R) function:  *return* it's
computation:

So, please, use instead something like

 movsd <- function(series,lag)
 {
msd <- vector(mode="numeric")
for (i in lag:length(series))
{
msd[i] <- sd(series[(i-lag+1):i])
}
msd
 }

and then things like

sy1.3 <- movsd(y1, 3)
sy1.5 <- movsd(y1, 5)
sy2.5 <- movsd(y2, 5)

etc.

__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


Re: [R] Switching to Mac, suggestions? (was switching to linux)

2004-12-14 Thread Siegfried Gonzi
Jari Oksanen wrote:
On 13 Dec 2004, at 19:53, doktora v wrote:
I'm looking to switch to Mac platform. Anyone had any experience
with that? I'm expecting on a power G4 laptop later this week hope
R behaves...

I have been a Linux user since 1999, and I got my first ever Mac 
(iBook G4 laptop) last December. There is just as little to comment on 
MacOS X as there is to comment on flavours of Linux distros: there is 
no large difference as regards to R. I still prefer emacs & ess as a 
shell (but you can get some kind of real emacs in Mac as well), but 
MacOS X/ R is more of an eye candy (though I find it really hard to 
get any real use for transparent windows in R: I still prefer to see 
what I type instead of looking the background through the text). As 
regards to R, it is just the same if you have any brand of Linux or 
MacOS X or even a fringe system like Windows. The differences are 
somewhere else than in R.

By the way, Ubuntu "GNU"/Linux works nicely in Mac, with blas who 
knows about the vector processor in G4. 

Hello:
When relating Mac OSX to Linux there is one thing always worth to note: 
'virtual desktops'. I have seen some mad Mac addicts who neglect the 
fact that 'virtual desktops' are one of the most useful things among X11 
environments. Expose comes nowhere near though!

Typically virtual desktops on the Mac are an add-on feature and cost money.
I prefer to use "Desktop Manager 0.5.1 by Rich Wareham', though, it is 
beta but it is damn stable -- at least in my case. The beta version was 
free but I think I should start my plan of sending the great guy behind 
the project at least a good cigar:

http://wsmanager.sourceforge.net/
I happen to have engaged typically 6 to 8 virtual desktops at the same 
time.

And when we are at that: one should try to install the Emacs from 
source. There is also an Emas version tailored to "Carbon" out there, 
but the X11 Emacs is more what one is used to comming from Unix or Linux.

That is all what one needs on Mac OSX.
Regards,
S. Gonzi
__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


Re: [R] UPGMA

2004-12-14 Thread Martin Maechler
> "Thomas" == Thomas Isenbarger <[EMAIL PROTECTED]>
> on Mon, 13 Dec 2004 14:27:56 -0600 writes:

Thomas> R-help folks:

Thomas> Thanks in the past for your help.  I have another
Thomas> question that I hope has a simple answer.  I have
Thomas> searched the R home pages and the R-help archives
Thomas> with no hits.  How can I cluster data in R using
Thomas> UPGMA?

library(cluster)
?agnes  # uses method="average" aka UPGMA by default

or
?hclust # has  method="average" as well.


I've added a \concept{} to agnes such that from the next version
of "cluster", 
   help.search("UPGMA clustering") 
will find agnes().

Martin Maechler, ETH Zurich

__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


[R] Plotting Speed: R vs Octave

2004-12-14 Thread Suhail


Hi, 

Is this the mailing address of Chunlou Yung who used to work at Perform.com

-Suhail

__
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html