The RonR! Seminar Series is an interactive R course aimed at students who want to learn R. They were first created as a set of exercises for a series of lectures given in April-May 2016 in Pompeu Fabra University. These exercises have evolved to stand on their own and can now be accessed by following the tutorial here.
Seminar 1. An overview of the strengths of R
Note: This introduction does not contain exercises, only an RMarkdown presentation
Brief introduction to R
- First steps using R
- The webpage of the R project
- Installation of R
- R environment
- Contributed packages and their installation
- How to work with R: Workspaces and scripts
- R graphics
- Graphs (ggvis, ggplot2)
- Interactive graphs(ggvis, plotly, shiny, Rcharts)
- Maps
- R and statistics
- Summary statistics output(stargazer package)
- Regression output(stargazer package)
- R for reports and teaching
- Making reports, PDF's and powerpoints through R (RMarkdown package)
- Programming exercises and exams in R (swirl and exam package)
This seminar contains exercises here.
-
Vectors
- Numerical, logical and character vectors
- Generation of regular sequences
- Vector arithmetic
- Factos
- Matrices and lists
-
Matrices and lists
- Creation and modification of matrices
- Creation and modification of lists
- Subsetting matrices and lists
-
Data frames (I)
- Creation of data frames
- Adding new variables
- Subsetting data frames
-
Data frames (II)
- Working with data frames: Functions attach and with
- Merging data frames
- Labelling variables
This seminar contains exercises here
-
Importing data from SPSS, EXCEL and STATA
-
Basic data manipulation:
- Creating new variables
- Recoding variables
- Renaming variables
- Selecting and removing variables
- Filtering and subsetting variables
- Grouping variables
- Merging datasets
-
Basic descriptive analyses:
- Computation of numerical indicators (mean, median, variance, etc.)
- Frequency tables for categorical variables
- Correlations of two numerical variables
- Contingency tables for two categorical variables