search for: muxspace

Displaying 7 results from an estimated 7 matches for "muxspace".

2013 Jan 21
0
lambda.r 1.1.0 on CRAN
...owed") } fib(0) %as% 1 fib(1) %as% 1 fib(n) %as% { fib(n-1) + fib(n-2) } > fib(-1) Error in function (n) : Negative numbers not allowed > fib(5) [1] 8 Documentation is available at the following locations: . http://cartesianfaith.wordpress.com/category/r/lambda-r/ . https://github.com/muxspace/lambda.r A more complete discussion on why analytical systems should be designed using functional programming principles will be available in my forthcoming book on functional programming and computational finance. Warm Regards, Brian Rowe
2013 Jan 21
0
lambda.r 1.1.0 on CRAN
...owed") } fib(0) %as% 1 fib(1) %as% 1 fib(n) %as% { fib(n-1) + fib(n-2) } > fib(-1) Error in function (n) : Negative numbers not allowed > fib(5) [1] 8 Documentation is available at the following locations: . http://cartesianfaith.wordpress.com/category/r/lambda-r/ . https://github.com/muxspace/lambda.r A more complete discussion on why analytical systems should be designed using functional programming principles will be available in my forthcoming book on functional programming and computational finance. Warm Regards, Brian Rowe
2013 Jul 17
1
On the mechanics of function evaluation and argument matching
Hello, Section 4.3.2 of the R language definition [1] states that argument matching to formal arguments is a 3-pass process to match arguments to a function. An error is generated if any (supplied) arguments are left unmatched. Interestingly the opposite is not true as any unmatched formals does not generate an error. > f <- function(x,y,z) x > f(2) [1] 2 > f(2,3) [1] 2 Since R is
2014 Jan 22
1
Behavior of --install-tests and testInstalledPackage
Hello, I'm writing a script that automates the testing of reverse dependencies of a package. I found the function testInstalledPackage in the tools package, which seems to do what I want. However, when I use it for a source package that was installed with --install-tests, I've noticed that only the actual test files (e.g. located in inst/tests) are available and run. In other words the
2009 Jul 20
1
Application logging in R
Hello, I'm curious to know how people log their applications in R. It seems like it's a combination of cat statements or writing out the session to a file, given the discussions I've had with people. This is fine for interactive work but is a little lacking for automated systems. To address this, I've written a logging facility modeled on the log4j Java library. The basic concept
2013 Feb 04
2
Contract Syntactic Sugar
## the following is a dream: add some sugar syntax to allow for contracts with teeth (in and out checking) > is.positive <- function(x) (all(x>0)) > exponentiate <- function( x ::is.data.frame , exponent ::is.numeric is.positive) :: is.vector is.numeric { x$base :: is.positive ## error also if base does not exist in x; may need some special IQ x$base^exponent }
2013 Jan 14
1
Issue with getParserData in R3.0.0
Hello, I am migrating my package lambda.r to R3.0.0 and am experiencing some issues with the getParserData function (which replaces the parser package). Basically the function works in the R shell but fails when either called from RUnit or from R CMD check. I've narrowed it down to the function getSrcfile, which is returning different values depending on the code path. From the command line