Re: [R] Jackknife estimates of predict.lda success rate

2007-03-28 Thread Prof Brian Ripley
Reposting the same message is not making it any easier for your audience to understand. You need to tell us what you mean by your subject line and 'jackknife reclassification'. Given these are far from standard terms, either you mean something else (and 'jackknife' is very frequently misused

Re: [R] Replacement in an expression - can't use parse()

2007-03-28 Thread Daniel Berg
Thank you very much for your good suggestions. I have chosen to pursue the suggestion by Peter which worked like a dream :) However, my problem is slightly more complicated still. I apologize for not mentioning this in the initial question. I have to do the evaluation inside a loop, not knowing

[R] nlsystemfit: Errors with reproducing the manual example

2007-03-28 Thread Federico Tamagni
Hi everybody, I'm a newbye with lots of problems :). I'm trying to use nlsystemfit, but I recieve two error messages whose origin that I don't understand. 1) When I try to reproduce the example reported in the systemfit package manual, that is library( systemfit ) data( ppine ) hg.formula -

[R] Standardization Range

2007-03-28 Thread Sergio Della Franca
Dear R-Helpers, I want to perform a standardization of a variable with range method. i.e.: Standardization (range) == (var-min(var))/(max(var)-min(var)) Do you konw how can i develop this? Thank you in advance. Sergio Della Franca [[alternative HTML version deleted]]

Re: [R] Standardization Range

2007-03-28 Thread Stéphane Dray
Hi sergio, Sergio Della Franca wrote: Dear R-Helpers, I want to perform a standardization of a variable with range method. i.e.: Standardization (range) == (var-min(var))/(max(var)-min(var)) Do you konw how can i develop this? As you do ... but don't use var which is the name of

Re: [R] Use of 'defineVar' and 'install' in .Call

2007-03-28 Thread Daniel Berg
Now it works, I made no changes to the functions in question, must have been some other mistake in my code and I obviously misinterpreted the crash report. defineVar(install(str),mkans(x),rho) works fine. The content of the variable 'str' is assigned in the given environment in R as it should. I

Re: [R] Standardization Range

2007-03-28 Thread Dimitris Rizopoulos
you can still use scale() (as you have been told), look at the help page for more info, especially at the Arguments section, e.g., mat - matrix(rnorm(100*10), 100, 10) rng - apply(mat, 2, range) scale(mat, scale = rng[2, ] - rng[1, ]) or you could even use apply() directly, e.g., apply(mat,

[R] R equivalent of S+SeqTrial?

2007-03-28 Thread francogrex
Does anyone know of an R package that is equivalent of S+SeqTrial for analysis of clinical trials using group sequential methods? Thanks. -- View this message in context: http://www.nabble.com/R-equivalent-of-S%2BSeqTrial--tf3478858.html#a9708877 Sent from the R help mailing list archive at

[R] Kmeans Ward

2007-03-28 Thread Sergio Della Franca
Dear R-Helpers, I want to perform a kmeans clustering with ward method. How can i obtain this? Thank yuo in advance. Serigo Della Franca [[alternative HTML version deleted]] __ R-help@stat.math.ethz.ch mailing list

[R] Regarding Vista

2007-03-28 Thread gyadav
Hi All Does R supports Vista Business and Vista Home Premium. I am planning to upgrade my system. Before that I just wanted to confirm whether R will work on Vista or not. Thanks for this help in advance -gaurav Sayonara With Smile With Warm Regards :-) G a u r a v Y a d a v

Re: [R] Regarding Vista

2007-03-28 Thread Uwe Ligges
[EMAIL PROTECTED] wrote: Hi All Does R supports Vista Business and Vista Home Premium. I am planning to upgrade my system. Before that I just wanted to confirm whether R will work on Vista or not. Although R Core does not officially support Vista, AFAIK, we have heard of working

Re: [R] eliminating panel borders from lattice plots

