[R] Splitting lines in R script

2015-08-02 Thread Steven Yen
I have a line containing summation of four components. # This works OK: p-pbivnorm(bb,dd,tau)+pbivnorm(aa,cc,tau)- -pbivnorm(aa,dd,tau)-pbivnorm(bb,cc,tau) # This produces unpredicted results without warning: p-pbivnorm(bb,dd,tau)+pbivnorm(aa,cc,tau)

Re: [R] Splitting lines in R script

2015-08-02 Thread Peter Langfelder
R does not need a semicolon or other character to terminate a command; if a line can be interpreted as a complete command, it will (first line in your second example). Also note that the first example may not produce what you want (if your second example is any indication) - the result of

Re: [R] vectorized sub, gsub, grep, etc.

2015-08-02 Thread John Thaden
Adam, The original posting gave a function sub2 whose aim differs both from your functions' aim and from the intent of mgsub() in the qdap package: Here is code to apply a different pattern and replacement for every target.#Example X - c(ab, cd, ef) patt - c(b, cd, a) repl -

Re: [R-es] ayuda con análisis de supervivencia

2015-08-02 Thread Javier Rubén Marcuzzi
Estimado José Miguel Arbones Leí su solicitud respecto a un análisis de (Survival) donde quiere medir el efecto de dos genotipos en la aparición de un síndrome metabólico. Usted también pregunta sobre si estadísticamente sería apropiado ese enfoque. Leí algo de sobrevida en genética, pero su

Re: [R] Error when compiling R-2.5.1 / *** [d-p-q-r-tests.Rout] Fehler 1

2015-08-02 Thread Joerg Kirschner
Dear Martin, thanks for the advice, I'll check out Bioconductor. Meanwhile I reinstalled Ubuntu, this time as 64-bit and the error is gone : ) Rgds, Joerg On Sat, Aug 1, 2015 at 8:16 PM, Martin Morgan mtmor...@fredhutch.org wrote: On 07/31/2015 10:48 PM, Joerg Kirschner wrote: Hi everyone,

[R] NATURAL Smoothing B-splines

2015-08-02 Thread Marc Lamblin
Hi all, I'm an engineering student from Politecnico di Milano. I want to perform Smoothing using Smoothing B-splines on syntethic data. The splines must be NATURAL (at the edges the second and third order derivates are zero). How can I impose this constraint? I have searched in R documentation.

Re: [R] NATURAL Smoothing B-splines

2015-08-02 Thread Spencer Graves
library(sos) ns. - findFn('natural spline') found 191 matches; retrieving 10 pages 2 3 4 5 6 7 8 9 10 Downloaded 113 links in 70 packages. ns2 - findFn('natural splines') found 145 matches; retrieving 8 pages 2 3 4 5 6 7 8 Downloaded 70 links in 42 packages. ns2. - ns.|ns2 ns2. # This

[R-es] ayuda con análisis de supervivencia

2015-08-02 Thread JM ARBONES
Hola a todos, -Estoy estudiando el efecto de dos genotipos (~tratamientos) en la aparición de síndrome metabólico (MetS) con datos longitudinales recogidos a tiempo 0,7,10,15,20 y 25 años. -He hecho un dataframe con las siguientes variables MetS: Síndrome Metabólico (Si=1,No=0) bmi: Indice de

Re: [R] PythonInR. Python script in R with parameters required. Download satellite images from NASA

2015-08-02 Thread Florian Schwendinger
I believe the Problem is that you trying to give command line arguments pyExecfile(myPythonScript.py) and pyExecfile only expects to get a filename. In Pyhton27 pyExecfile only runs the Python command execfile on the given filename. So the Problem is that in