Blog Archives

Writing manuscripts in Rstudio, easy citations

March 13, 2017
By
Writing manuscripts in Rstudio, easy citations

Intro and setup This is a simple explanation of how to write a manuscript in RStudio. Writing a manuscript in RStudio is not ideal, but it has gotten better over time. It is now relatively easy to add citations to documents in RStudio. **The goal...

Read more »

Generate text using Markov Chains (sort of)

January 20, 2017
By

Inspired by the hilarious podcast The Greatest Generation, I have worked again with all the lines from all the episode scripts of TNG. Today I will make a clunky bot (although it does nothing and is absolutely not useful) that talks like Captain ...

Read more »

Plotting a map with ggplot2, color by tile

January 5, 2017
By
Plotting a map with ggplot2, color by tile

Introduction Last week I was playing with creating maps using R and GGPLOT2. As I was learning I realized information about creating maps in ggplot is scattered over the internet. So here I combine all that knowledge. So if something is absolutel...

Read more »

Submitting your first package to CRAN, my experience

July 8, 2016
By
Submitting your first package to CRAN, my experience

I recently published my first R package to The Comprehensive R Archive Network (CRAN). It was very exciting and also quite easy. Let me walk you through my process. First a description of my brand new package: badgecreatr, then a description of steps to take for submission. Package description When you go around github looking at projects you often see...

Read more »

Introducing Badgecreatr, a package that places badges in your readme

July 7, 2016
By
Introducing Badgecreatr, a package that places badges in your readme

Introducing Badgecreatr, a package to create and place badges in your readme.Rmd file on Github. Badgecreatr will create the following badges (aka shields): minimal R...</p><p><a href=Read more »

Non-standard-evaluation and standard evaluation in dplyr

June 12, 2016
By

I love the dplyr package with all of its functions, however if you use normal dplyr in functions in your package r-cmd-check will give you a warning: R CMD check NOTE: No visible binding for global variable NAME OF YOUR VARIABLE 1. The functions do work, and everything is normal, however if you submit your package to CRAN,...

Read more »

Your most valuable collaborator, future-you

May 25, 2016
By
Your most valuable collaborator, future-you

I was recently at a R users meetup where Hadley Wickham talked about data wrangling. He showed some interesting stuff! Did you know that you can put a data frame into a data frame? You can make a list of data frames and add that list to your data frame. Very cool, and more useful then...

Read more »

From spss to R, part 4

April 3, 2016
By
From spss to R, part 4

This is the second part of working with ggplot. We will combine the packages dplyr and ggplot to improve our workflow. When you make a visualisation you often experiment with different versions of your plot. Our workflow will be dynamic, in stead of saving every version of the plot you created, we will recreate the plot untill it...

Read more »

Creating a package for your data set

March 6, 2016
By
Creating a package for your data set

Turning your dataset into a package is very useful for reproducable research. This tutorial is for you, even if you’ve never created a package in r. Why would you turn your dataset into a package? very easy to share easy to load (library(name) is easier then load("path/to/file") or data<-read.csv("path/to/file") etc.) documentation is part of the package and will never...

Read more »

From spss to R, part 3

March 1, 2016
By
From spss to R, part 3

In this post we will start with a build-in dataset and some basic ggplot graphics. In the next post we will combine dplyr and ggplot to do awesome stuff with the Dutch University student counts from the previous lessons. We will work with the build-in dataset mtcars. There are many datasets in r library(help = "datasets") but in many examples online...

Read more »

Sponsors

Never miss an update!
Subscribe to R-bloggers to receive
e-mails with the latest R posts.
(You will not see this message again.)

Click here to close (This popup will not appear again)