Re: [R] Fleming-Harrington weighted log rank test

2018-02-14 Thread David Winsemius
> On Feb 14, 2018, at 5:26 PM, David Winsemius wrote: > >> >> On Feb 13, 2018, at 4:02 PM, array chip via R-help >> wrote: >> >> Hi all, >> >> The survdiff() from survival package has an argument "rho" that implements >> Fleming-Harrington

Re: [R] Fleming-Harrington weighted log rank test

2018-02-14 Thread David Winsemius
> On Feb 13, 2018, at 4:02 PM, array chip via R-help > wrote: > > Hi all, > > The survdiff() from survival package has an argument "rho" that implements > Fleming-Harrington weighted long rank test. > > But according to several sources including "survminer" package

Re: [R] using cat to log to file with sapply

2018-02-14 Thread Bert Gunter
Not sure what you wanted to do.Note that you have "test'txt" and "log.txt" in your code. Using only "test.txt", the following worked fine for me: letters[1:5]->x logf<-"test.txt" cat('%%\n',file=logf) catf<-function(x,...,logfile='test.txt', append=TRUE){ cat(x,'\n',

Re: [R] using cat to log to file with sapply

2018-02-14 Thread Jeff Newmiller
Your call to catf in testit is after the return, so it is never called. FWIW my antibugging strategy (and readability strategy) is to never use the return function... I structure my logic to end up at the end with my desired function result in a variable and I simply put that variable on the

Re: [R] using cat to log to file with sapply

2018-02-14 Thread William Dunlap via R-help
testit<-function(x,...){ paste0('this is x: ',x)->y return(y) catf("++test=",...) } You return from the function before calling catf(). Remove the 'return(y)' and make 'y' the last expression in the function. Bill Dunlap TIBCO Software wdunlap tibco.com On

[R] using cat to log to file with sapply

2018-02-14 Thread Alexander.Herr
Hi List, I am trying to write unsuccessfully to a logfile with cat. Here my example code: letters[1:5]->x logf<-"test.txt" cat('%%\n',file=logf) catf<-function(x,...,logfile='log.txt', append=TRUE){ cat(x,'\n', file=logfile, append=append)} testit<-function(x,...){

Re: [R] Parallel assignments and goto

2018-02-14 Thread Fox, John
Dear Thomas, This looks like a really interesting project, and I don't think that anyone responded to your message, though I may be mistaken. I took at a look at implementing parallel assignment, and came up with: passign <- function(..., envir=parent.frame()){ exprs <- list(...) vars

Re: [R] help with the plot overlay

2018-02-14 Thread Fix Ace via R-help
Hi, JIm, Thank you so much! Such a convenient tool! A. On Sunday, February 4, 2018 9:59 PM, Jim Lemon wrote: Hi Ace, You can do it with plotrix: library(plotrix) barpos<-barp(c(1,5,38),width=0.5,col=c("white","lightgray","darkgray"),ylim=c(0,70))

Re: [R] long vectors not supported yet

2018-02-14 Thread Jeff Newmiller
This looks to me like a package development issue... which may be under discussion in R-sig-geo (search the archives), but more likely to be appropriate to discuss with the maintainer by email or through their development repository (R-forge, though it looks unused). -- Sent from my phone.

[R] long vectors not supported yet

2018-02-14 Thread Loris Bennett
Hi, I am running R 3.3.3 and getting the following error: Error in add_edges(res, edges = t(as.matrix(el[, 1:2])), attr = weight) : long vectors not supported yet: ../../src/include/Rinlinedfuns.h:138 when passing a 13 GB TransitionLayer object to shortestPath from the package

Re: [R] How to turn off warnings about class name conflicts

2018-02-14 Thread Ayhan yuksel
Thanks Daniel for your reply However I get these warnings even I start with a fresh R session and remove all objects (including hidden ones) before executing the mentioned codes I also tried reinstalling these libraries including zoo and xts libraries, but the problem continues I guess this is

[R] Unexpected behaviour in rms::lrtest

2018-02-14 Thread Kevin E. Thorpe
Hello. One of my teaching assistants was experimenting and encountered unexpected behaviour with the lrtest function in the rms package. It appears that when you have a pair of non-nested models that employ an RCS, the error checking for non-nested models appears not to work. Here is a

Re: [R-es] Tapply para medias entre mas de 2 factores

2018-02-14 Thread Carlos Ortega
Hola, Si el conjunto no es muy grande, puedes utilizar la función "aggregate()". Saludos, Carlos Ortega www.qualityexcellence.es El 14 de febrero de 2018, 14:13, Yesica Pallavicini Fernandez < yesipa...@gmail.com> escribió: > Hola. > Tengo unos datos de rendimiento de distintas variedades en 2

Re: [R-es] Ayuda

2018-02-14 Thread Freddy Omar López Quintero
Holap. El mié, 14-02-2018 a las 13:41 +0100, Francisco Javier Ibáñez López escribió: > Tengo una base de datos con 28 sujetos, a los cuales se les mide un > montón de elementos (tengo 27 variables dependientes) en tres > tiempos > distintos (un total de 84 mediciones por variable). Busco

[R-es] Tapply para medias entre mas de 2 factores

2018-02-14 Thread Yesica Pallavicini Fernandez
Hola. Tengo unos datos de rendimiento de distintas variedades en 2 localidades. Quiero sacar la media de cada variedad en cada una de las localidades. La función tapply solo me hace la media por variedad o por localidad, pero no juntas. ¿Conoceis alguna función que calcule la media de cada

Re: [R-es] Ayuda

2018-02-14 Thread Francisco Javier Ibáñez López
Gracias Javier Rubén, muy amable. Echaré un vistazo. Saludos, El 14/02/18 a las 13:51, Javier Marcuzzi escribió: > Estimado Francisco Javier Ibáñes López > > Puede utilizar un ejemplo de lme4 o nlme, hay algunos sobre > trabajador, máquina, y le agregan algunas cosas mezclando y >

Re: [R-es] Ayuda

2018-02-14 Thread Javier Marcuzzi
Estimado Francisco Javier Ibáñes López Puede utilizar un ejemplo de lme4 o nlme, hay algunos sobre trabajador, máquina, y le agregan algunas cosas mezclando y complicando el modelo, no recuerdo bien en que libro leí estos o si eran dentro de las ayudas públicas. Algo que puede ser importante es

[R-es] Ayuda

2018-02-14 Thread Francisco Javier Ibáñez López
Buenos días a tod@s, Tengo una base de datos con 28 sujetos, a los cuales se les mide un montón de elementos (tengo 27 variables dependientes) en tres tiempos distintos (un total de 84 mediciones por variable). Busco comparar unas variables con otras. ¿Alguien me ayuda con el modelo

Re: [R] How to turn off warnings about class name conflicts

2018-02-14 Thread Daniel Nordlund
On 2/13/2018 11:47 PM, Ayhan yuksel wrote: Hi, I am using two packages (quantmod and FRAPO) Quantmod and FRAPO both have a class names "zoo" R is displaying the following warning when I manipulate an object of class zoo: Found more than one class "zoo" in cache; using the first, from

[R] How to turn off warnings about class name conflicts

2018-02-14 Thread Ayhan yuksel
Hi, I am using two packages (quantmod and FRAPO) Quantmod and FRAPO both have a class names "zoo" R is displaying the following warning when I manipulate an object of class zoo: Found more than one class "zoo" in cache; using the first, from namespace 'quantmod' Also defined by ‘FRAPO’ The