Marinstatslectures

Like Us on FacebookFollow Us on TwitterSubscribe to Us on Youtube!Join Us on Google+

 Paired t Test in R (R Tutorial 4.4)

In this video, you will learn to conduct the matched paired t-test in R. This test is used to compare the means of two paired or dependent populations.

First, we will explain when it is appropriate to use the paired t-test and confidence interval to analyze the data. Then you will learn to visualize and interpret the difference in means for two populations that are paired or dependent on one another using a boxplot or scatterplot. Next, we will show you how to add a line for X=Y (eg. before= after) in a paired data plot using the "abline" command and how to interpret the scatterplot of paired or dependent data

Later in this tutorial, you will see how to do the paired t-test in R using the "t.test" command, how to let R know to test if the mean difference is 0 in the paired t-test using the "mu" argument and how to have a two-sided t-test using the "alt" argument.

We will also demonstrate how you can let R know that the data is paired when conducting t-test using  "paired" argument, how to specify the level of confidence interval in R using the "conf.level" argument and how the order that X and Y are entered in "t.test" command in R for a paired-t-test changes the results.

We recommend using the link below to download the dataset and practice on your own while watching this tutorial.

You can access and download the dataset that was used in this tutorial here:

Tab Delimited BloodPressure Dataset for R TutorialsExcel BloodPressure Dataset for R Tutorials

 

 

Previous Video in Series 4 R Tutorials

Back to Series 4 R Tutorials

Next Video in Series 4 R Tutorials