Re: [R] Urgent

2008-07-29 Thread Moshe Olshansky
Hi Yunlei, Is your problem constrained or not? If it is unconstrained and your matrix is not positive definite, the minimum is unbounded (unless you are extremely lucky and the matrix is positive semi-definite and the vector which multiplies the unknowns is exactly perpendicular to all the eige

Re: [R] Re peated Measure ANOVA-Old question

2008-07-29 Thread Mark Difford
Hi Chunhao, >> I google the website and I found that there are three ways to perform >> repeated measure ANOVA: aov, lme and lmer. It's also a good idea to search through the archives. >> I use the example that is provided in the above link and I try >> > tt<-aov(p.pa~group*time+Error(subject

[R] Repeated Measure ANOVA-Old question

2008-07-29 Thread ctu
Hi R users, I google the website and I found that there are three ways to perform repeated measure ANOVA: aov, lme and lmer. http://www.mail-archive.com/[EMAIL PROTECTED]/msg58502.html But the questions are which one is good to use and how to do post-hoc test? I use the example that is provide

Re: [R] R command history -- can it be like Matlab's?

2008-07-29 Thread Spencer Graves
Regarding dubuggers, RSiteSearch("debug", "fun") produced 183 hits for me just now. The first two reference a "debug" package, while the third describes the "debug" function in the "base" package. The "debug{base}" function is great, but not as good as the Matlab debugger. The "de

Re: [R] Is there a better way to check if an element of a list exists than using match on names?

2008-07-29 Thread jim holtman
Is this what you want: > "var3" %in% names(ipf) [1] FALSE > "var1" %in% names(ipf) [1] TRUE > On Tue, Jul 29, 2008 at 6:20 PM, <[EMAIL PROTECTED]> wrote: > > Hello R mailing list > > Is there a better way than this to see if an element exists *within* a > list object : > > #generate "file.txt"

Re: [R] how to get the position of a vector-value

2008-07-29 Thread jim holtman
?findInterval > x <- c(1.0,1.2,1.4,1.6,1.8,2.0) > findInterval(1.4,x) [1] 3 > findInterval(1.5,x) [1] 3 > findInterval(10,x) [1] 6 On Tue, Jul 29, 2008 at 8:32 PM, Jörg Groß <[EMAIL PROTECTED]> wrote: > I am searching for a way to get nearest position of a number in a vector > from a search-valu

Re: [R] finding a faster way to do an iterative computation

2008-07-29 Thread dxc13
Thank you to all who applied. These all seem to work the way I want them to. The outer function seems really useful, I probably could use that for a lot of my work. Thanks! Rolf Turner-3 wrote: > > > On 30/07/2008, at 6:12 AM, dxc13 wrote: > >> >> useR's, >> >> I am trying trying to find out

Re: [R] rolling regression between adjacent columns

2008-07-29 Thread Gabor Grothendieck
Read the last line of every message to r-help. On Tue, Jul 29, 2008 at 6:15 PM, rcoder <[EMAIL PROTECTED]> wrote: > > Hi everyone, > > I am trying to apply linear regression to adjacent columns in a matrix (i.e. > col1~col2; col3~col4; etc.). The columns in my matrix come with identifiers > at the

Re: [R] rollapply() opertation on time series

2008-07-29 Thread Gabor Grothendieck
methods(rollapply) shows which classes have rollapply methods. On Tue, Jul 29, 2008 at 5:48 PM, rcoder <[EMAIL PROTECTED]> wrote: > > Hi Gabor, > > Thanks for your reply. Assuming I have a time series that is ready made > (i.e. not constructed it using a zoo function) will the procedure below > st

[R] how to get the position of a vector-value

2008-07-29 Thread Jörg Groß
I am searching for a way to get nearest position of a number in a vector from a search-value. So perhaps if I have this vector: 1.0 1.2 1.4 1.6 1.8 2.0 I want to get the position of a special number. with match(1.4 ,x), I get "3" for position three. But now I want the nearest numbe

Re: [R] table questions

2008-07-29 Thread Ted Harding
On 29-Jul-08 16:28:26, Edna Bell wrote: > Hi again! > Suppose I have the following: > >> xy <- round(rexp(20),1) >> xy > [1] 0.1 3.4 1.6 0.4 1.0 1.4 0.2 0.3 1.6 0.2 0.0 0.1 0.1 1.0 2.0 0.9 > 2.5 0.1 1.5 0.4 >> table(xy) > xy > 0 0.1 0.2 0.3 0.4 0.9 1 1.4 1.5 1.6 2 2.5 3.4 > 1 4 2 1

Re: [R] Legality Question about R's Open Source GNU GPL License

2008-07-29 Thread Charles Annis, P.E.
Gad and David - would you be so kind as to include me in any off-line discussion of this vital topic of R and GPL? Many thanks. Charles Annis, P.E. [EMAIL PROTECTED] phone: 561-352-9699 eFax: 614-455-3265 http://www.StatisticalEngineering.com -Original Message- From: [EMAIL PROTECTED

Re: [R] Legality Question about R's Open Source GNU GPL License

2008-07-29 Thread David Henderson
Hello Gad: On Jul 29, 2008, at 4:41 PM, Gad Abraham wrote: If your legal department is still concerned, have them look at the license in Java. It most likely is GPL (unless you have a special commercial version of Java installed) and thus makes any Java program you create subject to the G

Re: [R] Legality Question about R's Open Source GNU GPL License

2008-07-29 Thread Gad Abraham
Gad Abraham wrote: If your legal department is still concerned, have them look at the license in Java. It most likely is GPL (unless you have a special commercial version of Java installed) and thus makes any Java program you create subject to the GPL in Java due to the JIT compiler used in J

Re: [R] Colors in Sweave

2008-07-29 Thread Duncan Murdoch
On 27/07/2008 3:10 PM, Stephen Tucker wrote: Hi list, I was using Sweave and was wondering if anyone has had any luck changing the font colors of the code chunks. For instance, in my .Rnw preample I tried including: === \usepackage[usenames]{colors} \definecolor{darkred}{rgb}{0.545,0,0} \defi

Re: [R] Legality Question about R's Open Source GNU GPL License

2008-07-29 Thread Gad Abraham
If your legal department is still concerned, have them look at the license in Java. It most likely is GPL (unless you have a special commercial version of Java installed) and thus makes any Java program you create subject to the GPL in Java due to the JIT compiler used in Java. If your legal

[R] rolling regression between adjacent columns

2008-07-29 Thread rcoder
Hi everyone, I am trying to apply linear regression to adjacent columns in a matrix (i.e. col1~col2; col3~col4; etc.). The columns in my matrix come with identifiers at the top of each column, but when I try to use these identifiers to reference the columns in the regression function using rollap

Re: [R] rollapply() opertation on time series

2008-07-29 Thread rcoder
Hi Gabor, Thanks for your reply. Assuming I have a time series that is ready made (i.e. not constructed it using a zoo function) will the procedure below still retain the dates in the matrix? Thanks, rcoder quote author="Gabor Grothendieck"> rollapply along an index: library(zoo) z <- zoo(mat

[R] correlation between matrices - both with some NAs

2008-07-29 Thread rcoder
Hi everyone, I'm having trouble applying the Cor() function to two matrices, both of which contain NAs. I am doing the following: a<-cor(m1, m2, use="complete.obs") ... and I get the following error message: Error in cor(m1, m2, use = "complete.obs") : no complete element pairs Does anyone

Re: [R] placing a text in the corner of a plot

2008-07-29 Thread Ben Tupper
On Jul 29, 2008, at 6:47 PM, Jörg Groß wrote: legend("topleft",c("Your text here"),pch=1) Thanks! But is it possible to get rid of the legend-box and the box-shadow? I don't find an argument in the manual for that. Hi, The documentation for the argument is right there - but as always i

Re: [R] placing a text in the corner of a plot

2008-07-29 Thread Rolf Turner
On 30/07/2008, at 10:47 AM, Jörg Groß wrote: legend("topleft",c("Your text here"),pch=1) Thanks! But is it possible to get rid of the legend-box and the box-shadow? I don't find an argument in the manual for that. You explicitly said that you *wanted* a box!!! But be tha

Re: [R] Chi-square parameter estimation

2008-07-29 Thread Moshe Olshansky
If v is your vector of sample variances (and assuming that their distribution is chi-square) you can define f(df) <- sum(dchisq(v,df,log=TRUE)) and now you need to maximize f, which can be done using any optimization function (like optim). --- On Sat, 26/7/08, Julio Rojas <[EMAIL PROTECTED]> wr

Re: [R] Help interpreting density().

2008-07-29 Thread Bill.Venables
In general there is no relation. The output of density gives you something you can plot, essentially. So the x-values are simply a series of points covering the range of the density and the y values are the ordinates at those abscissae. try plot(density(rnorm(1000)^2))) for example. Bill Ven

Re: [R] Legality Question about R's Open Source GNU GPL License

2008-07-29 Thread David Henderson
Hi All: I know this has been discussed at length already, but 1) I get R-Help in digest and didn't see this until 3am Pacific time this morning, and 2) We, REvolution, have been discussing this as of late. I thought I would pass on some of the knowledge we have recently obtained vis a vi

