Guidelines for efficient R programming

September 22, 2010
By

R is designed to make it easy to clearly express statistical ideas in code, but when it come to writing code that runs as fast as possible, there are a few tips, tricks and caveats to be aware of. As part of the BioConductor conference this past summer, Martin Morgan prepared a tutorial on efficient R programming. (Patrick Abouyen...

Read more »

Visualizations of US neighborhoods by race and ethnicity

September 22, 2010
By
Visualizations of US neighborhoods by race and ethnicity

HOMOPHILY + MAPS WITHOUT MAPPING SOFTWARE In the past, Decision Science News has posted about homophily (“birds of a feather shop together“) and cool, lightweight visualizations (“maps without map packages in R“). Today, both topics come together in Eric Fischer’s fascinating set of images on Flickr called “Race and Ethnicity”(*).  According to Eric: Red is

Read more »

Connecting to SQL Server from R using RJDBC

September 22, 2010
By
Connecting to SQL Server from R using RJDBC

A few months ago I switched my laptop from Windows to Ubuntu Linux. I had been connecting to my corporate SQL Server database using RODBC on Windows so I attempted to get ODBC connectivity up and running on Ubuntu. ODBC on Ubuntu turned into an exercise in futility. I spent many hours over many days

Read more »

My Crappy Fantasy Football Draft

September 22, 2010
By
My Crappy Fantasy Football Draft

I compared the results of my fantasy football draft with the results of more than 1500 mock drafts at the Fantasy Football Calculator (FFC).  I looked at where player X was drafted in our league, subtracted off the average draft … Continue reading →

Read more »

R Function of the Day: foodweb

September 21, 2010
By
R Function of the Day: foodweb

The R Function of the Day series will focus on describing in plain language how certain R functions work, focusing on simple examples that you can apply to gain insight into your own data. Today, I will discuss the foodweb function, found in...

Read more »

R Function of the Day: foodweb

September 21, 2010
By
R Function of the Day: foodweb

The R Function of the Day series will focus on describing in plain language how certain R functions work, focusing on simple examples that you can apply to gain insight into your own data. Today, I will discuss the foodweb function, found in...

Read more »

Oil – Equities correlation – trading opportunity or new normal?

September 21, 2010
By
Oil – Equities correlation – trading opportunity or new normal?

The R-Files: Hadley Wickham

September 21, 2010
By
The R-Files: Hadley Wickham

"The R-Files" is an occasional series from Revolution Analytics, where we profile prominent members of the R Community. Name: Hadley Wickham Profession: Assistant Professor of Statistics, Rice University Nationality: New Zealand Years Using R: 10 Known for: Developing popular R packages including ggplot2, plyr, reshape; creator of crantastic.org; author of ggplot2: Elegant Graphics for Data Analysis An Assistant Professor...

Read more »

Classification Trees using the rpart function

September 21, 2010
By
Classification Trees using the rpart function

In a previous post on classification trees we considered using the tree package to fit a classification tree to data divided into known classes. In this post we will look at the alternative function rpart that is available within the base R distribution. Fast Tube by Casper A classification tree can be fitted using the rpart function

Read more »

Example 8.6: Changing the reference category for categorical variables

September 21, 2010
By
Example 8.6: Changing the reference category for categorical variables

How can we change the reference category for a categorical variable? This question comes up often in a consulting practice.When including categorical covariates in regression models, there is a question of how to incorporate the categories. One simpl...

Read more »

Install and load R package "Rcmdr" to quickly install lots of other packages

September 21, 2010
By

I recently reformatted my laptop and needed to reinstall R and all the packages that I regularly use. In a previous post I covered R Commander, a nice GUI for R that includes a decent data editor and menus for graphics and basic statistical analysis. Since Rcmdr depends on many other packages, installing and loading Rcmdr like this... install.packages("Rcmdr", dependencies=TRUE)library(Rcmdr) ..

Read more »

R tee-shirt

September 21, 2010
By
R tee-shirt

I gave my introduction to the R course in a crammed amphitheatre of about 200 students today. Had to wear my collectoR teeshirt from Revolution Analytics, even though it only made the kids pay attention for about 30 seconds… The other few “lines” that worked were using the Proctor & Gamble “car 54″ poster and

Read more »

AQP Examples: Profile Visualization

September 20, 2010
By

Two examples of the output from the profile_plot() function, using data from the Sierra Foothill Region, CA. read more

Read more »

Auto-complete for R in EmEditor

September 20, 2010
By
Auto-complete for R in EmEditor

This will work for any language you have a syntax file for, but I'll use R as the example.1. Open an R file, and on the plugins menu, click "Word Complete"2. Type a couple of letters e.g. rn and then press ctrl+space (default word suggest keyboard...

Read more »

Saptarshi Guha on Hadoop, R

September 20, 2010
By

Saptarshi Guha (author of the Rhipe package) joins the likes of Ebay, Yahoo, Twitter and Facebook and as one of just 37 presenters at the Hadoop World conference. (Revolution Analytics is proud to sponsor Saptarshi's presence at this event, which take place in New York on October 12.) He'll be talking about using R and Hadoop to analyze Voice-over-IP...

Read more »

Problems with R

September 20, 2010
By

Struggling for two whole days to do some not-terribly-advanced repeated-measures analysis of variance in R. Probably my worst experience with R so far and really an example of where R could do with some centralisation of effort. I have explored six or seven ways to do more or less the same thing, but each approach

Read more »

Problems with R

September 20, 2010
By

Struggling for two whole days to do some not-terribly-advanced repeated-measures analysis of variance in R. Probably my worst experience with R so far and really an example of where R could do with some centralisation of effort. I have explo...

Read more »

In case you missed it: August Roundup

September 20, 2010
By

In case you missed them, here are some articles from August of particular interest to R users. We noted that R had a key role in the US government's reaction to the BP oil spill, as related by the Statistical Engineering division chief at NIST. We linked to an example of creating an animation in Google Earth based on...

Read more »

Cricket – opinions and facts

September 20, 2010
By
Cricket – opinions and facts

@zxaar's comments in a Cricinfo article prompted this post. He commented that - "He (Miandad) was not great outside of pakistan where he was helped by home umpires. Not a true great. Miadad's case states lie due to favour from umpires."I'm an Indian...

Read more »

R syntax highlighting for bloggers on WordPress.com

September 20, 2010
By
R syntax highlighting for bloggers on WordPress.com

Announcing the ability to highlight R syntax in WordPress.com blogs, thanks to the recent work of Yihui Xie, Yoav Farhi and Andrew Redd.

Read more »

Data Mining in A Nutshell

September 20, 2010
By
Data Mining in A Nutshell

# The following code may look rough, but simply paste into R or# a text editor (especially Notepad++) and it will look# much better.# PROGRAM NAME: MACHINE_LEARNING_R# DATE: 4/19/2010# AUTHOR : MATT BOGARD# PURPOSE: BASIC EXAMPLES OF MACHINE LEAR...

Read more »

How fast is JAGS?

September 20, 2010
By
How fast is JAGS?

The OpenBUGS development team have created some validation code called WinComp that allows the results of OpenBUGS to be compared with WinBUGS 1.4 for all the examples in the OpenBUGS manual.  I have wrapped up this code into an R … Continue reading →

Read more »

R Code Examples

September 19, 2010
By
R Code Examples

Data Mining in a Nutshell 'neuralnet'  neural network estimation and visualizationVisualizing Agricultural Subsidies by KY County R Code For googleVis  Data Visualization

Read more »

R Tutorial Series: Labeling Data Points on a Plot

September 19, 2010
By
R Tutorial Series: Labeling Data Points on a Plot

There are times that labeling a plot's data points can be very useful, such as when conveying information in certain visuals or looking for patterns in our data. Fortunately, labeling the individual data points on a plot is a relatively simple process ...

Read more »

R Tutorial Series: Labeling Data Points on a Plot

September 19, 2010
By
R Tutorial Series: Labeling Data Points on a Plot

There are times that labeling a plot's data points can be very useful, such as when conveying information in certain visuals or looking for patterns in our data. Fortunately, labeling the individual data points on a plot is a relatively simple process ...

Read more »

Why Use ProjectTemplate or Any Other Framework?

September 19, 2010
By

We use frameworks like Ruby on Rails or ProjectTemplate to minimize the time we spend on irrelevant details. By definition, an irrelevant detail isn’t of interest to us. But how can we tell which details are irrelevant? This isn’t a trivial task and it seems to be, on the surface, a profoundly subjective matter. Thankfully,

Read more »

Response Times, The Exponential Distribution and Poisson Processes

September 18, 2010
By
Response Times, The Exponential Distribution and Poisson Processes

I’m currently reading Luce’s “Response Times”. If you don’t know anything about response times, they are very easily defined: a response time is the length of time it takes a person to respond to a simple request, measured from the moment when the request is made to the moment when the person’s response is recorded.

Read more »

Elder Research Two Day Course

September 18, 2010
By

... or what I did on my summer vacation...Just got back from the Elder Research Two Day Course "Tools for Discovering Patterns in Data".  It was a great course that (while not R specific) provides a great overview of Data Mining tools and tec...

Read more »

Elder Research Two Day Course

September 18, 2010
By

... or what I did on my summer vacation...Just got back from the Elder Research Two Day Course "Tools for Discovering Patterns in Data".  It was a great course that (while not R specific) provides a great overview of Data Mining tools and tec...

Read more »