Category Archives: Data Munging

Plotting With Custom X Axis Labels in R — Part 5 in a Series

This is post #05 in a running series about plotting in R. There are a variety of ways to control how R creates x and y axis labels for plots. Let’s walk through the typical process of creating good labels … Continue reading

Posted in Data Munging, Plotting, R, Visualization | Tagged , | 1 Comment

Plotting Multiple Series in R — Part 4 in a Series

This is post #04 in a running series about plotting in R. Frequently, you want to simultaneously plot multiple series on the same plot. Let’s try plotting daily observations along with a 30 day moving average. To start, I have … Continue reading

Posted in Data Munging, Plotting, R | Tagged , | 2 Comments

Column Names of R Data Frames

Say you read a data frame from a file but you don’t like the column names. Here’s how you go about labelling them as you like. Start with a simple csv file: col1, col2, col3 “1,233″, “$12.79″, “$1,333,233.17″ “470″, “$1,113.22″, … Continue reading

Posted in Data Munging, R | Leave a comment

Cleaning Data in R: csv files

When you read csv files, you regularly encounter Excel encoded csv files which include extraneous characters such as commas, dollar signs, and quotes. Such a file might look like col1, col2, col3 “1,233″, “$12.79″, “$1,333,233.17″ “470″, “$1,113.22″, “$0.12″ and call … Continue reading

Posted in Data Munging, R | 1 Comment