Re: [R] Displaying R, N, Z-symbols with expression

2007-11-22 Thread Paul Murrell
Hi David Winsemius wrote: C.J.Albers [EMAIL PROTECTED] wrote in news:[EMAIL PROTECTED]: Hi all, (Apologies if this has been asked before; I tried to search for it in the archives, but searching for terms like 'N' yields too many hits) Is it possible to display symbols like 'R' (the

Re: [R] Displaying R, N, Z-symbols with expression

2007-11-22 Thread David Winsemius
C.J.Albers wrote: Hi all, (Apologies if this has been asked before; I tried to search for it in the archives, but searching for terms like 'N' yields too many hits) Is it possible to display symbols like 'R' (the set of real numbers, so with an additional vertical line on the left) in

Re: [R] How can I save a plot ?

2007-11-22 Thread John Wiedenhoeft
Try something like: pdf(file=filename.pdf) plot(...) dev.off(); works with other formats as well. Type ?Devices Hope that helps, John On Wednesday 21 November 2007 21:45:38 Maura E Monville wrote: I recently installed R 2.6 on Linux/SuSE When I was running the previous version on Windows I

[R] Odp: t.test : extracting Error

2007-11-22 Thread Petr PIKAL
Hi [EMAIL PROTECTED] napsal dne 20.11.2007 09:36:32: Hi Thanks for the reply. I implemented your solution to my problem but ... For some of my column there is not enough data to do t-test so it gives me error and stops the for loop, is any graceful way to check for error msg and say

[R] Naming elements of a list

2007-11-22 Thread Thomas L Jones, PhD
I have a numeric vector of lenth 1. I am trying to use it inside a function just by giving its name, rather than specifying it as an argument to the function. I am aware that there is an attach function which you need to call. The attach function will accept a list. However, I don't seem to be

Re: [R] Naming elements of a list

2007-11-22 Thread Bernardo Rangel Tura
On Thu, 2007-11-22 at 03:16 -0500, Thomas L Jones, PhD wrote: I have a numeric vector of lenth 1. I am trying to use it inside a function just by giving its name, rather than specifying it as an argument to the function. I am aware that there is an attach function which you need to call. The

Re: [R] grDevices package

2007-11-22 Thread Uwe Ligges
amna khan wrote: Dear Sir grDevices package is not found in packages list? It is a base package that ships with R. Uwe Ligges Thank You __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the

Re: [R] Plotting + saving to file on Linux

2007-11-22 Thread peter360
Maura, The following worked for me. Hope it helps. I did a plot, the graphics showed up on my screen. Then I did dev.copy2eps(), the graphics was saved to a file called Rplot.eps. I tried dev.copy(pdf) or dev.copy(png), but for some reason they generated 0 sized files for me. I didn't figure

[R] A installation problem that needs your supports.

2007-11-22 Thread PING-SHAN_CHEN
Hi Sirs: This is Ping-Shan Chen from ProMOS Technologies in Taiwan. I have a installation problem that needs your supports. Some error messages as follows occured while installing R on Unix server. Anyone could tell me how to fix this issue? The OS version is Enterprise Linux AS release 4

[R] instalation problem WXP

2007-11-22 Thread Petr PIKAL
Dear R developers I encountered a slight problem with instalation of new R versions. Up to 2.6.0 allwas OK. R 2.6.1rc and 2.7.0dev do not install due to inability to write C:\Documents..\PikalP\*.tmp file. I am not sure if it is a change of some MS instalation routines or if it is a change in

[R] Vectorize a correlation matrix

2007-11-22 Thread Serguei Kaniovski
Hello I can construct a correlation matrix from an (ordered) vector of correlation coefficients as follows: x - c(0.1,0.2,0.3,0.4,0.5) n - length(x) cmat - diag(rep(0.5,n)) cmat[lower.tri(cmat,diag=0)] - x cmat - cmat+t(cmat) But how to do the reverse operation, i.e. produce x from cmat?

[R] Matrix of dummies from a vector

2007-11-22 Thread Serguei Kaniovski
Hallo From a variable x that defines, say, four classes, I would like to define the matrix mat of dummy variables indicating the classes, i.e. x - c(1,1,1,1,2,2,2,3,3,3,4,4) mat - matrix(c(1,0,0,0, 1,0,0,0, 1,0,0,0, 1,0,0,0, 0,1,0,0, 0,1,0,0, 0,1,0,0, 0,0,1,0, 0,0,1,0, 0,0,1,0, 0,0,0,1,

Re: [R] Heatmap problem

2007-11-22 Thread Jim Lemon
affy snp wrote: Hi friends, I used heatmap(as.matrix(y2),col=rainbow(256),scale = column) to generate the heatmap. But it did not show the code that which color correspond the value. Is there any parameter for this in heatmap()? Hi Allen, If you want colors corresponding to the values

[R] manual parallel processing

2007-11-22 Thread jgarcia
Hi; I have a R script that includes a call to genoud(); genoud process lasts about 4 seconds, what would be OK if I hadn't have to call it about 2000 times. This yields about 2 hours of processing. And I would like to use this script operationally; so that it should be run twice a day. It seems to

[R] testing independence of categorical variables

2007-11-22 Thread Shoaaib Mehmood
hi, is there a way of calculating of measuring dependence between two categorical variables. i tried using the chi square test to test for independence but i got error saying that the lengths of the two vectors don't match. Suppose X and Y are two factors. X has 5 levels and Y has 7 levels. This

Re: [R] Vectorize a correlation matrix

2007-11-22 Thread Duncan Murdoch
Serguei Kaniovski wrote: Hello I can construct a correlation matrix from an (ordered) vector of correlation coefficients as follows: x - c(0.1,0.2,0.3,0.4,0.5) n - length(x) cmat - diag(rep(0.5,n)) cmat[lower.tri(cmat,diag=0)] - x cmat - cmat+t(cmat) But how to do the reverse

Re: [R] Naming elements of a list

2007-11-22 Thread Richard . Cotton
Thomas, I have a numeric vector of lenth 1. I am trying to use it inside a function just by giving its name, rather than specifying it as an argument to the function. I am aware that there is an attach function which you need to call. The attach function will accept a list. However, I don't

Re: [R] Packages - a great resource, but hard to find the right one

2007-11-22 Thread Antony Unwin
There have been several constructive responses to John Sorkin's comment, but none of them are fully satisfactory. Of course, if you know the name of the function you are looking for, there are lots of ways to search — provided that everyone calls the function by a name that matches your

[R] Cutting a vector

2007-11-22 Thread Dani Valverde
Hello, I have a vector, lets say x - 1:50 I would like it to be cut at certain points, being for example 1:5, 6:11, 12:17, ... How can I do it? I have tried the cut() function, but I don not know how to place the cutting points properly. Best regards, Dani -- Daniel Valverde Saubí Grup de

[R] Odp: Cutting a vector

2007-11-22 Thread Petr PIKAL
Hi you shall be more specific. Do you want to split your vector according some pionts split(x, findInterval(x, c(6,12,16))) if you want to make a factor from your x vector, then you can use findInterval or cut cut(x, breaks = c(0,6,12,17, +Inf)) Or something else? Regards Petr [EMAIL

Re: [R] Heatmap problem

2007-11-22 Thread Boks, M.P.M.
Try Heatmap.2 in the gplots package. BW, Marco -Oorspronkelijk bericht- Van: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Namens Jim Lemon Verzonden: donderdag 22 november 2007 11:21 Aan: affy snp CC: r-help@r-project.org Onderwerp: Re: [R] Heatmap problem affy snp wrote: Hi friends,

[R] question about extreme value distribution

2007-11-22 Thread Avril Coghlan
Hello, I have a question about using extreme value distribution in R. I have two variables, X and Y, and have pairs of points (X1,Y1),(X2,Y2), (X3,Y3) etc. When I plot X against Y, it looks like the maximum value of Y (for a particular X) is correlated with X. Indeed, when I bin the data by

Re: [R] Cutting a vector

2007-11-22 Thread jim holtman
Here is another way of doing it: x - 1:50 split(x, as.integer(seq(0, by=1, length=length(x))/5)) $`0` [1] 1 2 3 4 5 $`1` [1] 6 7 8 9 10 $`2` [1] 11 12 13 14 15 $`3` [1] 16 17 18 19 20 $`4` [1] 21 22 23 24 25 $`5` [1] 26 27 28 29 30 $`6` [1] 31 32 33 34 35 $`7` [1] 36 37 38 39 40

Re: [R] Cutting a vector

2007-11-22 Thread jim holtman
Forget the last message. I hit return before understanding the question. Its too early on Thanksgiving and I just put the turkey in the oven. I would have an excuse if I were already sampling the punch. On Nov 22, 2007 8:15 AM, jim holtman [EMAIL PROTECTED] wrote: Here is another way of doing

[R] Summary: Process multiple columns of data.frame

2007-11-22 Thread Thompson, David (MNR)
Thank you Jim Holtman and Mark Leeds for your help. Original question: How do I do the following more concisely? Bout[is.na(Bout$bd.n), 'bd.n'] - 0 Bout[is.na(Bout$ht.n), 'ht.n'] - 0 Bout[is.na(Bout$dbh.n), 'dbh.n'] - 0 . . . Solution: for (i in c('bd.n', 'ht.n', 'dbh.n'))

[R] match

2007-11-22 Thread Marco chiapello
Hi, I'm new about R. My problem is: I have 2 lists of proteins and I would compare them. I import the 2 lists like 2 different matrixs and I would that the first entry in the matrix 1 match with all entries of the matrix 2, then the second entry of the matrix 1 matchs with all entries of the

Re: [R] manual parallel processing

2007-11-22 Thread Martin Morgan
Hi Javier The Rmpi or snow packages might help, e.g., mpi.parLapply; you need to pay attention to what gets (explicitly or implicitly) shared with other nodes. Martin [EMAIL PROTECTED] writes: Hi; I have a R script that includes a call to genoud(); genoud process lasts about 4 seconds, what

Re: [R] Odp: Cutting a vector

2007-11-22 Thread jim holtman
If you want to 'cut' the vector into equal lengths of 4, for example, then the following would work: split(x, as.integer((seq_along(x) - 1) / 4)) On Nov 22, 2007 9:44 AM, Dani Valverde [EMAIL PROTECTED] wrote: Hello, That's very useful. I think the cut() function is the key. However, in my

Re: [R] Odp: Cutting a vector

2007-11-22 Thread Dani Valverde
Hello, That's very useful. I think the cut() function is the key. However, in my real vector I have 13112 points. I would like the function to cut the vector every certain number of points (ie 4). Is there a way to specify this without the need of writing each cutting point? For example, I do

Re: [R] Plotting + saving to file on Linux

2007-11-22 Thread Peter Dalgaard
peter360 wrote: Maura, The following worked for me. Hope it helps. I did a plot, the graphics showed up on my screen. Then I did dev.copy2eps(), the graphics was saved to a file called Rplot.eps. I tried dev.copy(pdf) or dev.copy(png), but for some reason they generated 0 sized files for

Re: [R] fitting a line to a logaritmic plot

2007-11-22 Thread John Kane
Could you calculate the log values of the two sections, fit the line, and use lines() to draw them? --- Joren Heit [EMAIL PROTECTED] wrote: Hi, I have processed measurements of a rough surface to a heigh-height correlation plot. What the meaning of this exactly is, is not important.

Re: [R] match

2007-11-22 Thread jim holtman
Can you provide an example of the input data and what you would like the output to be. When you say first entry is this a single cell, or the whole row? So an example would help to understand what you are after. On Nov 22, 2007 8:45 AM, Marco chiapello [EMAIL PROTECTED] wrote: Hi, I'm new

[R] Package specific dependencies...

2007-11-22 Thread Neil Shephard
Hi, I noticed recently when installing the GDD package for R under GNU/Linux that it required the gd library (http://libgd.org/) for generating graphics. The resolution of this was to simply install the library on my system, and then GDD successfully installed without any complaints. However,

Re: [R] A installation problem that needs your supports.

2007-11-22 Thread Marc Schwartz
On Thu, 2007-11-22 at 17:30 +0800, [EMAIL PROTECTED] wrote: Hi Sirs: This is Ping-Shan Chen from ProMOS Technologies in Taiwan. I have a installation problem that needs your supports. Some error messages as follows occured while installing R on Unix server. Anyone could tell me how to

Re: [R] Package specific dependencies...

2007-11-22 Thread Gabor Grothendieck
The SystemRequirements field on the DESCRIPTION file is used to document the system requirements. For example, the DESCRIPTION file for Ryacas (which requires yacas) is shown below. Package: Ryacas Version: 0.2-8 Date: 2007-08-22 Title: R interface to the yacas computer algebra system Author:

[R] Any useR conference in US in YR2008

2007-11-22 Thread Wensui Liu
Dear usRs, Is there any conference for usR in US next year? Happy Turkey day! wensui __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and

Re: [R] Heatmap problem

2007-11-22 Thread affy snp
Hi Jim, The problem with color2D.matplot is that it cannot do dendrogram which I want. Thanks! Allen On 11/22/07, Jim Lemon [EMAIL PROTECTED] wrote: affy snp wrote: Hi friends, I used heatmap(as.matrix(y2),col=rainbow(256),scale = column) to generate the heatmap. But it did not

Re: [R] Heatmap problem

2007-11-22 Thread affy snp
Hi Marco, Thanks! I actually tried heatmap.2 earlier but I observed dot line along each column generated as well. Allen On 11/22/07, Boks, M.P.M. [EMAIL PROTECTED] wrote: Try Heatmap.2 in the gplots package. BW, Marco -Oorspronkelijk bericht- Van: [EMAIL PROTECTED]

Re: [R] Any useR conference in US in YR2008

2007-11-22 Thread Marc Schwartz
On Thu, 2007-11-22 at 11:58 -0500, Wensui Liu wrote: Dear usRs, Is there any conference for usR in US next year? Happy Turkey day! wensui R related conferences, at least those officially related to the R Foundation, are listed here: http://www.r-project.org/conferences.html This past

Re: [R] Any useR conference in US in YR2008

2007-11-22 Thread Wensui Liu
Thank you so much, Marc! So if I understand correctly, there is no conference related to R in US in the coming yr2008. Am I correct? On 11/22/07, Marc Schwartz [EMAIL PROTECTED] wrote: On Thu, 2007-11-22 at 11:58 -0500, Wensui Liu wrote: Dear usRs, Is there any conference for usR in US next

Re: [R] Any useR conference in US in YR2008

2007-11-22 Thread Marc Schwartz
None sponsored by the R Foundation. There may be others, offered by the various companies who offer R/S-PLUS training. They do periodically post e-mails about them on these lists. Regards, Marc On Thu, 2007-11-22 at 12:44 -0500, Wensui Liu wrote: Thank you so much, Marc! So if I understand

Re: [R] Vectorize a correlation matrix

2007-11-22 Thread Michael Dewey
At 09:58 22/11/2007, Serguei Kaniovski wrote: Hello I can construct a correlation matrix from an (ordered) vector of correlation coefficients as follows: x - c(0.1,0.2,0.3,0.4,0.5) n - length(x) cmat - diag(rep(0.5,n)) cmat[lower.tri(cmat,diag=0)] - x cmat - cmat+t(cmat) cmat [,1] [,2]

Re: [R] function for all binomial combinations?

2007-11-22 Thread chenxh007
t(combn(4,2)) in the package *combinat* produce this function. Xiaohui Michael Wolf wrote: Dear all, Is there a function that computes all binomial combinations. I am aware of the function choose(n, k) which computes the number of such combinations, but not the actual combinations

[R] Problem with tsboot

2007-11-22 Thread John Theal
I'm trying to bootstrap some regression coefficients so that I can estimate confidence intervals, but boot is not producing results. Can anybody suggest what I'm doing wrong here? SpecPress - ts(rnorm(501)) Returns - ts(rnorm(501)) BootData - data.frame(cbind(SpecPress, Returns))

[R] function for all binomial combinations?

2007-11-22 Thread Michael Wolf
Dear all, Is there a function that computes all binomial combinations. I am aware of the function choose(n, k) which computes the number of such combinations, but not the actual combinations themselves, e.g.: choose(4, 2) [1] 6 So I am looking for function that would give me the following

[R] how to build a saturated model for logistic regression?

2007-11-22 Thread Wensui Liu
Dear Listers, Sorry for bothering you on Thxgiving. I am just curious how to build a saturated model for logistic regression or other kinds of regression. Thank you so much! wensui __ R-help@r-project.org mailing list

[R] problem updating packages on Ubuntu 7.10

2007-11-22 Thread Daniel Nordlund
I am running Ubuntu 7.10 and R-2.6.0, and I am having trouble updating packages. There appears to be a problem involving gfortran. For example, here is the output of an attempt to update the Hmisc package. * Installing *source* package 'Hmisc' ... ** libs gfortran -fpic -g -O2 -c cidxcn.f

[R] apache and php running R

2007-11-22 Thread Bill Szkotnicki
Hi, I am trying to run an R program ( linux ) from php to create a graph and other things for a webpage. The R program is stored in /tmp and to create a graph I use the png function i.e. png(filename = /tmp/trialcsvt8wafB.png, width = 720, height = 480) But when the userid apache ( which is what

Re: [R] R 2.6.0 Error in X11() : could not find X11 fonts

2007-11-22 Thread Patrick Connolly
On Wed, 21-Nov-2007 at 01:10PM -0800, Correia, James wrote: | All- | I have rhel4 and just installed R2.6.0. The error suggests it cant find the font library. I have failed to trouble shoot. Can anyone help me? | Thanks I'm interested to know about your experience. I use rhel3 and ran into a

[R] anova planned comparisons/contrasts

2007-11-22 Thread Tyler Smith
Hi, I'm trying to figure out how anova works in R by translating the examples in Sokal And Rohlf's (1995 3rd edition) Biometry. I've hit a snag with planned comparisons, their box 9.4 and section 9.6. It's a basic anova design: treatment - factor(rep(c(control, glucose, fructose,

[R] Cluster Analysis:build a classifier?

2007-11-22 Thread x_x
Dear All, I'm currently doing a project about unsupervised learning, and I'll be using R to analyse a few network traffic datasets downloaded off Andrew Moore's website (http://www.cl.cam.ac.uk/Research/SRG/netos/nprobe/data/papers/sigmetrics/index.html). Could anyone shed some light on how to

Re: [R] how to build a saturated model for logistic regression?

2007-11-22 Thread Rolf Turner
On 23/11/2007, at 8:36 AM, Wensui Liu wrote: Dear Listers, Sorry for bothering you on Thxgiving. This is a world-wide list, not just a U.S. one. Many of us are not particularly ``bothered''! I am just curious how to build a saturated model for logistic regression or other

Re: [R] R 2.6.0 Error in X11() : could not find X11 fonts

2007-11-22 Thread michael watson (IAH-C)
Been through the mill on this one ;) Prof Ripley found a workaround: http://tolstoy.newcastle.edu.au/R/e2/help/07/05/17402.html Still haven;t found the right fonts though ;) -Original Message- From: [EMAIL PROTECTED] on behalf of Patrick Connolly Sent: Thu 22/11/2007 7:33 PM To:

Re: [R] anova planned comparisons/contrasts

2007-11-22 Thread Peter Alspach
Tyler For balanced data like this you might find aov() gives an output which is more comparable to Sokal and Rohlf (which I don't have): trtCont - C(sugars$treatment, matrix(c(-4,1,1,1,1, 0,-1,3,-1,-1), 5, 2)) sugarsAov - aov(length ~ trtCont, sugars) summary(sugarsAov,

Re: [R] Packages - a great resource, but hard to find the right one

2007-11-22 Thread Johannes Hüsing
Antony Unwin [EMAIL PROTECTED] [Thu, Nov 22, 2007 at 12:43:07PM CET]: There have been several constructive responses to John Sorkin's comment, but none of them are fully satisfactory. Of course, if you know the name of the function you are looking for, there are lots of ways to search ?

[R] axis invertion

2007-11-22 Thread Juan Pablo Fededa
Hi all, I want to invert the y axis of a plot, how can I do that in an easy way? Thanks in advance, Juan Pablo __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide

[R] Clean programming with R

2007-11-22 Thread Christophe Genolini
Hi all Is there any compiler for R ? By compiler, I mean something that check the cleanliness of the code : if we declare all the variables we use, if we don't use external variable from a function and so on... For exemple, something that will ring a bell on the following code (saying line 4 :

[R] Lafiesta המסיבה - פורטל האירועים של ישראל

2007-11-22 Thread עמיר
Lafiesta המסיבה - פורטל האירועים של ישראל האירוע שלכם מתחיל כאן www.lafiesta.co.il תעבירו הלאה __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide

Re: [R] axis invertion

2007-11-22 Thread Peter Dalgaard
Juan Pablo Fededa wrote: Hi all, I want to invert the y axis of a plot, how can I do that in an easy way? Thanks in advance, Plot x vs. y, then rotate paper 90 degrees clockwise? ;-) Seriously, switching the endpoint as in ylim=c(ymax,ymin) should do the trick. Or maybe

Re: [R] Clean programming with R

2007-11-22 Thread Duncan Murdoch
On 22/11/2007 5:12 PM, Christophe Genolini wrote: Hi all Is there any compiler for R ? By compiler, I mean something that check the cleanliness of the code : if we declare all the variables we use, if we don't use external variable from a function and so on... For exemple, something that

[R] more outrageous plotting

2007-11-22 Thread Juan Pablo Fededa
Dear Contributors: I have the next matrix: X Y Z 1 2 526 2 5 723 310 110 4 7 1110 5 9 34 6 8 778 7 1 614 8 4 876 9 6 249 10 3 14 I want to order the matrix from bigest Z (1110) to lower Z (14). Then I

[R] printing levels as tuples

2007-11-22 Thread Alexy Khrabrov
I'm running rle() on a long vector, and get a result which looks like uc Run Length Encoding lengths: int [1:16753] 1 1 1 1 1 1 1 1 1 1 ... values : int [1:16753] 29462748 22596107 18322820 14323315 12684505 9909036 7296916 6857692 5884755 5883697 ... I can print uc$names or uc$levels

Re: [R] more outrageous plotting

2007-11-22 Thread Moshe Olshansky
One way to do this may be to create the right image and show it. I have never user R for image processing so I can not provide any details, but I would have done the following: Create a 100x100 (or 1000x1000) white image. Then (assuming that it is a 100x1000 image), for each pair of your (x,y) you

Re: [R] Clean programming with R

2007-11-22 Thread Gabor Grothendieck
See the codetools package: library(codetools) checkUsage(power) anonymous: local variable 'p' assigned but may not be used findGlobals(power) [1] ^ { - pp return On Nov 22, 2007 5:12 PM, Christophe Genolini [EMAIL PROTECTED] wrote: Hi all Is there any compiler for R ? By

Re: [R] testing independence of categorical variables

2007-11-22 Thread Moshe Olshansky
Hi, When testing whether random variables X and Y are independent the usual assumption is that you have n pairs of outcomes - (X1,Y1), (X2,Y2), ... , (Xn,Yn) and you are basically checking whether the value of X affects the value of Y. If you have 7 observations of X and 5 separate observations

[R] BUG: choose function

2007-11-22 Thread Luis Salasar
Hi, I have used the function choose(n, k) sometimes, and i realized that it doesn't work properly for n 0. For example, if one tries choose(-1, 3), it should be returned the value (-1)^3 = -1, since choose (-1, 3) = (-1)*(-2)*(-3)/3! = (-1)^3, but indeed R returns the value 0. I am using

Re: [R] more outrageous plotting

2007-11-22 Thread hadley wickham
Hi Juan, Assuming that your data frame is named df, something like the following should work: library(ggplot) qplot(X, Y, data = df, colour = Z, label = Z, geom = text) + scale_colour_continuous(low=orange, high = blue) You can find out more about ggplot2 at http://had.co.nz/ggplot2. Hadley

Re: [R] BUG: choose function

2007-11-22 Thread Duncan Murdoch
On 22/11/2007 8:11 PM, Benilton Carvalho wrote: well, choose(n, k) should actually return: factorial(n)/(factorial(n-k)*factorial(k)) That's not how the docs define it. They say Note that 'choose(n,k)' is defined for all real numbers n and integer k. For k = 1 as n(n-1)...(n-k+1)

[R] Problem with environments

2007-11-22 Thread Thomas L Jones, PhD
I have a numeric vector of length 1. I am trying to use it inside a function just by giving its name, rather than specifying it as an argument to the function. I am aware that there is an attach function which you need to call. The attach function will accept a list. However, I don't seem to be

Re: [R] printing levels as tuples

2007-11-22 Thread Moshe Olshansky
Not the most efficient way would be to use a loop If x is your rel object, you can do the following: for (i in 1:length(x$values)) { cat((,x$values[i],,,x$lengths[i],) ) if (i %% 10 == 0) cat(\n) } cat(\n) --- Alexy Khrabrov [EMAIL PROTECTED] wrote: I'm running rle() on a long vector,

[R] compiling R on a shared webhost

2007-11-22 Thread Greg Dingle
Hi, I'm trying to install the R language interpreter on a shared webhost, OpenSolaris platform. The installing is going fine except that the compiler runs into forking limits. g77: fork: Resource temporarily unavailable Is there a way to keeping the compiler from forking too much? Or does

Re: [R] BUG: choose function

2007-11-22 Thread Benilton Carvalho
well, choose(n, k) should actually return: factorial(n)/(factorial(n-k)*factorial(k)) R-2.6.0 works just fine for me so does R-2.5.1 so does R-2.4.1 b On Nov 22, 2007, at 8:04 PM, Luis Salasar wrote: Hi, I have used the function choose(n, k) sometimes, and i realized

Re: [R] Problem with environments

2007-11-22 Thread Gabor Grothendieck
Is this what you want? i - 3 f - function() get(i, parent.frame()) f() # 3 On Nov 22, 2007 10:38 PM, Thomas L Jones, PhD [EMAIL PROTECTED] wrote: I have a numeric vector of length 1. I am trying to use it inside a function just by giving its name, rather than specifying it as an argument to

Re: [R] R 2.6.0 Error in X11() : could not find X11 fonts

2007-11-22 Thread Patrick Connolly
On Thu, 22-Nov-2007 at 08:50PM -, michael watson (IAH-C) wrote: | Been through the mill on this one ;) | | Prof Ripley found a workaround: | | http://tolstoy.newcastle.edu.au/R/e2/help/07/05/17402.html That's a different mill. :-( My locale is en-NZ which I thought would have not had that

Re: [R] BUG: choose function

2007-11-22 Thread Benilton Carvalho
Thanks for the clarifcation, Duncan. Best, B On Nov 22, 2007, at 8:32 PM, Duncan Murdoch [EMAIL PROTECTED] wrote: On 22/11/2007 8:11 PM, Benilton Carvalho wrote: well, choose(n, k) should actually return: factorial(n)/(factorial(n-k)*factorial(k)) That's not how the docs define it.

Re: [R] Any useR conference in US in YR2008

2007-11-22 Thread Bill.Venables
Apropos this issue, the R Foundation has had an offer to host useR 2009 from a European based group rather than a North American based one. My understanding is that no decision has yet been taken, though. If other groups had an interest in hosting useR 2009, it might not be a bad idea to

Re: [R] BUG: choose function

2007-11-22 Thread Duncan Murdoch
On 22/11/2007 8:04 PM, Luis Salasar wrote: Hi, I have used the function choose(n, k) sometimes, and i realized that it doesn't work properly for n 0. For example, if one tries choose(-1, 3), it should be returned the value (-1)^3 = -1, since choose (-1, 3) = (-1)*(-2)*(-3)/3! =

Re: [R] printing levels as tuples

2007-11-22 Thread Moshe Olshansky
Or even print(paste((,y$values,,,y$lengths,) ,sep=),quote=FALSE) --- Gabor Grothendieck [EMAIL PROTECTED] wrote: Try this: x - c(a, a, b, b, b) # test input with(rle(x), paste(values, lengths)) [1] a 2 b 3 On Nov 22, 2007 7:32 PM, Alexy Khrabrov [EMAIL PROTECTED] wrote: I'm