Re: [R] RSiteSearch for words ``as one entity''.

2008-09-10 Thread Prof Brian Ripley
If firefox is involved on a Mac, that is one difference. My Mac is using 'open' (the default, I believe) and that is calling Safari (the default, I believe). Yes, it would be the job of browseURL to encode URLs where required. But at least on Windows and using the -remoteURL mechanism (as on

Re: [R] Two way clustering

2008-09-10 Thread Tobias Verbeke
Hi, I am trying to do two-way clustering (using information of both observation and variables). Is there any package available in R. There is a package for biclustering in development on R-Forge http://r-forge.r-project.org/projects/biclust/ Slides from a recent presentation of the package a

Re: [R] binomial(link="inverse")

2008-09-10 Thread Prof Brian Ripley
On Wed, 10 Sep 2008, Thomas Lumley wrote: On Wed, 10 Sep 2008, Prof Brian Ripley wrote: As to why the list of links known by name is as it is, that seems history. in part the White Book history of S. I've always thought it an error that 'log' was a standard link for binomial, as the range d

Re: [R] All possible pairs of two variables

2008-09-10 Thread Yihui Xie
Just simple loops as follows: z = NULL for (y in 0:10) { for (x in 0:y) { z = rbind(z, c(x, y)) } } z Yihui On Thu, Sep 11, 2008 at 12:34 PM, Ron Michael <[EMAIL PROTECTED]> wrote: > I have two variables (x,y) : > > x : it takes a

Re: [R] using R for online course/distance ed

2008-09-10 Thread Yihui Xie
Hi Erin, I'm not a teacher, and I don't have any experience in teaching, but I have been working on the demonstration of statistical ideas via animations (I think they will effectively prevent students from sleeping in class ^o^). I hope this would be of some help to you: http://animation.yihui.na

Re: [R] periodicity validation

2008-09-10 Thread yk
The data I mentioned above is oscilating vs time,but there are not obersevable fixed cycle if I just plot this data. How to get the average cycle,or the most probable range of cycle with statistical methods? I don't know how to achieve it by R, is there any command? On Sep 11, 10:52 am, "stephen

[R] All possible pairs of two variables

2008-09-10 Thread Ron Michael
I have two variables (x,y) : x : it takes all integer values from 0 to y and, y : takes all values from 0, 10 I am looking for some R code to find all possible pairs of (x,y). Can anyone please help me? New Email addresses available on Yahoo! Get the Email name you've always wanted on t

Re: [R] arima and xreg

2008-09-10 Thread David Stoffer
Your model is close, but not correct... there are no t's on the parameters and the U's aren't lagged. You can find an ARMAX example on our "quick fix" page: http://www.stat.pitt.edu/stoffer/tsa2/R_time_series_quick_fix.htm . The example is near the bottom and just above the spectral analysis e

[R] Loop for the convergence of shape parameter

2008-09-10 Thread sandsky
Hello, The likelihood includes two parameters to be estimated: lambda (=beta0+beta1*x) and alpha. The algorithm for the estimation is as following: 1) with alpha=0, estimate lambda (estimate beta0 and beta1 via GLM) 2) with lambda, estimate alpha via ML estimation 3) with updataed alpha, replica

Re: [R] extract variance components

