Blog Archives

Thoughts on R’s Terrible, Horrible, No Good, Very Bad Documentation

March 10, 2015
By
Thoughts on R’s Terrible, Horrible, No Good, Very Bad Documentation

A couple of days ago Pete Werner had a rant about the state of R’s documentation. A lot of it was misguided, but it had some legitimate complaints, and the fact that people can perceive R’s documentation as being bad (whether accurate or not) is important in itself. The exponential growth in R’s popularity means

Read more »

Many package updates on CRAN

February 4, 2015
By
Many package updates on CRAN

Over the last week or two I’ve been pushing all my packages to CRAN. pathological (for working with file paths), runittotestthat (for converting RUnit tests to testthat tests), and rebus (formerly regex, for building regular expressions in a human readable way) all make their CRAN debuts. assertive, for run-time testing your code has more checks

Read more »

How do you get things into base-R?

January 15, 2015
By
How do you get things into base-R?

A couple of months ago I spotted that the examples for the paste function weren’t very good, and actually, there were quite a few functions that new users of R are likely to encounter, that weren’t well explained. I’ve now managed to get some updated examples into R (paste, sum, NumericConstants, pie, a couple dozen

Read more »

Update on improving examples in base-R

December 24, 2014
By
Update on improving examples in base-R

Last month I was ranting about the state of some of the examples in base-R, particularly the paste function. Martin Maechler has now kindly taken my suggested examples and added them into R. Hopefully this will reduce the number of newbie questions about “how do I join these strings together”. Since Martin showed some interest

Read more »

Improving base-R examples

November 25, 2014
By
Improving base-R examples

Earlier today I saw the hundred bazillionth question about how to use the paste function. My initial response was “take a look at example(paste) to see how it works”. Then I looked at example(paste), and it turns out that it’s not very good at all. There isn’t even an example of how to use the

Read more »

Regular expressions for everyone else

September 25, 2014
By
Regular expressions for everyone else

Regular expressions are an amazing tool for working with character data, but they are also painful to read and write.  Even after years of working with them, I struggle to remember the syntax for negative lookahead, or which way round the start and end anchor symbols go. Consequently, I’ve created the regex package for human

Read more »

Finally, a use for rapply

July 15, 2014
By
Finally, a use for rapply

Tagged: r, rapply, recursive, stats

Read more »

Automatically convert RUnit tests to testthat tests

May 12, 2014
By
Automatically convert RUnit tests to testthat tests

There’s a new version of my assertive package, for sanity-checking code, on its way to CRAN. The release has been delayed a while, since my previous attempt at an upload met with an error that was only generated on the CRAN machine, but not on my own. The problem lay with some code designed to

Read more »

Introducing the pathological package for manipulating paths, files and directories

April 28, 2014
By
Introducing the pathological package for manipulating paths, files and directories

I was recently hunting for a function that will strip the extension from a file – changing foo.png to foo, and so forth. I was knitting a report, and wanted to replace the file extension of the input with the extension of the the output file. (knitr handles this automatically in most cases but I

Read more »

Fearsome Engines Part 3: Which one should you use?

October 13, 2013
By
Fearsome Engines Part 3: Which one should you use?

There are lots of R engines emerging! I’ve interviewed members of each of the teams involved in these projects. In part 1 of this series, we covered the motivation of each project. Part 2 looked at the technical achievements and new features. This part tries to determine which projects are suitable for which users. Compatibility

Read more »