2007-03-28 Thread John Bullock
On 3/25/07, John Bullock [EMAIL PROTECTED] wrote: I am trying to eliminate panel borders from my lattice plots. By default, they always print. For example: library(lattice) x - seq(-3,3,length=1000) y1 - dnorm(x) y2 - dnorm(x, sd=.5) data - data.frame(x=rep(x,2),

[R] Import of a workspace into R

2007-03-28 Thread Schmitt, Corinna
Hallo, Sorry for more details before but I was in a hurry. One workspace comes from Matlab and one should come from Bioconductor. At the moment I can just work with the Matlab-workspace. I just know that the data is stored in an Excel-File -- I have a table. I know that there exists an RMatlab

[R] regarding time series object

2007-03-28 Thread gyadav
Hello All I have time series data like given hereinbelow :- The data is having dates. I tried using ts() but it requires frequency. As i have holidays, saturdays sunday market closed, and also sometimes the data may not be recorded. I want to create a time series object but i want that where

Re: [R] Replacement in an expression - can't use parse()

2007-03-28 Thread Gabor Grothendieck
The solution in my post has the advantage of not using eval or character conversions (except in setting up L where you want such character conversions to build up the names, as your more general sitution shows). The following is the same as in that post except the line setting L in that post is

Re: [R] regarding time series object

2007-03-28 Thread Gabor Grothendieck
I am not 100% sure of what you want but maybe this will help. I have modified your example data to omit one point so that there is a holiday among the rows: library(zoo) # read data Lines - DateOpenHigh Low CloseNifty 2004-01-01 1880.35 1917.05 1880.351912.25 2004-01-02 1912.25

[R] Help with grep (and similar functions)

2007-03-28 Thread Alberto Monteiro
This works: grep(([A-Za-z]*) , Aaaa 3 x 0 Bbbb) # 1 This also works: grep(([A-Za-z]*) , Aaaa 3 x 0 Bbbb, value=T) # Aaaa 3 x 0 Bbbb However, I want a grep that returns the _matched_ pattern, which, in this case, would be Aaaa. How can I do it? Alberto Monteiro

[R] aggregating data with Zoo

2007-03-28 Thread Alfonso Sammassimo
Is there a way of aggregating 'zoo' daily data according to day of week? eg all Thursdays I came across the 'nextfri' function in the documentation but am unsure how to change this so any day of week can be aggregated. I have used POSIX to arrange the data (not as 'zoo' series) according to

Re: [R] Regarding Vista

2007-03-28 Thread christian.ritter
Hi folks, The Vista issue is not innocent as it threatens the life of R within large corporations. So any posts on how R runs under Vista and what has to be done to make it work and what cannot be done etc will be very useful. Chris -Original Message- From: [EMAIL PROTECTED]

[R] Optimal workstation architecture for running R / Bioconductor

2007-03-28 Thread Höning , Gunther
Dear list, I use a lot of data files (at the moment 35 files by 34 MB each) for analysis. My own processing steps will (hopefully) improve with increasing number of files I have. So I am looking for an suitable workstation configuration, e.g. 64bit architecture, 16 GB RAM etc. Does

[R] (no subject)

2007-03-28 Thread kaloytyn
Hallo, I'm trying to sample a matrix with simple random sampling without replacement but seem to have a problem with the matrix length. Both sample() and srswor() use length() which returns the number of columns in matrix. This means that to function it seems that the sample size exceeds the

Re: [R] Help with grep (and similar functions)

2007-03-28 Thread Gabor Grothendieck
Try this: library(gsubfn) pat - ([[:upper:]][[:lower:]]*) s - Aaaa 3 x 0 Bbbb strapply(s, pat, backref =-1)[[1]] or (not quite as general but works in this case): pat - ([[:upper:]][[:lower:]]*) s - Aaaa 3 x 0 Bbbb s.idx - gregexpr(pat, s)[[1]] substring(s, s.idx, s.idx + attr(s.idx,

Re: [R] Import of a workspace into R

2007-03-28 Thread Marc Schwartz
On Wed, 2007-03-28 at 13:22 +0200, Schmitt, Corinna wrote: Hallo, Sorry for more details before but I was in a hurry. One workspace comes from Matlab and one should come from Bioconductor. At the moment I can just work with the Matlab-workspace. I just know that the data is stored in an

Re: [R] R equivalent of S+SeqTrial?

2007-03-28 Thread Marc Schwartz
On Wed, 2007-03-28 at 02:42 -0700, francogrex wrote: Does anyone know of an R package that is equivalent of S+SeqTrial for analysis of clinical trials using group sequential methods? Thanks. I don't know that there are fully functional equivalents, but you might want to look at the following:

Re: [R] aggregating data with Zoo

2007-03-28 Thread Gabor Grothendieck
Please read the last line on every post to r-help. On 3/28/07, Alfonso Sammassimo [EMAIL PROTECTED] wrote: Is there a way of aggregating 'zoo' daily data according to day of week? eg all Thursdays I came across the 'nextfri' function in the documentation but am unsure how to change this so

Re: [R] Regarding Vista

2007-03-28 Thread Prof Brian Ripley
On Wed, 28 Mar 2007, [EMAIL PROTECTED] wrote: The Vista issue is not innocent as it threatens the life of R within large corporations. So any posts on how R runs under Vista and what has to be done to make it work and what cannot be done etc will be very useful. See the rw-FAQ in the

Re: [R] line style outliers in boxplot

2007-03-28 Thread AA
Thank you Gabor. This works. And you are right, bxp is actually on the boxplot help page. I am sorry I missed it. Thanks again. A. - Original Message - From: Gabor Grothendieck [EMAIL PROTECTED] To: AA [EMAIL PROTECTED] Cc: r-help@stat.math.ethz.ch Sent: Tuesday, March 27, 2007 7:49 PM

Re: [R] Help with grep (and similar functions)

2007-03-28 Thread Alberto Monteiro
Gabor Grothendieck wrote: Try this: library(gsubfn) pat - ([[:upper:]][[:lower:]]*) s - Aaaa 3 x 0 Bbbb strapply(s, pat, backref =-1)[[1]] Ok, I think I got it. For example, if I want to retrieve Aaaa and Bbbb (which could be any strings) or the numbers 3 and 0, I would do this:

Re: [R] Regarding Vista

2007-03-28 Thread christian.ritter
Thanks Brian. Working for one of these large corporations, I receive a considerable amount of mails requesting me to verify whether software I use (and which was made avalailable via company wide installers on my request) is Vista compatible. It's not that these big companies will roll out

[R] scale of gamma distribution

2007-03-28 Thread Xin
Dear All: If y~Ga(a,b) What's about the (n-1)y~Ga(a, (n-1)b), is this right? Many Thanks [[alternative HTML version deleted]] __ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the

Re: [R] Samplng from a matrix (was: no subject)

2007-03-28 Thread Marc Schwartz
On Wed, 2007-03-28 at 15:46 +0300, [EMAIL PROTECTED] wrote: Hallo, I'm trying to sample a matrix with simple random sampling without replacement but seem to have a problem with the matrix length. Both sample() and srswor() use length() which returns the number of columns in matrix. This

Re: [R] Reading config data from text files

2007-03-28 Thread Peter Dalgaard
Alberto Monteiro wrote: Pete Cap wrote: I'm writing a tcl/tk gui tool to wrap around RMySQL for some co-workers. Good luck; I find the documentation on the library(tcltk) very poor, lacking examples for most of the functions. Well, they are interface functions, and what you

[R] changes in behaviour of Rcmd SHLIB since 2.4.0

2007-03-28 Thread Jan . Kleinn
Dear all, I have some C code using the zlib uncompress. It compiles fine under Win XP (with SP2) with R up to 2.3.1 and generates four files (Makedeps, *.d, *.dll, and *.o): C:\Data\R-packages\cmgrcmd SHLIB cmg.c -o cmg.dll latex: not found making cmg.d from cmg.c gcc

[R] substitute NA values

2007-03-28 Thread Sergio Della Franca
Dearl R-Helpers, I have the following data set: YEAR PRODUCTS 1990 2478 1995 3192 2000 NA 2005 1594 I wanto to replace NA values, in the PRODUCTS column, with 0. How can i obtain this? Thak you in advance. Sergio Della Franca [[alternative HTML version

[R] fitting data with conditions

2007-03-28 Thread [EMAIL PROTECTED]
Mich beschäftig folgende Fragestellung. Ich kenne die Verteilung (lognormal) zusätzlich weiss ich das 99%, das 90% und das 1% Quantil. Gibt es in R eine Möglichkeit die Lognormalverteilung zu finden, das heisst den korrespondierenden logmean und logsd? Vielen Dank für ihre Hilfe Gruss Yvonne

[R] Problem with adding packages to default start-up list

2007-03-28 Thread Jeff Lusk
After reading the help files (?Startup) and using RSiteSearch(defaultPackages), I have been trying to add several packages to my default startup list using the following code: local({ old-getOption(defaultPackages) options(defaultPackages=c(old,lattice,RODBC) }) Subsequently, when I query the

Re: [R] substitute NA values

2007-03-28 Thread Marc Schwartz
On Wed, 2007-03-28 at 16:21 +0200, Sergio Della Franca wrote: Dearl R-Helpers, I have the following data set: YEAR PRODUCTS 1990 2478 1995 3192 2000 NA 2005 1594 I wanto to replace NA values, in the PRODUCTS column, with 0. How can i obtain this? Thak

Re: [R] substitute NA values

2007-03-28 Thread Uwe Ligges
See ?is.na and use its result for indexing. Uwe Ligges Sergio Della Franca wrote: Dearl R-Helpers, I have the following data set: YEAR PRODUCTS 1990 2478 1995 3192 2000 NA 2005 1594 I wanto to replace NA values, in the PRODUCTS column, with 0. How can i

Re: [R] changes in behaviour of Rcmd SHLIB since 2.4.0

2007-03-28 Thread Uwe Ligges
Since R-2.4.0 less symbols are exported from R.dll. Uwe Ligges [EMAIL PROTECTED] wrote: Dear all, I have some C code using the zlib uncompress. It compiles fine under Win XP (with SP2) with R up to 2.3.1 and generates four files (Makedeps, *.d, *.dll, and *.o):

Re: [R] changes in behaviour of Rcmd SHLIB since 2.4.0

2007-03-28 Thread Prof Brian Ripley
On Wed, 28 Mar 2007, [EMAIL PROTECTED] wrote: Dear all, I have some C code using the zlib uncompress. It compiles fine under Win XP (with SP2) with R up to 2.3.1 and generates four files (Makedeps, *.d, *.dll, and *.o): No one every said that zlib interface would be exported from R, and as

Re: [R] Problem with adding packages to default start-up list

2007-03-28 Thread Prof Brian Ripley
On Wed, 28 Mar 2007, Jeff Lusk wrote: After reading the help files (?Startup) and using RSiteSearch(defaultPackages), I have been trying to add several packages to my default startup list using the following code: local({ old-getOption(defaultPackages)

Re: [R] substitute NA values

2007-03-28 Thread Jorge Cornejo-Donoso
This could work, but not with big matrix! year - c(1990,1995,2000,2005) Prod - c(2478,3192,NA,1594) matrix - data.frame(cbind(year,Prod)) for (i in 1:dim(matrix)[1]) { if (is.na(matrix[i,2])) {matrix[i,2] - 0} } __

Re: [R] fitting data with conditions

2007-03-28 Thread Uwe Ligges
This mailing list is in english If you know that for the quantiles, say: 1%: 3 90%: 5.2 99%: 6.1 then you could quickly look for the minimum of the following function foo - function(x){ (qlnorm(0.01, meanlog = x[1], sdlog = x[2]) - 3)^2 + (qlnorm(0.9, meanlog = x[1], sdlog =

Re: [R] what is the difference between survival analysis and (...)

2007-03-28 Thread Eric Elguero
Hi everybody, recently I had to teach a course on Cox model, of which I am not a specialist, to an audience of medical epidemiologists. Not a good idea you might say.. anyway, someone in the audience was very hostile. At some point, he sayed that Cox model was useless, since all you have to do is

Re: [R] aggregating data with Zoo

2007-03-28 Thread Achim Zeileis
On Wed, 28 Mar 2007, Alfonso Sammassimo wrote: Is there a way of aggregating 'zoo' daily data according to day of week? eg all Thursdays Sure, the easiest way will probably differ depending on the time stamp class. One example might be this: ## small example with Date index z -

Re: [R] what is the difference between survival analysis and (...)

2007-03-28 Thread Frank E Harrell Jr
Eric Elguero wrote: Hi everybody, recently I had to teach a course on Cox model, of which I am not a specialist, to an audience of medical epidemiologists. Not a good idea you might say.. anyway, someone in the audience was very hostile. At some point, he sayed that Cox model was useless,

[R] Kmeans

2007-03-28 Thread Sergio Della Franca
Dear R-Helpers, I performed kmeans clustering on the following data set(y): YEAR PRODUCTS 1 10 2 42 3 25 4 42 5 40 6 45 7 44 8 47 9 42 with this code:

Re: [R] R equivalent of S+SeqTrial?

2007-03-28 Thread Douglas Bates
On 3/28/07, Marc Schwartz [EMAIL PROTECTED] wrote: On Wed, 2007-03-28 at 02:42 -0700, francogrex wrote: Does anyone know of an R package that is equivalent of S+SeqTrial for analysis of clinical trials using group sequential methods? Thanks. I don't know that there are fully functional

Re: [R] fitting data with conditions

2007-03-28 Thread Peter Dalgaard
[EMAIL PROTECTED] wrote: Mich beschäftig folgende Fragestellung. Ich kenne die Verteilung (lognormal) zusätzlich weiss ich das 99%, das 90% und das 1% Quantil. Gibt es in R eine Möglichkeit die Lognormalverteilung zu finden, das heisst den korrespondierenden logmean und logsd? (Nicht

Re: [R] R equivalent of S+SeqTrial?

2007-03-28 Thread Marc Schwartz
On Wed, 2007-03-28 at 10:49 -0500, Douglas Bates wrote: On 3/28/07, Marc Schwartz [EMAIL PROTECTED] wrote: On Wed, 2007-03-28 at 02:42 -0700, francogrex wrote: Does anyone know of an R package that is equivalent of S+SeqTrial for analysis of clinical trials using group sequential methods?

Re: [R] what is the difference between survival analysis and (...)

2007-03-28 Thread Lucke, Joseph F
You can (and I have) fit survival data with logistic regression. Agresti (1990, pp 189--196) has an introductory discussion. The issue is whether the occurrence of the event is of interest or whether the time-to-event is of interest. If the study lasts 180 days (as in my case) logistic

[R] weight factor in somers2 function

2007-03-28 Thread sara . vallecillo
Hi! I’m trying to calculate de C index (concordance probability) through the somers2 function (library Hmisc). I’m interesting on including the sampling effort as a weight factor for the evaluation of model predictions with real data. I’ve some questions about that: first of all I’m not really

[R] multi-level modeling R?

2007-03-28 Thread John Kane
A colleague was asking me if R does multi-level modelling as opposed to multiple regression. Since I have no knowledge of multi-level modelling (except 5 minutes googling ) I thought that I would as here. Does are offer any multi-level modeling packages? It looked like arm might be one but I

Re: [R] multi-level modeling R?

2007-03-28 Thread Andrew Perrin
Yes, typically one uses lme4 or nlme to do multilevel modeling in R. -- Andrew J Perrin - andrew_perrin (at) unc.edu - http://perrin.socsci.unc.edu Assistant Professor of Sociology; Book Review Editor, _Social Forces_ University

Re: [R] what is the difference between survival analysis and (...)

2007-03-28 Thread Christos Hatzis
On the same point, transforming time-to-event data to binary outcomes so that contingency-table analysis (odds ratios etc) or logistic regression can be applied will result in loss of information that could lead to misleading conclusions. For example, assuming that there is a good-prognosis

Re: [R] multi-level modeling R?

2007-03-28 Thread Chuck Cleland
John Kane wrote: A colleague was asking me if R does multi-level modelling as opposed to multiple regression. Since I have no knowledge of multi-level modelling (except 5 minutes googling ) I thought that I would as here. Does are offer any multi-level modeling packages? It looked like

[R] differences among time points Using manova

2007-03-28 Thread Mario A. Morales R.
How I test for differences among time points without assuming parallelism, With a profile analysis model, Using manova R function. For example, with Potthoff and Roy data (Potthoff and Roy 1964) how I can test H: ABC=0, when A-diag(2) and C-rbind(diag(3),rep(-1,3)) (Davis, 2005 p.p 81 ).

[R] Large matrix into a vector

2007-03-28 Thread A Ezhil
Hi, I have a matrix HR(9x27). I would like to make a single vector with elements: t(HR[,1]) followed by t(HR[,2]) and then t(HR[,3] ... etc. Is there any neat way of converting this matrix into a vector rather doing something like c(t(HR[,1]), t(HR[,2]), t(HR[,3]) ..)? Thanks in Advance. Kind

Re: [R] Large matrix into a vector

2007-03-28 Thread Ravi Varadhan
c(HR) will do it. Ravi. --- Ravi Varadhan, Ph.D. Assistant Professor, The Center on Aging and Health Division of Geriatric Medicine and Gerontology Johns Hopkins University Ph: (410) 502-2619 Fax: (410)

Re: [R] Large matrix into a vector

2007-03-28 Thread Gabor Csardi
A matrix is just a vector with a dim attribute, so if you remove the dim attribute it'll be a vector. The elements of a matrix are stored columnwise so you'll get just what you want, if i get your question right. g - matrix(1:6, nc=2, nr=3) g [,1] [,2] [1,]14 [2,]25 [3,]

Re: [R] Large matrix into a vector

2007-03-28 Thread Marc Schwartz
On Wed, 2007-03-28 at 10:27 -0700, A Ezhil wrote: Hi, I have a matrix HR(9x27). I would like to make a single vector with elements: t(HR[,1]) followed by t(HR[,2]) and then t(HR[,3] ... etc. Is there any neat way of converting this matrix into a vector rather doing something like

Re: [R] Large matrix into a vector

2007-03-28 Thread Alberto Monteiro
A Ezhil wrote: I have a matrix HR(9x27). I would like to make a single vector with elements: t(HR[,1]) followed by t(HR[,2]) and then t(HR[,3] ... etc. Is there any neat way of converting this matrix into a vector rather doing something like c(t(HR[,1]), t(HR[,2]), t(HR[,3]) ..)? It

Re: [R] what is the difference between survival analysis and (...)

2007-03-28 Thread Prof Brian Ripley
That is not the only way to apply logistic regression to this problem (although it is a common error in the analysis of cancer studies). One can discretize time and apply logistic regression to survival over each short time period (jointly): doing so comes pretty close to what the Cox

[R] warnings on adapt

2007-03-28 Thread lmpalaci
Hi all I was wondering if someone could help me. I have to estimate some parameters, so I am using the function nlm. Inside this function I have to integrate, hence I am using the function adapt. I don't understand why it is giving the following warnings: At the beginning: Warning: a final

Re: [R] warnings on adapt

2007-03-28 Thread Ranjan Maitra
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code. No one can help you. Ranjan On Wed, 28 Mar 2007 11:47:03 -0600 (MDT) [EMAIL PROTECTED] wrote: Hi all I was wondering if someone could help me.

Re: [R] Large matrix into a vector

2007-03-28 Thread Prof Brian Ripley
We have already seen three solutions. I don't like to see the use of c() for its side effects. In this case Marc's as.vector seems to me to be self-explanatory, and that is a virtue in programming that is too often undervalued. On Wed, 28 Mar 2007, Marc Schwartz wrote: On Wed, 2007-03-28 at

Re: [R] multi-level modeling R?

2007-03-28 Thread Christos Hatzis
Also, take a look at Andrew Gelman's recent book with Jennifer Hill on multilevel modeling. It is written as a practical how-to text book using R as the primary platform. I have found it very easy to read, extremely useful and very good value for its price (I am not related to the authors or the

Re: [R] multi-level modeling R?

2007-03-28 Thread John Kane
Thanks Christos Some low life managed to get it out of the library! It looks worth reading, I must say. --- Christos Hatzis [EMAIL PROTECTED] wrote: Also, take a look at Andrew Gelman's recent book with Jennifer Hill on multilevel modeling. It is written as a practical how-to text book using

[R] .duplicate question

2007-03-28 Thread Leeds, Mark \(IED\)
I am using the vars package and it calls a function causality() which then calls something called .duplicate. I had to modify the causality function slightly for my purposes and I called it my.causality() but now the .duplicate function is no longer known to the my.causality function. I'm fairly

[R] is this trellis device or standard graphics device?

2007-03-28 Thread Prasenjit Kapat
OK, here is the issue: I have a graphcis device (say X11) which I can set as active by dev.set(n). Is there ANY way to identify/infer whether this X11 device was obtained from a lattice function (like xyplot, levelplot...) or a standard function (like plot, scatterplot,...). A related question is

[R] geoRglm question with covariates

2007-03-28 Thread Ken Nussear
Hi All, I'm trying to use the geoRglm package to run a poisson spatial glm on a dataset with several covariates. When I run without covariates I have no problems. control1.data.geo - mcmc.control(S.scale=0.2, thin = 1) model1.data.geo - list(cov.pars = c(1,1), beta=c(1), family=poisson)

Re: [R] .duplicate question

2007-03-28 Thread Benilton Carvalho
have you tried replacing .duplicate() in your my.causality() by vars:::.duplicate() ? b On Mar 28, 2007, at 3:11 PM, Leeds, Mark ((IED)) wrote: I am using the vars package and it calls a function causality() which then calls something called .duplicate. I had to modify the causality

Re: [R] Large matrix into a vector

2007-03-28 Thread John Kane
Is this something like what you want? ab - rep(1,4) bb - rep(2,4) cc - rep(3,4) mydata - data.frame(ab,bb,cc) unlist(mydata) unlist(data.frame(t(mydata))) --- A Ezhil [EMAIL PROTECTED] wrote: Hi, I have a matrix HR(9x27). I would like to make a single vector with elements: t(HR[,1])

Re: [R] weight factor in somers2 function

2007-03-28 Thread Frank E Harrell Jr
[EMAIL PROTECTED] wrote: Hi! I’m trying to calculate de C index (concordance probability) through the somers2 function (library Hmisc). I’m interesting on including the sampling effort as a weight factor for the evaluation of model predictions with real data. I’ve some questions about that:

Re: [R] multi-level modeling R?

2007-03-28 Thread John Kane
Thanks to everyone for the information and to Chuck for the links. I must have misspelt something because I missed most of them in the RsiteSearch. Anyway back to selling R :) --- Chuck Cleland [EMAIL PROTECTED] wrote: John Kane wrote: A colleague was asking me if R does multi-level

[R] what is the difference between EM clustering and latent class analysis

2007-03-28 Thread zhongmiao wang
Hello: Is EM clustering the same as latent class analysis? Thank you. Zhongmiao Wang Senior Analyst RMG Connect [[alternative HTML version deleted]] __ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE

Re: [R] aggregating data with Zoo

2007-03-28 Thread Alfonso Sammassimo
Thankyou Achim. Along these lines, how might I extract subsets from that set by day of week? eg: create a new series that includes Mondays only. Thanks, Alf - Original Message - From: Achim Zeileis [EMAIL PROTECTED] To: Alfonso Sammassimo [EMAIL PROTECTED] Cc: r-help@stat.math.ethz.ch

[R] By sentence

2007-03-28 Thread Erin Hodgess
Hi again! Please try something like this: zone1.df zone sex len 11 male 15 21 fema 20 31 fema 17 42 fema 19 52 male 18 str(zone1.df) 'data.frame': 5 obs. of 3 variables: $ zone: Factor w/ 2 levels 1,2: 1 1 1 2 2 $ sex : Factor w/ 2 levels fema,male: 2 1 1 1 2

Re: [R] Large matrix into a vector

2007-03-28 Thread Marc Schwartz
On Wed, 2007-03-28 at 19:55 -0200, Alberto Monteiro wrote: Prof Brian Ripley wrote: We have already seen three solutions. I don't like to see the use of c() for its side effects. In this case Marc's as.vector seems to me to be self-explanatory, and that is a virtue in programming

[R] Outlier detection with the dprep library

2007-03-28 Thread Talbot Katz
Hi. The dprep library has at least three different methods for outlier detection: baysout, mahaout, robout. I wanted to test them on a very simple data set: vrmat-cbind((1:22),c(8,14,14,17,21,20,27,23,25,33,31,32,30,36,37,40,42,44,52,61,81,265)) As you can see by eyeballing this, the last

Re: [R] Large matrix into a vector

2007-03-28 Thread Alberto Monteiro
Prof Brian Ripley wrote: We have already seen three solutions. I don't like to see the use of c() for its side effects. In this case Marc's as.vector seems to me to be self-explanatory, and that is a virtue in programming that is too often undervalued. I agree; but for our

Re: [R] Large matrix into a vector

2007-03-28 Thread Peter Dalgaard
Marc Schwartz [EMAIL PROTECTED] writes: On Wed, 2007-03-28 at 19:55 -0200, Alberto Monteiro wrote: Prof Brian Ripley wrote: We have already seen three solutions. I don't like to see the use of c() for its side effects. In this case Marc's as.vector seems to me to be

[R] string into command

2007-03-28 Thread Brian Dolan
Hello, I would like to take the string mylist = list(a = 5, b = 7) and evaluate it as a list. I have attempted to use parse and several other functions with no success. Thanks for your time. -brian dolan ~~~ may all your sequences converge [[alternative HTML version deleted]]

[R] Bonferroni p-value greater than 1

2007-03-28 Thread Horace Tso
Hi folks, I use the outlier.test in package car to test a lm model and the bonferroni p value returned is shown as NA. When the object is typed it indicates the p value is greater than 1. I'm not sure how to interpret it. Thanks in advance. Horace W. Tso outlier.test(mod)$test

Re: [R] string into command

2007-03-28 Thread Benilton Carvalho
cmd = mylist = list(a = 5, b = 7) (eval(parse(text=cmd))) b On Mar 28, 2007, at 11:38 AM, Brian Dolan wrote: Hello, I would like to take the string mylist = list(a = 5, b = 7) and evaluate it as a list. I have attempted to use parse and several other functions with no success.

[R] options(error=recover) in .Rprofile

2007-03-28 Thread Andy Jacobson
Hi, I'd like to try using options(error=recover) in my ~/.Rprofile, but it appears that the function recover is not defined during R startup when the .Rprofile is processed. recover is defined after I get an R prompt, however. Can anyone shed light on why this is, and whether a

Re: [R] string into command

2007-03-28 Thread Marc Schwartz
On Wed, 2007-03-28 at 08:38 -0700, Brian Dolan wrote: Hello, I would like to take the string mylist = list(a = 5, b = 7) and evaluate it as a list. I have attempted to use parse and several other functions with no success. Thanks for your time. Not sure what combinations you may

Re: [R] is this trellis device or standard graphics device?

2007-03-28 Thread Paul Murrell
Hi Prasenjit Kapat wrote: OK, here is the issue: I have a graphcis device (say X11) which I can set as active by dev.set(n). Is there ANY way to identify/infer whether this X11 device was obtained from a lattice function (like xyplot, levelplot...) or a standard function (like plot,

Re: [R] options(error=recover) in .Rprofile

2007-03-28 Thread Sundar Dorai-Raj
Andy Jacobson said the following on 3/28/2007 4:01 PM: Hi, I'd like to try using options(error=recover) in my ~/.Rprofile, but it appears that the function recover is not defined during R startup when the .Rprofile is processed. recover is defined after I get an R prompt, however.

Re: [R] multi-level modeling R?

2007-03-28 Thread AA
Thanks Christos for this tip on the book. I needed something like that get started on the topic. AA. - Original Message - From: Christos Hatzis [EMAIL PROTECTED] To: 'John Kane' [EMAIL PROTECTED]; 'Chuck Cleland' [EMAIL PROTECTED] Cc: 'R R-help' r-help@stat.math.ethz.ch Sent: Wednesday,

Re: [R] Use of 'defineVar' and 'install' in .Call

2007-03-28 Thread Douglas Bates
I did read your second message about the problem symptoms disappearing but I thought that I might make a couple of suggestions about your code anyway. There are a number of helper functions declared in Rinternals.h such as ScalarReal, which is equivalent to your mkans. (Also ScalarInteger,

Re: [R] what is the difference between survival analysis and (...)

2007-03-28 Thread Thomas Lumley
On Wed, 28 Mar 2007, Frank E Harrell Jr wrote: Eric Elguero wrote: Hi everybody, recently I had to teach a course on Cox model, of which I am not a specialist, to an audience of medical epidemiologists. Not a good idea you might say.. anyway, someone in the audience was very hostile. At

Re: [R] Bonferroni p-value greater than 1

2007-03-28 Thread John Fox
Dear Horace, The Bonferonni p-value is obtained from the unadjusted p-value by multiplying the latter by the number of observations, and provides a conservative (although usually quite accurate) outlier test. When the adjusted p-value exceeds 1 you can take that as an indication that there are no

Re: [R] is this trellis device or standard graphics device?

2007-03-28 Thread Prasenjit Kapat
Hi, On Wednesday 28 March 2007 07:32:08 pm Paul Murrell wrote: You could call the grid function getNames() and if that is zero-length, then the device is either blank or only contains traditional graphics. Thanks Dr. Murrell. I was looking for something simple like this. A related question

[R] to use EM algorithm for MLE

2007-03-28 Thread subhajit dutta
hi, I want to use EM for MLE estimation.WHAT would be the relevant package or code?? Regards, Subhajit. [[alternative HTML version deleted]] __ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read

Re: [R] Replacement in an expression - can't use parse()

2007-03-28 Thread Daniel Berg
Thank you Gabor, your solution works great, even for veeery long expressions. //Daniel On 3/28/07, Gabor Grothendieck [EMAIL PROTECTED] wrote: The solution in my post has the advantage of not using eval or character conversions (except in setting up L where you want such character conversions

Re: [R] Bonferroni p-value greater than 1

2007-03-28 Thread Peter Dalgaard
John Fox wrote: Dear Horace, The Bonferonni p-value is obtained from the unadjusted p-value by multiplying the latter by the number of observations, and provides a conservative (although usually quite accurate) outlier test. When the adjusted p-value exceeds 1 you can take that as an