2008-09-10 Thread huang min
See the error message. Thanks. a.fit<-lme(distance~age, data=aaa, random=~day/subject) getVarCov(a.fit) Error in getVarCov.lme(a.fit) : Not implemented for multiple levels of nesting On Wed, Sep 10, 2008 at 9:53 PM, Lyman, Mark <[EMAIL PROTECTED]> wrote: > Take a look again at help(getVarCov

Re: [R] using R for online course/distance ed

2008-09-10 Thread stephen sefick
I have taught myself R with undue suffering by this list over the last year, and I see no reason why distance education wouldn't work. The learning curve will be a little shallower than mine with a guide. I would suggest using the Rcmdr to jump start everything because you can see the code that g

Re: [R] periodicity validation

2008-09-10 Thread stephen sefick
?spectrum ?acf ?ccf library(wmtsa) ?wavCWT library(sowas) ?wsp you could also look at lagged plots to look for periodicity. if you elaborate on the problem and include executable sample code you will probably recieve more help. On Wed, Sep 10, 2008 at 10:02 PM, yk <[EMAIL PROTECTED]> wrote: > The

Re: [R] using R for online course/distance ed

2008-09-10 Thread cryan
Well, I can speak from the "receiving end." I'm enrolled in an online distance masters degree in statistics at Texas A&M University. I'm in my fourth course. We are pretty much free to use any statistical software we want. The first semester (distributions, goodness of fit, one- and two- sam

[R] periodicity validation

2008-09-10 Thread yk
There is a series of data contains time in fixed step and energy varying with time, how to test its periodicity?In R, it seems there is no direct tools since I have search the R manual with periodic and I have not found any related topic. Thanks a lot __

Re: [R] mixed model MANCOVA

2008-09-10 Thread John Fox
Dear Erika et al., I'm not sure exactly what you want to do, but you might take a look at the Anova() function in the car package, which will compute "type-II" or "type-III" tests for multivariate linear models, including models with repeated measures; you can also get the traditional univariate t

Re: [R] Woring message in as.yearmon()

2008-09-10 Thread Andy Zhu
Try this modification: as.yearmon(paste(res[,1], res[,2], sep="-"),format="%Y-%m")Andy --- On Wed, 9/10/08, Megh Dal <[EMAIL PROTECTED]> wrote: From: Megh Dal <[EMAIL PROTECTED]> Subject: [R] Woring message in as.yearmon() To: [EMAIL PROTECTED] Date: Wednesday, September 10, 2008, 2:15 PM I have

Re: [R] help: error handling in try

2008-09-10 Thread jim holtman
It does not "stop" the program. It generates an "error" message which is caught by 'try' from which you can do a recovery. The purpose of 'stop' is to cause the 'try' to catch it and return the error message as the result and you can test the class for being 'try-error'. On Wed, Sep 10, 2008 at

[R] Convex optimization in R?

2008-09-10 Thread Hesen Peng
Hi my R buddies, I'm trying to solve a specific group of convex optimization in R. The admissible region is the inside and surface of a multi-dimensional eclipse area and the goal function is the sum of absolution values of the variables. Could any one please tell me whether there's a package in R

Re: [R] help: error handling in try

2008-09-10 Thread Andy Zhu
Thanks, Jim: One of the purpose of this function is to try not to stop the program and generate T/F result for further process. Actually find fix by myself with tryCatch (but don't know why try doesn't work). The modified function handles potential Date and yearmon in Zoo classes. is.Date= # a

Re: [R] bootstrapping - number of items to replace is not a multiple of replacement length

2008-09-10 Thread Gabriela Bucini
HI Steve, I've checked the random forest package. The VariableImportance does exactly what I need. Thank you so much! Gabriela > -Original Message- > From: Steven McKinney [mailto:[EMAIL PROTECTED] > Sent: Tuesday, September 09, 2008 8:48 PM > To: Gabriela Bucini; r-help@r-project.org >

Re: [R] mixed model MANCOVA

2008-09-10 Thread hadley wickham
On Mon, Sep 8, 2008 at 1:06 PM, Erika Crispo <[EMAIL PROTECTED]> wrote: > Hello, > > I need to perform a mixed-model (with nesting) MANCOVA, using Type III sums > of squares. I know how to perform each of these types of tests individually, > but I am not sure if performing a mixed-model MANCOVA i

Re: [R] making spearman correlation cor() call fail with log(0) as input

2008-09-10 Thread Greg Snow
Your code shows no errors only correct responses. If you want an error when R is generating correct results, you will need to check for the conditions yourself. -Original Message- From: "Timur Shtatland" <[EMAIL PROTECTED]> To: "r-help@r-project.org" Sent: 9/10/08 3:51 PM Subject: [R] m

Re: [R] mixed model MANCOVA

2008-09-10 Thread Adam D. I. Kramer
Hi Erika, As mentioned, I haven't run the model before and I don't have access to your data set, so you might want to post your reply to the list as well (cc'd again). As another guessing-without-trying-anything, I'd first make sure that in fact pop and family are factor variable

Re: [R] re flecting a line

2008-09-10 Thread Nordlund, Dan (DSHS/RDA)
> -Original Message- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] On Behalf Of Gabor Grothendieck > Sent: Wednesday, September 10, 2008 3:45 PM > To: David Epstein > Cc: r-help@r-project.org > Subject: Re: [R] re flecting a line > > Try this: > >lines(fitted(lm(x ~ y)), y, l

Re: [R] RSiteSearch for words ``as one entity''.

2008-09-10 Thread Rolf Turner
On 11/09/2008, at 10:09 AM, Marc Schwartz wrote: As Prof. Ripley noted, try using debug(RSiteSearch) and then step through the code to see where $HOME is being added to the URL variable. That can help pin it down further. If the URL is not corrupted by the time browseURL() is calle

Re: [R] re flecting a line

2008-09-10 Thread Gabor Grothendieck
Try this: lines(fitted(lm(x ~ y)), y, lty = 2) On Wed, Sep 10, 2008 at 4:06 PM, David Epstein <[EMAIL PROTECTED]> wrote: > > Suppose x and y are numeric vectors of the same length. > > plot(x,y) #scatterplot > lmObj1 <- lm(y~x) # best fit line > abline(lmObj1) # good > lmObj2 <- lm(x~y) #get

Re: [R] comparing a list and vector and returnig the listname

2008-09-10 Thread Adam D. I. Kramer
Maybe, for vector v and list l match(v,names(l)) ? --Adam On Wed, 10 Sep 2008, Rajasekaramya wrote: hi, I have list of length 5453 and vector of length 14318.I need to compare the vector with the list and return the list name if matched.I am thinking of using an lapply but how to retrive t

Re: [R] making spearman correlation cor() call fail with log(0) as input

2008-09-10 Thread Timur Shtatland
Hi Miltinho, Thank you for the reply. I know that this is one way to stop cor(log()...) from failing. However, my question was exactly the opposite: how to *make* it fail. cor() silently succeeds and even returns a value even when the input to it fails on its own (e.g., log(0) fails). Note that

Re: [R] request: most repeated component of a list

2008-09-10 Thread Adam D. I. Kramer
You might try apply(t(sapply(l,apply,2,sum)),2,sum) --Adam On Wed, 10 Sep 2008, Muhammad Azam wrote: Dear R community I have stored the results of arrays in a list consist of J-components (say 200 components). Each component containing same no of columns but may be different no of rows. e.

[R] using R for online course/distance ed

2008-09-10 Thread Erin Hodgess
Hi R People! I'm going to be putting together a completely online undergrad business stats course (a second semester course) and was going to use R and Rcmdr. My question: has anyone else used R for an online course, please? If so, did it go well, please? Thanks in advance, Sincerely, Erin -

[R] Trouble compiling R with self-compiled LAPACK/ATLAS under Linux

2008-09-10 Thread Adam D. I. Kramer
Hello, I just had a lot of trouble compiling a version of R which uses a recently-compiled version of ATLAS and LAPACK. ATLAS and LAPACK compiled correctly and installed fine and passed all of their checks (and yes, I did compile them all with -fPIC as is required for R). This was my init

Re: [R] RSiteSearch for words ``as one entity''.

2008-09-10 Thread Henrik Bengtsson
On Wed, Sep 10, 2008 at 3:09 PM, Marc Schwartz <[EMAIL PROTECTED]> wrote: > on 09/10/2008 04:49 PM Rolf Turner wrote: >> >> On 11/09/2008, at 9:29 AM, Marc Schwartz wrote: >> >>> on 09/10/2008 04:03 PM Rolf Turner wrote: I tried to search for a string of words ``as one entity'' following

[R] using portfolioMarkowitz

2008-09-10 Thread Chiquoine, Ben
Hi, I'm pretty new to R and I'm trying to use the functions portfolioMarkowitz and portfolioMonteCarlo. I think that its in the package fPortfolio but it doesn't seem to work with I install the package and import the library. I think this may be because It only existed in an old version of th

Re: [R] making spearman correlation cor() call fail with log(0) as input

2008-09-10 Thread milton ruser
Hi Timur, try cor(log(a+1), log(b+1), method="pearson") HTH, miltinho brazil On Wed, Sep 10, 2008 at 6:04 PM, Timur Shtatland <[EMAIL PROTECTED]>wrote: > Hi, > > How can I make the cor(x, y, method="spearman") call to produce an > error when the input to it (x, y) produces an error? Here is a

Re: [R] RSiteSearch for words ``as one entity''.

2008-09-10 Thread Marc Schwartz
on 09/10/2008 04:49 PM Rolf Turner wrote: > > On 11/09/2008, at 9:29 AM, Marc Schwartz wrote: > >> on 09/10/2008 04:03 PM Rolf Turner wrote: >>> >>> I tried to search for a string of words ``as one entity'' following the >>> example in the help file: >>> RSiteSearch("{logistic regression}")

Re: [R] binomial(link="inverse")

2008-09-10 Thread Lucke, Joseph F
Isn't the binomial-log used to obtain risk ratios from the coefficients rather than odds-ratios? -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Thomas Lumley Sent: Wednesday, September 10, 2008 4:36 PM To: Prof Brian Ripley Cc: r-help@r-project.org; Ben

[R] [R-pkgs] STAR (Spike Train Analysis with R) uploaded on CRAN

2008-09-10 Thread Christophe Pouzat
Hi all, I've uploaded STAR (Spike Train Analysis with R) on CRAN two days ago. The package is designed to analyze neuronal spike (action potential) trains. It uses S3 classes and methods and makes heavy use of other CRAN packages like gss, R2HTML, mgcv, survival. * Analysis of both spontaneous a

Re: [R] binomial(link="inverse")

2008-09-10 Thread Ben Bolker
Thomas Lumley wrote: > As a side note, in (some versions of) S, due to partial matching, > binomial("log") is valid -- it just does logistic regression. > ouch! signature.asc Description: OpenPGP digital signature __ R-help@r-project.org mailing l

[R] making spearman correlation cor() call fail with log(0) as input

2008-09-10 Thread Timur Shtatland
Hi, How can I make the cor(x, y, method="spearman") call to produce an error when the input to it (x, y) produces an error? Here is a simple example: > a <- c(0, 1, 2) > b <- c(100, 2, 4) ## error: > log(a) [1] -Inf 0.000 0.6931472 ## error, as expected: > cor(log(a), log(b), method="p

Re: [R] RSiteSearch for words ``as one entity''.

2008-09-10 Thread Rolf Turner
On 11/09/2008, at 9:29 AM, Marc Schwartz wrote: on 09/10/2008 04:03 PM Rolf Turner wrote: I tried to search for a string of words ``as one entity'' following the example in the help file: RSiteSearch("{logistic regression}") and got the error message: 2008-09-11 08:55:41.356 open[823]

Re: [R] mixed model MANCOVA

2008-09-10 Thread Adam D. I. Kramer
Hi Erika, I have not tried this before, and I hope that somebody will correct me if I'm wrong, but the glmer function in the lme4 library appears to do what you want. From examples(lmer): lmer> (gm1 <- glmer(cbind(incidence, size - incidence) ~ period + (1 | herd), family = binomial, dat

Re: [R] binomial(link="inverse")

2008-09-10 Thread Thomas Lumley
On Wed, 10 Sep 2008, Prof Brian Ripley wrote: As to why the list of links known by name is as it is, that seems history. in part the White Book history of S. I've always thought it an error that 'log' was a standard link for binomial, as the range does not match the specification of probabil

Re: [R] RSiteSearch for words ``as one entity''.

2008-09-10 Thread Prof Brian Ripley
On Wed, 10 Sep 2008, Henrik Bengtsson wrote: Seems that one of the slashed is dropped after the protocol prefix, i.e. http:/search.r-project.org/... should be http://search.r-project.org/... Someone else has to take it from here. /Henrik On Wed, Sep 10, 2008 at 2:03 PM, Rolf Turner <[EMAIL

Re: [R] re flecting a line

2008-09-10 Thread Nordlund, Dan (DSHS/RDA)
> -Original Message- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] On Behalf Of David Epstein > Sent: Wednesday, September 10, 2008 1:06 PM > To: r-help@r-project.org > Subject: [R] re flecting a line > > > Suppose x and y are numeric vectors of the same length. > > plot(x,y) #s

Re: [R] RSiteSearch for words ``as one entity''.

2008-09-10 Thread Marc Schwartz
on 09/10/2008 04:03 PM Rolf Turner wrote: > > I tried to search for a string of words ``as one entity'' following the > example in the help file: > >> RSiteSearch("{logistic regression}") > > and got the error message: > > 2008-09-11 08:55:41.356 open[823] No such file: > /Users/rturner/http:/s

Re: [R] RSiteSearch for words ``as one entity''.

2008-09-10 Thread Henrik Bengtsson
Seems that one of the slashed is dropped after the protocol prefix, i.e. http:/search.r-project.org/... should be http://search.r-project.org/... Someone else has to take it from here. /Henrik On Wed, Sep 10, 2008 at 2:03 PM, Rolf Turner <[EMAIL PROTECTED]> wrote: > > I tried to search for a s

[R] Two way clustering

2008-09-10 Thread ram basnet
Hi R users,   I am trying to do two-way clustering (using information of both observation and variables). Is there any package available in R. Another querry, if somebody can provide related information (website) regarding this statistics, it will be great. Thanks in advance.   Regards,   Ram Ku

[R] RSiteSearch for words ``as one entity''.

2008-09-10 Thread Rolf Turner
I tried to search for a string of words ``as one entity'' following the example in the help file: > RSiteSearch("{logistic regression}") and got the error message: 2008-09-11 08:55:41.356 open[823] No such file: /Users/rturner/http:/ search.r-project.org/cgi-bin/namazu.cgi?query={logistic+reg

Re: [R] re flecting a line

2008-09-10 Thread milton ruser
Hi David, I don´t know if I got what you are looking for. But see the code below. x<-1:100 y<-x+(runif(100)*x) plot(y~x) mymod<-glm(y~x) my.coefs<-coef(mymod) my.coefs curve(my.coefs[1]+my.coefs[2]*x, lwd=2, col="red", add=T) Cheers, mitinho astronauta brazil On Wed, Sep 10, 2008 at 6:06 PM,

[R] re flecting a line

2008-09-10 Thread David Epstein
Suppose x and y are numeric vectors of the same length. plot(x,y) #scatterplot lmObj1 <- lm(y~x) # best fit line abline(lmObj1) # good lmObj2 <- lm(x~y) #get best fit but with axes interchanged abline(lmObj2) # not what I want. I want the correct line, drawn on the same graph, but with

[R] How to install rpy under mac os x?

2008-09-10 Thread mando
Hi to all, there are some binary .dmg packages to install easly rpy under mac os x? I'm tryin' to install Rpy under Mac Os X but I receive the following message: host46-209-dynamic:rpy usernone$ python setup.py install running install running build running build_py running build_ext buildi

[R] trouble printing from graphics device in R 2.7.2

2008-09-10 Thread Jenny Drnevich
Hi, I've been using R for many years and have always tried to keep my R version up to date, and when I switched from 2.7.1 to 2.7.2 I'm suddenly having trouble printing from the graphics device. I have Windows XP, and installed both versions of R from the binaries. If I start 2.7.2 and simply

Re: [R] Mixed effects model with binomial errors - problem

2008-09-10 Thread Ben Bolker
RFTW nioo.knaw.nl> writes: > > > ok, the model does run now! > > but, dont i need the method="ML" when i want to compare this model with a > reduced model using anova(model1, model2)? The R-Book tells me that REML is > not good for that (p.635) maximum likelihood ("ML") is the default [an

Re: [R] WG: Re: NMDS and varimax rotation

2008-09-10 Thread Gavin Simpson
On Wed, 2008-09-10 at 14:24 +0200, Bernd Panassiti wrote: > hello, > thanks a lot for your help. > > @ Stephen: In my opinion the proscrutes rotation is more used to > compare the > alignment of different ordination methods. But maybe I'm wrong. > > @ Bill: Thanks for the comprehensive descript

Re: [R] Color coding plotted numbers

2008-09-10 Thread Wade Wall
Hi all, I realized what I was doing wrong and aplogize about posting before thinkg about it for long enough. If I try to plot the pca results directly (bulbil.pca), I can't do it. But if I extract the axes 1 and 2 and plot directly, I can add col=as.numeric(group.bulbil[,3]) to the text() functi

Re: [R] Woring message in as.yearmon()

2008-09-10 Thread Gabor Grothendieck
I can't reproduce that. When I run it I get no warning. Check your versions: > Lines <- "19464 1.27 + 19465 1.27 + 19466 1.27 + 19467 1.27 + 19468 1.52 + 19469 1.52 + 1946 10 1.52 + 1946 11 1.52 + 1946 12 1.62 + 19471 1.62 + 19472 1.62 + 19473

Re: [R] xls to csv conversion via WinXP's context menu?

2008-09-10 Thread Gabor Grothendieck
The main difference is that read.xls and xls2csv in the gdata package use a perl program which works on all platforms whereas the others require Windows but may have advantages there. On Wed, Sep 10, 2008 at 1:40 PM, Erich Neuwirth <[EMAIL PROTECTED]> wrote: > There are at least 2 more packages wh

[R] Woring message in as.yearmon()

2008-09-10 Thread Megh Dal
I have following dataset: > res [,1] [,2] [,3] [1,] 19464 1.27 [2,] 19465 1.27 [3,] 19466 1.27 [4,] 19467 1.27 [5,] 19468 1.52 [6,] 19469 1.52 [7,] 1946 10 1.52 [8,] 1946 11 1.52 [9,] 1946 12 1.62 [10,] 19471 1.62 [11,] 19472 1.62 [12,] 1947

Re: [R] : writeMat

2008-09-10 Thread Henrik Bengtsson
Hi, I've managed to reproduce the error with R.matlab v1.2.2 and Matlab v7.4.0.287 (R2007a). There seems to be a bug introduced in R.matlab v1.2.2 (2008-07-12). In this version we tried to optimize the speed of writeMat(), and something failed (although all tests show the generated files loads fi

Re: [R] setting history file

2008-09-10 Thread Edna Bell
I am using R-2.7.2 on Windows XP. Sorry for the problems. Sincerely, Edna On Wed, Sep 10, 2008 at 11:54 AM, Prof Brian Ripley <[EMAIL PROTECTED]> wrote: > On Wed, 10 Sep 2008, Edna Bell wrote: > >> Dear R Gurus: >> >> I would like to set the number of commands in the history file as 50 >> rathe

Re: [R] xls to csv conversion via WinXP's context menu?

2008-09-10 Thread Erich Neuwirth
There are at least 2 more packages which can handle the conversion. xlsReadWrite (only available on Windows) allows you to read Excel files directly in R. At the moment xls, but not xlsx and xlsm, AFAIK. RExcel (available via RExcelInstaller on CRAN) is an Excel addin which allows you to transfe

Re: [R] many correlations

2008-09-10 Thread William Revelle
Stephen and Jorge, Perhaps a simpler solution is to use the which function test.data <- Harman74.cor$cov#a test data set td <- test.data * lower.tri(test.data) #this will examine only the lower off diagonal elements td.1 <- which(abs(td)>.6,arr.ind=TRUE) # the critical pairs td.2 <- td

[R] Color coding plotted numbers

2008-09-10 Thread Wade Wall
Hi all, I have run a pca and want to plot the samples multivariate space using the sample numbers. In addition, I would like to color code the sample numbers by group, but can't find a way to color-code the sample numbers by group. So, I have to do it in two separate steps: plot(bulbil.pca, col

Re: [R] setting history file

2008-09-10 Thread Prof Brian Ripley
On Wed, 10 Sep 2008, Edna Bell wrote: Dear R Gurus: I would like to set the number of commands in the history file as 50 rather than 25. It is neither of those. That is the default value of max.show, not of the size of the file. I would do this in the .First function. How do I set this,

Re: [R] : writeMat

2008-09-10 Thread erola pairo
Hi, that's the information about R and R.matlab: *R version 2.6.2 (2008-02-08) x86_64-pc-linux-gnu locale: C attached base packages: [1] stats graphics grDevices utils datasets methods base other attached packages: [1] R.matlab_1.2.3R.oo_1.4.5R.methodsS3_1.0.3 MASS_7.2-

Re: [R] Mode value

2008-09-10 Thread Greg Snow
Others showed you how to find the mode in a dataset, I just want to point out that if your data is from a continuous distribution (or near continuous), then the mode of the data is more likely to be the result of a quirk of rounding than representative of anything useful. If the data is discret

Re: [R] comparing a list and vector and returnig the listname

2008-09-10 Thread Henrique Dallazuanna
If I understand, try this: names(l[l %in% v]) where l is your list and v is your vector. On Wed, Sep 10, 2008 at 1:38 PM, Rajasekaramya <[EMAIL PROTECTED]>wrote: > > hi, > > I have list of length 5453 and vector of length 14318.I need to compare the > vector with the list and return the list na

[R] setting history file

2008-09-10 Thread Edna Bell
Dear R Gurus: I would like to set the number of commands in the history file as 50 rather than 25. I would do this in the .First function. How do I set this, please? I tried history(max=50) and it prints what it has. I just want to set the size in .First. Thanks in advance, Sincerely, Edna __

[R] comparing a list and vector and returnig the listname

2008-09-10 Thread Rajasekaramya
hi, I have list of length 5453 and vector of length 14318.I need to compare the vector with the list and return the list name if matched.I am thinking of using an lapply but how to retrive the listname is wat i am puzzled abt. kindly let me know how to go abt it. Ramya -- View this message in c

[R] MA coefficients

2008-09-10 Thread richard fann
Hi everyone, I am performing the time series regression analysis on a series of data sets. A few data sets followed an ARMA(1,1) process. However, they all had a same value of moving average MA coefficients = -1, constantly, from output of function “arima" . Example: > arima(residuals, order=c(1

Re: [R] printing all rows

2008-09-10 Thread Greg Snow
Are you really going to look at all the rows? Probably better options for what you want are to look at functions like 'head', 'tail', 'subset', and 'View' that will let you look at specific parts of the data rather than printing out much more information than you are likely to care about, then

[R] FW: RE: arima and xreg

2008-09-10 Thread markleeds
hi: you should probably send below to R-Sig-Finance because there are some econometrics people over there who could also possibly give you a good answer and may not see this email ? Also, there's package called mar ( I think that's the name ) that may do what you want ? Finally, I don't k

Re: [R] test for a single variance

2008-09-10 Thread Greg Snow
If you are trying to test the hypotheses: H0: sigma^2 == sigma[0]^2 Ha: sigma^2 != sigma[0]^2 i.e. is the variance of the distribution from which the data came different from the hypothesized value? Then the normal theory test can be done fairly simply (I don't know of any prepackaged equivale

Re: [R] loop with splitted data

2008-09-10 Thread Ling, Gary (Electronic Trading)
YES! many many thanks, Jim. I know it'd be simple, yet I can't believe it's that simple. =) -gary -Original Message- From: jim holtman [mailto:[EMAIL PROTECTED] Sent: Wednesday, September 10, 2008 11:55 AM To: Ling, Gary (Electronic Trading) Cc: Peter Dalgaard; r-help@r-project.org Subje

Re: [R] request: most repeated component of a list

2008-09-10 Thread jim holtman
If want you want is the summary from all of them, then 'rbind' the data together into one matrix and analyze it: totalMat <- do.call(rbind, listOfMatrices) On Wed, Sep 10, 2008 at 11:49 AM, Muhammad Azam <[EMAIL PROTECTED]> wrote: > Dear R community > I have stored the results of arrays in a list

Re: [R] loop with splitted data

2008-09-10 Thread jim holtman
Is this what you want: > lapply(z, '[[', 1) [[1]] [1] 1 2 3 [[2]] [1] 11 12 13 > lapply(z, '[[', 2) [[1]] [1] 4 5 6 [[2]] [1] 14 15 16 > On Wed, Sep 10, 2008 at 11:43 AM, Ling, Gary (Electronic Trading) <[EMAIL PROTECTED]> wrote: > Hi R users, I have a question which is some what related to

[R] request: most repeated component of a list

2008-09-10 Thread Muhammad Azam
Dear R community I have stored the results of arrays in a list consist of J-components (say 200 components). Each component containing same no of columns but may be different no of rows. e.g [[1]] [,1] [,2] [,3] [,4] [,5] [1,]40000 [2,]43400 [3,

Re: [R] Binning

2008-09-10 Thread Felipe Carrillo
Thanks Jim and S Ellison for your help > This should do what you want. > > #--x <- read.table('clipboard', header=TRUE, > as.is=TRUE) > # convert dates > x$date <- as.POSIXct(strptime(x$SampleDate, > "%m/%d/%Y")) > # put ForkLength into bins > x$bins <- cut(x$ForkLength, breaks=c(32, 34, 37, 40),

Re: [R] loop with splitted data

2008-09-10 Thread Ling, Gary (Electronic Trading)
Hi R users, I have a question which is some what related to this thread. Here is the setup: z is a list of lists, with no names. zz is same is z, but with names. with names on zz, I can crawl on the data with lapply, but I don't know how do the same on z (without names). Can someone help? ###

Re: [R] Problem with dir.create in windows servers

2008-09-10 Thread Henrik Bengtsson
This sounds vaguely familiar to me. This could be reason for why I wrote mkdirs() of the R.utils package. mkdirs() does it's own (manual) recursive creation of directories. See if that does it for you. /Henrik On Wed, Sep 3, 2008 at 1:14 AM, Francisco Jose Sastre <[EMAIL PROTECTED]> wrote: > He

Re: [R] cluster/snow question

2008-09-10 Thread tolga . i . uzuner
Many thanks, that is very helpful. Tolga Luke Tierney <[EMAIL PROTECTED]> 10/09/2008 14:05 To [EMAIL PROTECTED] cc [EMAIL PROTECTED], r-help@r-project.org Subject Re: [R] cluster/snow question ls() looks in its calling environment, which in this case would be the internals of the snow me

Re: [R] ggplot2: edge outlines on points

2008-09-10 Thread hadley wickham
Hi Adam, The next version of ggplot2 supports the build-in R plotting symbols that have different fills and borders, so you can do something like: geom_point(aes(colour=TRT), fill="red", colour="black", shape=21) Otherwise in the current version you can do: ggplot(data.frame(x = runif(20), y =

Re: [R] naive variance in GEE

2008-09-10 Thread Qiong Yang
Thanks Thomas. Here is a further question I asked and the answer from Prof Ripley. This agrees with your previous response. Is it true that the same algorithm was used in calculation of GLM S.E. and GEE naive S.E., and the only difference is the stopping criteria? Professor Ripley: No, but it

[R] arima and xreg

2008-09-10 Thread Jose Capco
Dear R-help-archive.. I am trying to figure out how to make arima prediction when I have a process involving multivariate time series input, and one output time series (output is to be predicted) .. (thus strictly speaking its an ARMAX process). I know that the arima function of R was not designe

Re: [R] binomial(link="inverse")

2008-09-10 Thread Ben Bolker
Prof Brian Ripley wrote: > This isn't accurate. You are talking about link functions *known by name*. > > link: a specification for the model link function. This can be a > name/expression, a literal character string, a length-one > character vector or an object of class

[R] using function instead of formula in plm

2008-09-10 Thread sentimental . gentleman
Hi all, I am trying to use plm to estimate coefficients in a model consisting of a system of equations. So far I used mle2 from the package "bbmle", but now I need to test for autocorrelation and mle2 does not provide for the necessary tests. mle2 needs a function as input that might as well co

[R] ggplot2: edge outlines on points

2008-09-10 Thread Adam Marsh
The graphic design elements in ggplot2 are so well done for color graphics. Thank you! For BW publication graphs, there are a few options I would like to be able to tweak, but can't seem to find the grob handles necessary OR the right plotting strategy. Here's one problem I've been puzzling

Re: [R] Package installation in Windows - Urgent!

2008-09-10 Thread boxyzzy
Thanks for your response. However, I need more guidance. 1) I searched the archives of this list back to June 1. I found no discussion on this subject as I examined all the subject titles for the string [Ww]in. 2) I tried (what I understand) to be you suggestion. I created etc/Renviron.site: R_

Re: [R] Return dimension index from array with n-dimensions

2008-09-10 Thread jim holtman
Is this what you were looking for: > a <- array(100:1,dim=c(5,4,5)) > which(a == 7) [1] 94 > which(a == 7, arr.ind=TRUE) dim1 dim2 dim3 [1,]435 > On Wed, Sep 10, 2008 at 10:22 AM, Hintzen, Niels <[EMAIL PROTECTED]> wrote: > Hi, > > I have been dealing with some problems finding

[R] Return dimension index from array with n-dimensions

2008-09-10 Thread Hintzen, Niels
Hi, I have been dealing with some problems finding a fast way of getting to know in what dimension a specific value is located out of an array (like the 'which' function for a vector returns its position). Unable to find anything about this on the internet I wrote a function myself. Could you p

Re: [R] Mixed effects model with binomial errors - problem

2008-09-10 Thread RFTW
ok, the model does run now! but, dont i need the method="ML" when i want to compare this model with a reduced model using anova(model1, model2)? The R-Book tells me that REML is not good for that (p.635) So, besides that... how do i now do a sort of posthoc test to see 1) estimates of all trea

Re: [R] A question about the hypergeometric distribution and phyper()

2008-09-10 Thread Stefan Evert
On 10 Sep 2008, at 15:19, michael watson (IAH-C) wrote: Example 1: I have a universe of 6187 objects, and 164 have a particular attribute, therefore 6187-164 do not have that attribute. I sample 249 of those objects, and find that 19 have that attribute. I get a p- value here (looking at

Re: [R] writing simple function through script

2008-09-10 Thread Dieter Menne
Benoit Boulinguiez ensc-rennes.fr> writes: > yo<-function(Xdata) > { > n<-length(Xdata[,1]) > > Lgm<-nls(formula=LgmFormula, > data=Xdata, > start=list(a=1500,b=0.1),weights=Xdata$Qe) > return(Lgm) > } > > After the execution of the script, when I call the function yo on data > called NC60.

Re: [R] isolating X on an expression

2008-09-10 Thread Gabor Grothendieck
Try Ryacas: > library(Ryacas) > A <- Sym("A"); B <- Sym("B"); X <- Sym("X"); Y <- Sym("Y"); K <- Sym("K") > Solve(K==(sin(A) * sin(B) ) + ( cos(A) * cos(B) * cos ( X - Y ) ), "X") [1] "Starting Yacas!" expression(list(X == Y + acos((K - sin(A) * sin(B))/(cos(A) * cos(B))), X == Y - acos((K -

Re: [R] Mixed effects model with binomial errors - problem

2008-09-10 Thread Ben Bolker
RFTW nioo.knaw.nl> writes: > Our question is if the proportion of visits to the experimental tree, in > relation to the total number of visits to both trees differs between > treatments. > > We have made treatment and individual into a factor > All individuals were subjected to a maximum of 4

Re: [R] extract variance components

2008-09-10 Thread Lyman, Mark
Take a look again at help(getVarCov). Mark Lyman, Statistician ATK Launch Systems [EMAIL PROTECTED] From: huang min [mailto:[EMAIL PROTECTED] Sent: Tuesday, September 09, 2008 10:02 PM To: r-help@r-project.org Cc: [EMAIL PROTECTED] Subject: Re: extract variance components Hi, Thanks

Re: [R] writing simple function through script

2008-09-10 Thread Gabor Grothendieck
Its looking in environment(LgmFormula) for Xdata in order to evaluate Xdata$Qe in the weights argument so just specify weights = Qe. Alternately insert the following as the beginning of yo. It creates a new local LgmFormula but with its environment set to the current environment: environment(L

Re: [R] yahoo finance into R

2008-09-10 Thread davidr
Yahoo and OandA provide only daily data, but the history goes back quite a ways: > msft <- get.hist.quote(instrument="MSFT", start="1986-03-31", > end="2008-09-10", quote=c("O","H","L","C","A","V"), provider="yahoo", > retclass="zoo") > NROW(msft) [1] 5663 That's 22 years of data. Not sure what y

Re: [R] randomForest partial dependence plots

2008-09-10 Thread Liaw, Andy
The partial dependence at X1=x is simply the average of predicted response at all data points, holding X1=x. No additional `normalization' is done. That web link says the image does not exist. Andy From: Christopher Schwalm > Hello ALL, > > I'm unsure how to interpret partial dependence plot

[R] A question about the hypergeometric distribution and phyper()

2008-09-10 Thread michael watson (IAH-C)
Dear All I have a question about the hypergeomteric distribution. Example 1: I have a universe of 6187 objects, and 164 have a particular attribute, therefore 6187-164 do not have that attribute. I sample 249 of those objects, and find that 19 have that attribute. I get a p-value here (looking

  1   2   >