Monthly Archives: May 2010

R function names, explained

May 11, 2010
By

Why is the function to print out text in R named "cat"? Why is the function to delete objects called "rm"? Unless you have a background in Unix (or Linux) programming, some of R's command names can seem, well, a bit arcane. Jeromy Anglim explains the provenance of many of R's command names in this post: the details are...

Read more »

Beware of rogue header files (Bioconductor installation)

May 11, 2010
By
Beware of rogue header files (Bioconductor installation)

Just a short note concerning a “gotcha”. As I have many times before, I opened an R console on my newly-upgraded (to lucid 10.04) Ubuntu machine, typed source(“http://bioconductor.org/biocLite.R”) and began a Bioconductor install with biocLite(). Only this time, I saw this: Error in dyn.load(file, DLLpath = DLLpath, ...) : unable to load shared library '/home/sau103/R/i486-pc-linux-gnu-library/2.11/affyio/libs/affyio.so':

Read more »

Putting Text in a Margin

May 10, 2010
By
Putting Text in a Margin

I found text and title early on but was initially confounded when trying to add text outside of an actual chart. As it turns out, I needed to understand a bit about R's concept of margins in a chart> par(oma=c(2,2,2,2))> plot(rnorm)> mtext('The label'...

Read more »

String Concatenation in R

May 10, 2010
By
String Concatenation in R

String concatenation is a rather basic function - but my particular programming reflexes did not help me figure out how to do this in R. I tried the + and & operator, and even the || operator to no avail. Also tried concat() function... no dice. ...

Read more »

A ridiculous email

May 10, 2010
By
A ridiculous email

Wolfram Research presumably has a robot that sends automated email following postings on arXiv: Your article, “Evidence and Evolution: A review”, caught the attention of one of my colleagues, who thought that it could be developed into an interesting Demonstration to add to the Wolfram Demonstrations Project. The Demonstrations Project, launched alongside Mathematica 6 in

Read more »

Example 7.36: Propensity score stratification

May 10, 2010
By
Example 7.36: Propensity score stratification

In examples 7.34 and 7.35 we described methods using propensity scores to account for possible confounding factors in an observational study.In addition to adjusting for the propensity score in a multiple regression and matching on the propensity score...

Read more »

An economist explains: Why I use R

May 10, 2010
By

Economist and R blogger JD Long gave a talk last week (as part of the vconf.org project) about why he uses R to do statistical forecasts of agricultural yield for the reinsurance company he works for. I couldn't make the live session, but a replay is now available. The audio's a bit choppy, but if you've every struggled with...

Read more »

ggplot2: Waterfall Charts

May 10, 2010
By
ggplot2: Waterfall Charts

Waterfall charts are often used for analytical purposes in the business setting to show the effect of sequentially introduced negative and/or positive values. Sometimes waterfall charts are also referred to as cascade charts. In the next few paragraphs I will show how to plot a waterfall chart using ggplot2. Data A very small fictional dataset

Read more »

Abbreviations of R Commands Explained: 250+ R Abbreviations

May 10, 2010
By

The R programming language includes many abbreviations. Abbreviations exist in function names, argument names, and allowed values for arguments. This post expands on over 150 R abbreviations with the aim of making it easier for users new to R who are trying...

Read more »

Abbreviations of R Commands Explained: 250+ R Abbreviations

May 10, 2010
By

The R programming language includes many abbreviations. Abbreviations exist in function names, argument names, and allowed values for arguments. This post expands on over 150 R abbreviations with the aim of making it easier for users new to R who are trying...

Read more »