Re: [R] placing a text in the corner of a plot

2008-07-29 Thread Jörg Groß
> legend("topleft",c("Your text here"),pch=1) Thanks! But is it possible to get rid of the legend-box and the box-shadow? I don't find an argument in the manual for that. Am 30.07.2008 um 00:08 schrieb Jorge Ivan Velez: > > Dear Jörg, > > Perhaps, > > plot(1:10) > legend("topleft",c("Your t

[R] What's the best way to operate R from within Excel?

2008-07-29 Thread losemind
Hi all, How do I operate R from within Excel? I mean, highlight a bunch of cells, and send to R, and do some statistics in R, and return back the numbers and do some plots in R. For example, I have some parameters for Gaussian Random variable, and I would find the most convenient way to send th

Re: [R] R command history -- can it be like Matlab's?

2008-07-29 Thread losemind
Prof Brian Ripley wrote: > > A patch to do this was posted on 2007-09-29 by Glenn Davis. Some people > not addicted to Matlab find the behaviour very inconvenient and prefer the > getline/readline behaviour (triggered by ^R/^S) of Rterm and R on Unixen. > > On Tue, 29 Jul 2008, losemind wro

Re: [R] finding a faster way to do an iterative computation

2008-07-29 Thread Moshe Olshansky
Try abs(outer(xk,x,"-")) (see ?outer) --- On Wed, 30/7/08, dxc13 <[EMAIL PROTECTED]> wrote: > From: dxc13 <[EMAIL PROTECTED]> > Subject: [R] finding a faster way to do an iterative computation > To: r-help@r-project.org > Received: Wednesday, 30 July, 2008, 4:12 AM > useR's, > > I am trying

