R_download RStudio CC BY-NC-SA 4.0

Basics of R Programming Language for Data Wrangling and Analysis

Last updated: 06 May 2023


Instructor: Prof Dr Md Kamrul Hasan

Dept of Agricultural Extension and Rural Development

Patuakhali Science and Technology University

Dumki, Patuakhali 8602

Email: kamrulext@pstu.ac.bd

Mobile: 01711 51 16 18



Lesson Plan for R Programming Part


Lesson 1: 23 September 2022 - Research Tools: Validity and Reliability

Contents: R program installation, concepts and examples of validity and reliability, revisiting the research design, unavoidable principles of experimental design, measuring validity and reliability


Lesson 2: 09 October 2022 - Application of R Programming for Data Analysis

Contents: Object, vector, variable, data types, mathematical operations, programming operators, combining vectors, installation ‘tidyverse’ package, loading package, data re-coding, tabulation, creating data-sets and writing data-sets in .csv format


Lesson 3: 14 October 2022 - Application of R Programming for Data file Reading, cross tabulation, Chi-square test, Fisher’s exact test

Contents: Data file reading (.csv and .xlsx formats), assumptions of Chi-square test and executing Chi-square test


Lesson 4: 15 October 2022 - Application of R Programming for Variable Selection and Manipulation, data visualizations

Contents: Piping commands, column (variable) and row (case or subject) selection, variable gathering and spreading, summary information, customized summary with dplyr, mutating variables, plotting data


Lesson 5: 16 October 2022 - Correlation and regression using R

Contents: t-test, Welch test, correlation (Pearson and Spearman), simple regression, residual analysis


Lesson 6: 21 October 2022 - ANOVA using R

Contents: Multiple regression and ANOVA, selection of statistical tests, R learning by R (swirl, learnr, Rcmdr)