Get startedGet started for free

Pearson ignoring groups

A Pearson correlation assesses the strength and direction of a linear relationship. After deriving the needed sample size and assuring the data is appropriate, the Pearson analyses can be run.

A company is interested in assessing the relationship between the amount of time spent searching items on their website and the amount of money spent on purchasing items. You have determined a Pearson correlation is fitting given a non-significant Shapiro test and linear scatter plot. Perform the Pearson correlation test ignoring groups, determine the proportion of variance explained, and run the power analysis of the test to determine if there is a significant relationship and whether the results found are reliable.

The pwr package and SiteSales dataset have been loaded for you.

This exercise is part of the course

A/B Testing in R

View Course

Hands-on interactive exercise

Have a go at this exercise by completing this sample code.

# Run the Pearson correlation
cor.test(___, 
         data = ___, 
         method = ___)
Edit and Run Code