[R] Is there a better way to check if an element of a list exists than using match on names?

2008-07-29 Thread Paul.Rustomji
Hello R mailing list Is there a better way than this to see if an element exists *within* a list object : #generate "file.txt" using current routine cat("var1=33\nvar2=TRUE",file="file.txt") #load file to a list called "ipf" f <- function(.file){source(.file,local=TRUE);as.list(environment())}

Re: [R] placing a text in the corner of a plot

2008-07-29 Thread Jorge Ivan Velez
Dear Jörg, Perhaps, plot(1:10) legend("topleft",c("Your text here"),pch=1) See ?legend and ?text for more information. HTH, Jorge On Tue, Jul 29, 2008 at 6:04 PM, Jörg Groß <[EMAIL PROTECTED]> wrote: > Is there an easy way to add a text into an R-plot and place it in the upper > left corner

[R] placing a text in the corner of a plot

2008-07-29 Thread Jörg Groß
Is there an easy way to add a text into an R-plot and place it in the upper left corner? Like that: | (a) | | | | | |

Re: [R] R command history -- can it be like Matlab's?

2008-07-29 Thread hadley wickham
On Tue, Jul 29, 2008 at 4:39 PM, Rolf Turner <[EMAIL PROTECTED]> wrote: > > On 30/07/2008, at 9:16 AM, hadley wickham wrote: > >> On Tue, Jul 29, 2008 at 2:45 PM, Prof Brian Ripley >> <[EMAIL PROTECTED]> wrote: >>> >>> A patch to do this was posted on 2007-09-29 by Glenn Davis. Some people >>> not

Re: [R] R command history -- can it be like Matlab's?

2008-07-29 Thread Rolf Turner
On 30/07/2008, at 9:16 AM, hadley wickham wrote: On Tue, Jul 29, 2008 at 2:45 PM, Prof Brian Ripley <[EMAIL PROTECTED]> wrote: A patch to do this was posted on 2007-09-29 by Glenn Davis. Some people not addicted to Matlab find the behaviour very inconvenient and prefer the getline/readline

Re: [R] R command history -- can it be like Matlab's?

2008-07-29 Thread hadley wickham
On Tue, Jul 29, 2008 at 2:45 PM, Prof Brian Ripley <[EMAIL PROTECTED]> wrote: > A patch to do this was posted on 2007-09-29 by Glenn Davis. Some people not > addicted to Matlab find the behaviour very inconvenient and prefer the > getline/readline behaviour (triggered by ^R/^S) of Rterm and R on U

Re: [R] finding a faster way to do an iterative computation

2008-07-29 Thread Rolf Turner
On 30/07/2008, at 6:12 AM, dxc13 wrote: useR's, I am trying trying to find out if there is a faster way to do a certain computation. I have successfully used FOR loops and the apply function to do this, but it can take some time to fully compute, but I was wondering if anyone may know

Re: [R] finding a faster way to do an iterative computation

2008-07-29 Thread Christos Hatzis
matrix(rep(x, each=13) - xk, nrow=13) > -Original Message- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] On Behalf Of dxc13 > Sent: Tuesday, July 29, 2008 2:13 PM > To: r-help@r-project.org > Subject: [R] finding a faster way to do an iterative computation > > > useR's, > > I

[R] finding a faster way to do an iterative computation

2008-07-29 Thread dxc13
useR's, I am trying trying to find out if there is a faster way to do a certain computation. I have successfully used FOR loops and the apply function to do this, but it can take some time to fully compute, but I was wondering if anyone may know of a different function or way to do this: > x [1]

