Re: [Rd] An offer: R packages in Gentoo Land?
Allen S. Rout wrote: > Greetings. I love R, we run Gentoo. I want to maintain R packages in > the same methods I use for the rest of them; in Gentoo this is in "the > portage tree", or in "a portage overlay". > > I am working towards something I consider suitable for production > release, and wanted to ask if there are conventional blessings which I > ought to ask of the R-devel folks; How does this usually go, in > R-land? > > Are there other developeRs who run Gentoo who would be willing to > kibitz? > I'm neither an R nor a Gentoo developer but I run Gentoo and R and would welcome an integrated Portage/CRAN/Bioconductor package management system. I would recommend joining the "gentoo-science" mailing list. Email me off list if you'd like an introduction. -- M. Edward (Ed) Borasky http://linuxcapacityplanning.com __ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel
Re: [Rd] Installation, permissions of /usr/local/lib/R (PR#9054)
[EMAIL PROTECTED] wrote: >Full_Name: Jori Mäntysalo >Version: 2.3.1 >OS: Linux, GNU/Debian stable >Submission from: (NULL) (81.197.171.182) > > >I said >./configure --with-readline=no --with-x=no >make >make install > >and everything works except that /usr/local/lib/R/etc/ldpaths was not readable >as normal user. > >__ >R-devel@r-project.org mailing list >https://stat.ethz.ch/mailman/listinfo/r-devel > > > > > You don't say if you installed R as root or as a normal user. Did you try: chown your-user-name /usr/local/lib/R/ -R ? Or, if you intend to make R available to several users, create a R users group and then type the previous command replacing "your-user-name" by "R-users-group-name". Maybe this would help. Thibaut. -- ## Thibaut JOMBART CNRS UMR 5558 - Laboratoire de Biométrie et Biologie Evolutive Universite Lyon 1 43 bd du 11 novembre 1918 69622 Villeurbanne Cedex Tél. : 04.72.43.29.35 Fax : 04.72.43.13.88 [EMAIL PROTECTED] http://biomserv.univ-lyon1.fr/sitelabo/pageperso.php?id_personne=178 __ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel
Re: [Rd] Installation, permissions of /usr/local/lib/R (PR#9054)
Thibaut Jombart <[EMAIL PROTECTED]> writes: > [EMAIL PROTECTED] wrote: > > >I said > >./configure --with-readline=no --with-x=no > >make > >make install > > > >and everything works except that /usr/local/lib/R/etc/ldpaths was not > >readable > >as normal user. > You don't say if you installed R as root or as a normal user. > Did you try: > chown your-user-name /usr/local/lib/R/ -R > ? > > Or, if you intend to make R available to several users, create a R users > group and then type the previous command replacing "your-user-name" by > "R-users-group-name". Maybe this would help. More likely, the umask setting was too restrictive during make install. AFAIR, "umask 022" (i.e. no write permission for anyone except user, but read and execute allowed) is needed to enable non-root users to run R. Some systems set it differently, and we're not overriding that since it could be a policy issue. It's not a bug. -- O__ Peter Dalgaard Øster Farimagsgade 5, Entr.B c/ /'_ --- Dept. of Biostatistics PO Box 2099, 1014 Cph. K (*) \(*) -- University of Copenhagen Denmark Ph: (+45) 35327918 ~~ - ([EMAIL PROTECTED]) FAX: (+45) 35327907 __ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel
Re: [Rd] Installation, permissions of /usr/local/lib/R (PR#9054)
Thibaut Jombart <[EMAIL PROTECTED]> writes: > [EMAIL PROTECTED] wrote: > > >I said > >./configure --with-readline=no --with-x=no > >make > >make install > > > >and everything works except that /usr/local/lib/R/etc/ldpaths was not > >readable > >as normal user. > You don't say if you installed R as root or as a normal user. > Did you try: > chown your-user-name /usr/local/lib/R/ -R > ? > > Or, if you intend to make R available to several users, create a R users > group and then type the previous command replacing "your-user-name" by > "R-users-group-name". Maybe this would help. More likely, the umask setting was too restrictive during make install. AFAIR, "umask 022" (i.e. no write permission for anyone except user, but read and execute allowed) is needed to enable non-root users to run R. Some systems set it differently, and we're not overriding that since it could be a policy issue. It's not a bug. -- O__ Peter Dalgaard Øster Farimagsgade 5, Entr.B c/ /'_ --- Dept. of Biostatistics PO Box 2099, 1014 Cph. K (*) \(*) -- University of Copenhagen Denmark Ph: (+45) 35327918 ~~ - ([EMAIL PROTECTED]) FAX: (+45) 35327907 __ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel
Re: [Rd] Test for argument in ...
Yes, this works. Thanks Gabor! Gabor Grothendieck wrote: > That's because you are passing the argument twice. Try this: > >> foo1 <- function(x, ...) > + { > + L <- list(...) > + if (is.null(L$decreasing)) L$decreasing <- TRUE > + do.call(order, c(list(x), L)) > + } >> >> foo1(c(5, 2, 3, 4), decreasing=FALSE) > [1] 2 3 4 1 > > On 7/1/06, Gregor Gorjanc <[EMAIL PROTECTED]> wrote: >> Hi, >> >> Gabor Grothendieck wrote: >> > Try this: >> > >> >> f <- function(...) if (!is.null(list(...)$arg1)) cat("arg1 found\n") >> >> else cat("arg1 not found\n") >> >> f(arg1 = 3) >> > arg1 found >> >> f(arg2 = 3) >> > arg1 not found >> >> Actually it is not OK. Bellow is simplified example that shows, what I >> would like to do: >> >> foo1 <- function(x, ...) >> { >> if(is.null(list(...)$decreasing)) { >>decreasing <- TRUE >> } else { >>decreasing <- list(...)$decreasing >> } >> return(order(x, ..., decreasing=decreasing)) >> } >> >> > foo1(c(5, 2, 3, 4)) >> [1] 1 4 3 2 >> >> >foo1(c(5, 2, 3, 4), decreasing=FALSE) >> Error in order(x, ..., decreasing = decreasing) : >>formal argument "decreasing" matched by multiple actual arguments >> >> > On 7/1/06, Gregor Gorjanc <[EMAIL PROTECTED]> wrote: >> >> Hello! >> >> >> >> Say I have a function foo1, which has argument ... to pass various >> >> arguments to foo2 i.e. >> >> >> >> foo1 <- function(x, ...) >> >> { >> >> foo2(x, ...) >> >> } >> >> >> >> Say that foo2 accepts argument arg1 and I would like to do the >> following: >> >> - if foo1 is called as foo1(x) then I would like to assign some >> value to >> >> arg1 inside foo1 before calling foo2 >> >> >> >> arg1 <- "some value" >> >> foo2(x, arg1=arg1) >> >> >> >> - if foo1 is called foo1(arg1="some other value") do not assign some >> >> value to arg1 and call foo2 >> >> >> >> foo2(arg1=arg1) >> >> >> >> However, I am not able to do this since I do not know how to >> test/check >> >> if arg1 was given in foo1. Is it possible to test whether some >> argument >> >> was passed in "..." i.e. something like >> >> >> >> foo1 <- function(x, ...) >> >> { >> >> if(testForArgumentInThreeDots(arg1)) arg1 <- "some value" >> >> foo2(x, arg1=arg1, ...) >> >> } >> >> >> >> Thanks! -- Lep pozdrav / With regards, Gregor Gorjanc -- University of Ljubljana PhD student Biotechnical Faculty Zootechnical Department URI: http://www.bfro.uni-lj.si/MR/ggorjan Groblje 3 mail: gregor.gorjanc bfro.uni-lj.si SI-1230 Domzale tel: +386 (0)1 72 17 861 Slovenia, Europefax: +386 (0)1 72 17 888 -- "One must learn by doing the thing; for though you think you know it, you have no certainty until you try." Sophocles ~ 450 B.C. __ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel
Re: [Rd] Test for argument in ...
Bill Dunlap wrote: > On Sun, 2 Jul 2006, Gregor Gorjanc wrote: > >> Yes, this works. >> >> Thanks Gabor! >> >> Gabor Grothendieck wrote: >>> That's because you are passing the argument twice. Try this: >>> foo1 <- function(x, ...) >>> + { >>> + L <- list(...) >>> + if (is.null(L$decreasing)) L$decreasing <- TRUE >>> + do.call(order, c(list(x), L)) >>> + } foo1(c(5, 2, 3, 4), decreasing=FALSE) >>> [1] 2 3 4 1 > > How does this differ from >foo2 <- function(x, ..., decreasing=TRUE) > order(x, ..., decreasing = decreasing) > ? I agree, but I wanted to learn ... argument in a more general way. That was just an example - not a good one as you have showed. >> x<-c(5,2,3,4) >> identical(foo2(x), foo1(x)) > [1] TRUE >> identical(foo2(x,decreasing=F), foo1(x,decreasing=F)) > [1] TRUE >> identical(foo2(x,decreasing=T), foo1(x,decreasing=T)) > [1] TRUE -- Lep pozdrav / With regards, Gregor Gorjanc -- University of Ljubljana PhD student Biotechnical Faculty Zootechnical Department URI: http://www.bfro.uni-lj.si/MR/ggorjan Groblje 3 mail: gregor.gorjanc bfro.uni-lj.si SI-1230 Domzale tel: +386 (0)1 72 17 861 Slovenia, Europefax: +386 (0)1 72 17 888 -- "One must learn by doing the thing; for though you think you know it, you have no certainty until you try." Sophocles ~ 450 B.C. __ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel
[Rd] "Template" for model.matrix functions
Hello! I would like to write a function that would create a (part) of a model matrix to be used in lm() like functions i.e lm(y ~ myFunc(x)) Where can I find a good example or a template for this as well as for predict method? Thanks! -- Lep pozdrav / With regards, Gregor Gorjanc -- University of Ljubljana PhD student Biotechnical Faculty Zootechnical Department URI: http://www.bfro.uni-lj.si/MR/ggorjan Groblje 3 mail: gregor.gorjanc bfro.uni-lj.si SI-1230 Domzale tel: +386 (0)1 72 17 861 Slovenia, Europefax: +386 (0)1 72 17 888 -- "One must learn by doing the thing; for though you think you know it, you have no certainty until you try." Sophocles ~ 450 B.C. __ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel
[Rd] Package Unit Testing
Hello, Do we have like an official unit testing framework for packages? Like we do R CMD check, and say the scripts in /test are executed? Or do we roll out our own outside the package? Thanks, M. Manese __ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel
Re: [Rd] Package Unit Testing
miguel manese wrote: > Hello, > > Do we have like an official unit testing framework for packages? Like > we do R CMD check, and say the scripts in /test are executed? The scripts are executed with R CMD check. What else do you need? Uwe Ligges > Or do we roll out our own outside the package? > > Thanks, > M. Manese > > __ > R-devel@r-project.org mailing list > https://stat.ethz.ch/mailman/listinfo/r-devel __ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel