Tag: r
Perspectives on Python after R
July 24, 2020#python #r
My first programming language was R. I fell in love with the nuance R granted for visualizing data, and how with a little practice it was straightforward to pull off complex statistical analyses. I coded in R throughout my Ph.D., but I needed to switch to Python for my first non-academic job. Picking up a second language went much faster than the first, but there was a lot to get used to when I transitioned.
Visualizing the danger of multiple t-test comparisons
May 13, 2018#projects #r #statistics
It’s often tempting to make multiple t-test comparisons when running analyses with multiple groups. If you have three groups, this logic would look like “I’ll run a t-test to see if Group A is significantly different from Group B, then another to check if Group A is significantly different from Group C, then one more for whether Group B is different from Group C.” This logic, while seemingly intuitive, is seriously flawed. I’ll use an R function I wrote, false_pos
, to help visualize why multiple t-tests can lead to highly inflated false positive rates.
Linear regression via gradient descent
April 22, 2018#machine-learning #projects #r #statistics
After hearing so much about Andrew Ng’s famed Machine Learning Coursera course, I started taking the course and loved it. (His demeanor can make any topic sound reassuringly simple!) Early in the course, Ng covers linear regression via gradient descent. In other words, given a series of points, how can we find the line that best represents those points? And to take it a step further, how can we do that with machine learning?
Visualizing my daily commute
November 1, 2017#projects #r
I love data visualization, and one holiday my partner surprised me with the book Dear Data. The book is a series of weekly letters two data analysts wrote to one another with visualizations of data on random topics. One week they tracked the number of times they said “thank you,” for example; another week, they counted the number of times they looked at a clock. In their letters, they visualized their data. One of the most interesting parts of the book was seeing how differently they could plot the same type of data.
How to be fancy with comparisons in R
October 14, 2017#r
Welcome to another episode of “Random R,” where we’ll ask random programming and statistical questions and answer them with R. Today, for whatever reason, let’s say we want to dive into methods for comparing values. We’ll start simple (e.g. is 5 greater than 4? Read on to find out.) and then work our way towards trickier element-wise comparisons among multiple matrices.
For loops vs. apply - a race in efficiency
July 13, 2017#projects #r
Welcome to the first Random R post, where we ask random programming questions and use R to figure them out. In this post we’ll look at the computational efficiency of for
loops versus the apply
function.
Learning R 5. The apply functions
February 1, 2017#r
Learning R series
- Introduction
- Random data and plotting
for
loops and random walks- Functions and
if
statements - The
apply
functions
Learning R 4. Functions and if statements
May 15, 2016#r
Learning R series
- Introduction
- Random data and plotting
for
loops and random walks- Functions and
if
statements - The
apply
functions
Learning R 3. For loops and random walks
April 24, 2016#r
Learning R series
- Introduction
- Random data and plotting
for
loops and random walks- Functions and
if
statements - The
apply
functions
Learning R 2. Random data and plotting
December 22, 2015#r
Learning R series
- Introduction
- Random data and plotting
for
loops and random walks- Functions and
if
statements - The
apply
functions
Learning R 1. Introduction
December 15, 2015#r
Learning R series