[R] optimize simultaneously two binomials inequalities using nlm

2008-07-29 Thread emir.toktar
Dear R users, I´m trying to optimize simultaneously two binomials inequalities used to acceptance sampling, which are nonlinear solution, so there is no simple direct solution. Please, let me explain shortly the the problem and the question as following. The objective is to obtain the smallest v

Re: [R] try question

2008-07-29 Thread Mike Prager
"Edna Bell" <[EMAIL PROTECTED]> wrote: > Hi still yet again! > > I have the following code: > > > try(log(rnorm(25)),silent=TRUE) > [1] -0.26396185 NaN NaN -0.13078069 -2.44997193 > -2.15603971 NaN 0.94917495 0.07244544 NaN > [11] -1.06341127 -0.42293099 -0.537

Re: [R] R command history -- can it be like Matlab's?

2008-07-29 Thread Prof Brian Ripley
A patch to do this was posted on 2007-09-29 by Glenn Davis. Some people not addicted to Matlab find the behaviour very inconvenient and prefer the getline/readline behaviour (triggered by ^R/^S) of Rterm and R on Unixen. On Tue, 29 Jul 2008, losemind wrote: Hi all, In R GUI window, if you

Re: [R] Coarsening the Resolution of a Dataset

2008-07-29 Thread jim holtman
I assume that you are doing this on one column of the matrix which should only have 2160 entries in it. can you send the actual code you are using. I tried it with 10,000 samples and it works fine. So I need to understand the data structure you are using. Also the infinite recursion sounds stra

[R] R command history -- can it be like Matlab's?

2008-07-29 Thread losemind
Hi all, In R GUI window, if you use "up" and "down" key, you will be able to recall the previous and next command that has been used and stored in the command history cache. But there is one inconvenience: In Matlab, you can type the first a few characters of the command that you previously use

Re: [R] ls() and memory question

2008-07-29 Thread jim holtman
It is memory. You should probably not have 40% of your RAM allocated to R so that if you do create some large objects, you will have room for them. How much physical memory do you have, can you put some "numbers" on how many objects you need, if you have a lot of them, have you considered using l

Re: [R] combining zoo series with an overlapping index?

2008-07-29 Thread stephen sefick
My apologies it worked perfectly. On Tue, Jul 29, 2008 at 12:40 PM, stephen sefick <[EMAIL PROTECTED]> wrote: > plot(replace(day, is.list(index(lin)), coredata(lin))) > -- Let's not spend our time and resources thinking about things that are so little or so large that all they really do for u

Re: [R] Graphics function question

2008-07-29 Thread Marc Schwartz
Just a quick follow up to my own post here. In offline exchanges, Peter noted a typo in the call to plot(), where I was missing the final ")". Also, I had the order of the unnamed arguments to segments() off. Here is the corrected code, with some additional teaks: plotdiffs <- function(x, y,

Re: [R] table questions

2008-07-29 Thread Patrizio Frederic
# is that what you want? table(cut(xy,seq(0,max(xy)+.4,by=.4))) # or this table(cut(xy,hist(xy)$breaks)) # not the same regards, PF +- | Patrizio Frederic | Research associate in Statistics, | Department of Economics, | University of Modena and

Re: [R] List names help

2008-07-29 Thread Sarah Goslee
Sure, just set them to NULL. > mylist <- c(a=1, b=2, c=3) > mylist a b c 1 2 3 > names(mylist) <- NULL > mylist [1] 1 2 3 Sarah On Tue, Jul 29, 2008 at 1:45 PM, Rajasekaramya <[EMAIL PROTECTED]> wrote: > > hi , > > Is there anyways to delet the list names once created. > > i tried > rm(names(my

[R] Flexible semivariogram in R (HELP)

2008-07-29 Thread Alessandro
Hey All, I am a PhD student in Forestry science and I wish use kriging to spatial LiDAR cloud points. The shape of my semivariogram is like "hole (wave) model", but unfortunately I don't know the code of flexible model or hole model to fit my semivariogram in R. I Found it in google or in R he

[R] biplot_group_colours_and_point_symbols

2008-07-29 Thread Indermaur Lukas
hi, i am seeking for a solution to create a biplot that shows: a) data points instead of labels and that b) shows two different groups (field: site with two factor levels: forest/corridor) in different colours i tried to include "pch=19" to show points instead of labels in the syntax below but

[R] List names help

2008-07-29 Thread Rajasekaramya
hi , Is there anyways to delet the list names once created. i tried rm(names(mylist)) i didnt work kindly help me Ramya -- View this message in context: http://www.nabble.com/List-names-help-tp18717742p18717742.html Sent from the R help mailing list archive at Nabble.com. _

Re: [R] Graphics function question

2008-07-29 Thread Sarah Goslee
One clarification: I did the dirty and completely unprofessional thing, and assumed that this function would only be run in the workspace with all your data. I use functions like this frequently for something I need to do multiple times for a particular project, but will never do anywhere else, bu

Re: [R] Major Cloud Computing Testbed Announced at University of Illinois

2008-07-29 Thread Ajay ohri
*R we Wishing on a cloud-* I would like to Test R as an cloud analytical tool. remote submit csv files to the web for data mining , get data crunching with scalable processing power and disk storage , display Silverlight graphs of summarization, downloadable in pdf's. data mining on demand, o

Re: [R] Negative Binomial Regression

2008-07-29 Thread Ben Bolker
Prof Brian Ripley wrote: 'poisson' _family_, I presume? oops, yes. __ 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 provide commente

Re: [R] accessing list elements

2008-07-29 Thread Erik Iverson
Hello - Paul Adams wrote: Hello everyone, I have a list which I am trying to calculate a max value.I have the list as w<-c(v[[1]][1],...v[[100]][1]). The problem I am getting is that the function max is saying the list is an "invalid type (list) of argument".When I show the element v[[1]][1] it

Re: [R] try question

2008-07-29 Thread Prof Brian Ripley
On Tue, 29 Jul 2008, Edna Bell wrote: Hi still yet again! I have the following code: try(log(rnorm(25)),silent=TRUE) [1] -0.26396185 NaN NaN -0.13078069 -2.44997193 -2.15603971 NaN 0.94917495 0.07244544 NaN [11] -1.06341127 -0.42293099 -0.53769569 0.9513476

Re: [R] Negative Binomial Regression

2008-07-29 Thread Prof Brian Ripley
On Tue, 29 Jul 2008, Ben Bolker wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Prof Brian Ripley wrote: | On Tue, 29 Jul 2008, Ben Bolker wrote: | |> jcarmichael gmail.com> writes: |>> |>> Hello. |>> |>> I am attempting to duplicate a negative binomial regression in R. |>> SAS uses |>> g

Re: [R] Graphics function question

2008-07-29 Thread Marc Schwartz
on 07/29/2008 11:38 AM Peter Flom wrote: Hello I have created a graph using the following commands: <<< startBReP3O1T <- diffs$BReP3O1T - diffs$diff_BReP3O1T endBReP3O1T <- diffs$BReP3O1T x <- seq(47,89, length = 10) ymin <- min(min(startBReP3O1T), min(endBReP3O1T)) ymax <- max(max(startBReP3O

Re: [R] accessing list elements

2008-07-29 Thread Sarah Goslee
What's v? And w? And what exactly do you want to do? A small reproducible example would be very helpful. Without knowing what your data look like, it's hard to make helpful suggestions. Sarah On Tue, Jul 29, 2008 at 12:56 PM, Paul Adams <[EMAIL PROTECTED]> wrote: > > Hello everyone, > I have a

Re: [R] Graphics function question

2008-07-29 Thread Sarah Goslee
You can do it very easily using subsetting and a bit of paste(). I assumed you didn't need startdata and enddata after the plot has been made, but if you do you can change the last line of the function to return them. Sarah myfunction <- function(dataname) { # where dataname is a string, eg myf

Re: [R] Panel of pie charts

2008-07-29 Thread Gavin Simpson
On Tue, 2008-07-29 at 17:23 +0100, [EMAIL PROTECTED] wrote: > > I am looking to making a panel of pie charts fo some of my > > dritribution data . I was wondering if there is a way in any R > > package to write a small script to do so. > pie() will do you a one-off pie chart, but there is no eq

Re: [R] Removing script file

2008-07-29 Thread Prof Brian Ripley
On Tue, 29 Jul 2008, Dennis Fisher wrote: Colleagues, (Running R 2.7.0) I have a script that I want to delete as it completes execution. The penultimate line of the script (before the quit command) is: file.remove("Scriptname") The script is executed as: R --no-save < Scriptna

Re: [R] try question

2008-07-29 Thread Richard . Cotton
> > try(log(rnorm(25)),silent=TRUE) > [1] -0.26396185 NaN NaN -0.13078069 -2.44997193 > -2.15603971 NaN 0.94917495 0.07244544 NaN > [11] -1.06341127 -0.42293099 -0.53769569 0.95134763 0.93403340 > NaN -0.10502078 NaN 0.30283262 NaN > [21] -0.1

[R] accessing list elements

2008-07-29 Thread Paul Adams
Hello everyone, I have a list which I am trying to calculate a max value.I have the list as w<-c(v[[1]][1],...v[[100]][1]). The problem I am getting is that the function max is saying the list is an "invalid type (list) of  argument".When I show the element v[[1]][1] it shows as $statistic,V,73

[R] try question

2008-07-29 Thread Edna Bell
Hi still yet again! I have the following code: > try(log(rnorm(25)),silent=TRUE) [1] -0.26396185 NaN NaN -0.13078069 -2.44997193 -2.15603971 NaN 0.94917495 0.07244544 NaN [11] -1.06341127 -0.42293099 -0.53769569 0.95134763 0.93403340 NaN -0.10502078

Re: [R] combining zoo series with an overlapping index?

2008-07-29 Thread stephen sefick
plot(replace(day, is.list(index(lin)), coredata(lin))) [[alternative HTML version deleted]] __ 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

[R] Graphics function question

2008-07-29 Thread Peter Flom
Hello I have created a graph using the following commands: <<< startBReP3O1T <- diffs$BReP3O1T - diffs$diff_BReP3O1T endBReP3O1T <- diffs$BReP3O1T x <- seq(47,89, length = 10) ymin <- min(min(startBReP3O1T), min(endBReP3O1T)) ymax <- max(max(startBReP3O1T), max(endBReP3O1T)) y <- seq(ymin, ymax,

[R] ls() and memory question

2008-07-29 Thread Edna Bell
Hi again! I put in ls() to check the objects in my workspace. Is there a limit on how many objects I can have, please? Or does it depend on the memory, please? TIA, Edna Bell __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/

Re: [R] more environment questions

2008-07-29 Thread Gabor Grothendieck
No but look at proto since I suspect the creation of proto objects is basically what you are trying to do through the back door. Home page: http://r-proto.googlecode.com On Tue, Jul 29, 2008 at 12:29 PM, Edna Bell <[EMAIL PROTECTED]> wrote: > Is there a way to set the environment within a functi

Re: [R] more environment questions

2008-07-29 Thread Edna Bell
Is there a way to set the environment within a function,, please? On Tue, Jul 29, 2008 at 11:25 AM, Gabor Grothendieck <[EMAIL PROTECTED]> wrote: > e1 <- ... > creates a new environment e1 > > environment(e1) > does nothing > > print(environment(e1)) > print environment e1 > > By the way, if you

[R] table questions

2008-07-29 Thread Edna Bell
Hi again! Suppose I have the following: > xy <- round(rexp(20),1) > xy [1] 0.1 3.4 1.6 0.4 1.0 1.4 0.2 0.3 1.6 0.2 0.0 0.1 0.1 1.0 2.0 0.9 2.5 0.1 1.5 0.4 > table(xy) xy 0 0.1 0.2 0.3 0.4 0.9 1 1.4 1.5 1.6 2 2.5 3.4 1 4 2 1 2 1 2 1 1 2 1 1 1 > Is there a way to s

[R] Question regarding statisticians

2008-07-29 Thread Max
Hi Everyone, I'm apologize for asking this in the R-general list, but I'm unsure of where else to ask this burning question of mine: Where do statisticians talk on the internet about professional/ career developement/ issues? I've found many a list (much like this one) that specailize in tal

Re: [R] more environment questions

2008-07-29 Thread Gabor Grothendieck
e1 <- ... creates a new environment e1 environment(e1) does nothing print(environment(e1)) print environment e1 By the way, if you are doing a lot of manipulations of environments you might want to look at the proto package which reframes the whole thing in terms of object oriented programming.

Re: [R] Panel of pie charts

2008-07-29 Thread Richard . Cotton
> I am looking to making a panel of pie charts fo some of my > dritribution data . I was wondering if there is a way in any R > package to write a small script to do so. pie() will do you a one-off pie chart, but there is no equivalent using grid/ lattice graphics. You could write a panel.pie

[R] more environment questions

2008-07-29 Thread Edna Bell
Hi R Gurus: Here is some code that I was experimenting with, please: > f1 <- function(x) { + e1 <- new.env(parent=.GlobalEnv) + environment(e1) + print(environment()) + return(mean(x)) + } > f1(1:15) [1] 8 > My question: why isn't the environment within the function set to e1, please? Thanks,

[R] Bootstraping GAMs for confidence intervales calculation

2008-07-29 Thread Luis Reino
Dear R-Users, I am resending this message just to reminder my question regarding the calculation of a bootstrap confidence intervals for a GAM plot. I am trying to apply a bootstrap to a GAM in order to calculate the 95% confidence intervals for a smooth curve obtained by the “plot.gam” fun

Re: [R] Negative Binomial Regression

2008-07-29 Thread Ben Bolker
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Prof Brian Ripley wrote: | On Tue, 29 Jul 2008, Ben Bolker wrote: | |> jcarmichael gmail.com> writes: |> |>> |>> |>> Hello. |>> |>> I am attempting to duplicate a negative binomial regression in R. |>> SAS uses |>> generalized estimating equations fo

[R] tensor product of equi-spaced B-splines in the unit square

2008-07-29 Thread Patrizio Frederic
Dear all, I need to compute tensor product of B-spline defined over equi-spaced break-points. I wrote my own program (it works in a 2-dimensional setting) library(splines) # set the break-points Knots = seq(-1,1,length=10) # number of splines M = (length(Knots)-4)^2 # short cut to splineDe

[R] Removing script file

2008-07-29 Thread Dennis Fisher
Colleagues, (Running R 2.7.0) I have a script that I want to delete as it completes execution. The penultimate line of the script (before the quit command) is: file.remove("Scriptname") The script is executed as: R --no-save < Scriptname In OS X and Linux this is successful an

[R] subscript out of bounds help

2008-07-29 Thread Rajasekaramya
(mean.std.s2n.loss.gain[[1]]) Probe.Set.ID rho_prime rho_prime_sd pom Expr1 matchinggenes Meanstd_dev 29 SNP_A-190846347 2.47 0.75 0 PRKCZ -0.345616170.13443676 30 SNP_A-213137044 2.61 0.58 0

[R] lattice question

2008-07-29 Thread Troels Ring
Dear friends - I have a plot of simulated data to compare to the observed and want the simulated to appear accumulated so that a darker grey corresponds to more lines of simulated data, but on top of that I want the measured values (Na) to be very visible. The code below meets only few of the d

[R] subscript out of bounds error.

2008-07-29 Thread Rajasekaramya
(mean.std.s2n.loss.gain[[1]]) Probe.Set.ID rho_prime r ho_prime_sdpom Expr1 matchinggenes Mean std_dev 29 SNP_A-190846347 2.47 0.75 0 PRKCZ - 0.34560. 1344 30 SNP_A-213137044 2.61

Re: [R] Case statements in R

2008-07-29 Thread Roland Rau
Dear all, may I suggest to include this quotation of Patrick Burns in the fortunes package? :-) Best, Roland Patrick Burns wrote: A good reason to use '&&' rather than '&' is if evaluating whatever is on the right will create an error if what is on the left is FALSE. '&&' and '||' stop if

Re: [R] Most often pairs of chars across grouping variable

2008-07-29 Thread Marc Schwartz
on 07/29/2008 09:51 AM [EMAIL PROTECTED] wrote: Hi list, is there a package or function to compute the frequencies of pairs of chars in a variable across a grouping variable? Eg: d <- data.frame(ID=gl(2,3), F=c("A","B","C","A","C","D")) d ID F 1 1 A 2 1 B 3 1 C 4 2 A 5 2 C 6 2 D Now

Re: [R] Negative Binomial Regression

2008-07-29 Thread Prof Brian Ripley
On Tue, 29 Jul 2008, Ben Bolker wrote: jcarmichael gmail.com> writes: Hello. I am attempting to duplicate a negative binomial regression in R. SAS uses generalized estimating equations for model fitting in the GENMOD procedure. proc genmod data=mydata (where=(gender='F')); by agegroup; c

[R] Most often pairs of chars across grouping variable

2008-07-29 Thread svga
Hi list, is there a package or function to compute the frequencies of pairs of chars in a variable across a grouping variable? Eg: d <- data.frame(ID=gl(2,3), F=c("A","B","C","A","C","D")) > d ID F 1 1 A 2 1 B 3 1 C 4 2 A 5 2 C 6 2 D Now I want to summarize the frequencies of all pair

Re: [R] About clustering techniques

2008-07-29 Thread Christian Hennig
A quick comment on this: imputation is an option to make things technically work, but it is not necessarily good. Imputation always introduces some noise, ie, it fakes information that is not really there. Whether it is good depends strongly on the data, the situation and the imputation metho

Re: [R] combining zoo series with an overlapping index?

2008-07-29 Thread Gabor Grothendieck
The code I gave replaces that portion of d that overlaps with lin with lin. Is that not what you wanted? (please try to use minimal examples as shown here) > library(zoo) > d <- zoo(1:10) + 100 > lin <- - head(d, 4) > window(d, time(lin)) <- coredata(lin) > d 1234567

Re: [R] About clustering techniques

2008-07-29 Thread Christian Hennig
Dear Paco, in order to use the methods in the cluster package (including pam), look up the help page of daisy, which is able to compute dissimilarity matrices handling missing values appropriately (in most situations). A good reference is the Kaufman and Rousseeuw book cited on that help page.

Re: [R] About clustering techniques

2008-07-29 Thread ctu
Hi Paco, I got the same problem with you before. Thus, I just impute the missing values For example: newdata<-as.matrix(impute(olddata, fun="random")) then I believe that you could analyze your data. Hopefully it helps. Chunhao Quoting pacomet <[EMAIL PROTECTED]>: Hello R users It's some ti

Re: [R] Coarsening the Resolution of a Dataset

2008-07-29 Thread Steve Murray
Unfortunately, when I get to the 'myCuts' line, I receive the following error: Error: evaluation nested too deeply: infinite recursion / options(expressions=)? ...and I also receive warnings about memory allocation being reached (even though I've already used memory.limit() to maximise the memo

[R] About clustering techniques

2008-07-29 Thread pacomet
Hello R users It's some time I am playing with a dataset to do some cluster analysis. The data set consists of 14 columns being geographical coordinates and monthly temperatures in annual files latitutde - longitude - temperature 1 -. - temperature 12 I have some missing values in some cases

[R] Howto Draw Bimodal Gamma Curve with User Supplied Parameters

2008-07-29 Thread Gundala Viswanath
Hi, Suppose I have the following vector (data points): > x [1] 36.0 57.3 73.3 92.0 300.4 80.9 19.8 31.4 85.8 44.9 24.6 48.0 [13] 28.0 38.3 85.2 103.6 154.4 128.5 38.3 72.4 122.7 123.1 41.8 21.7 [25] 143.6 120.2 46.6 29.2 44.8 25.0 57.3 96.4 29.4 62.9 66.4 30.0 [37]

Re: [R] writing the plots

2008-07-29 Thread John Kane
?png ?write.table --- On Mon, 7/28/08, Rajasekaramya <[EMAIL PROTECTED]> wrote: > From: Rajasekaramya <[EMAIL PROTECTED]> > Subject: [R] writing the plots > To: r-help@r-project.org > Received: Monday, July 28, 2008, 10:54 AM > hi there, > > I want to write the plots in the pdfs and the detail

Re: [R] combining zoo series with an overlapping index?

2008-07-29 Thread stephen sefick
when I plot this it gives me the coredata(lin) (Ithink). I would like d<- c(day[1:17,], lin, day[84:96,]) to be the result On Tue, Jul 29, 2008 at 9:18 AM, Gabor Grothendieck <[EMAIL PROTECTED] > wrote: > Try: > > window(d, time(lin)) <- coredata(lin) > > On Tue, Jul 29, 2008 at 9:01 AM, stephe

Re: [R] Panel of pie charts

2008-07-29 Thread John Kane
Have a look at mfcol in ?par. --- On Tue, 7/29/08, Amin Momin <[EMAIL PROTECTED]> wrote: > From: Amin Momin <[EMAIL PROTECTED]> > Subject: [R] Panel of pie charts > To: r-help@r-project.org > Received: Tuesday, July 29, 2008, 7:34 AM > Hi , > I am looking to making a panel of pie charts fo som

Re: [R] combining zoo series with an overlapping index?

2008-07-29 Thread Gabor Grothendieck
Try: window(d, time(lin)) <- coredata(lin) On Tue, Jul 29, 2008 at 9:01 AM, stephen sefick <[EMAIL PROTECTED]> wrote: > day<-structure(c(7.7, 7.7, 7.7, 7.7, 7.7, 7.71, 7.7, 7.71, 7.71, 7.7, > 7.7, 7.7, 7.7, 7.69, 7.68, 7.68, 7.67, 7.67, 7.67, 7.66, 7.65, > 7.65, 7.65, 7.64, 7.64, 7.63, 7.63, 7.63

Re: [R] keywords

2008-07-29 Thread Charilaos Skiadas
On Jul 29, 2008, at 5:24 AM, Edna Bell wrote: Hi R Gurus! When you build a package, you need to put in keywords in the Rd files. Where would you find the list of keywords, please? Simplest way is to google for "r keywords". First hit is: http://www.stat.ucl.ac.be/ISdidactique/Rhelp/doc/keyw

[R] combining zoo series with an overlapping index?

2008-07-29 Thread stephen sefick
day<-structure(c(7.7, 7.7, 7.7, 7.7, 7.7, 7.71, 7.7, 7.71, 7.71, 7.7, 7.7, 7.7, 7.7, 7.69, 7.68, 7.68, 7.67, 7.67, 7.67, 7.66, 7.65, 7.65, 7.65, 7.64, 7.64, 7.63, 7.63, 7.63, 7.62, 7.62, 7.62, 7.62, 7.63, 7.63, 7.63, 7.63, 7.63, 7.64, 7.64, 7.65, 7.65, 7.65, 7.66, 7.66, 7.67, 7.67, 7.67, 7.68, 7.68

Re: [R] How to set the parameters in Trellis Graphics (by Lattice package)

2008-07-29 Thread Felix Andrews
On Tue, Jul 29, 2008 at 5:37 PM, G.H. Zuo <[EMAIL PROTECTED]> wrote: > Dear R users > > I plot the trellis graphics by using the lattice package. Everything is > OK. Now, I want set > some parameters of the trellis graphics. > > 1. The tick label site. By default, only two tick labels had been o

Re: [R] Negative Binomial Regression

2008-07-29 Thread Ben Bolker
jcarmichael gmail.com> writes: > > > Hello. > > I am attempting to duplicate a negative binomial regression in R. SAS uses > generalized estimating equations for model fitting in the GENMOD procedure. > > proc genmod data=mydata (where=(gender='F')); > by agegroup; > class id gender type; >

  1   2   >