Step 1: Design the Experiment

An experiment was performed to know if people who are primed have a greater preference for products. This experiment was performed by priming 22 of the 42 participants to have a preference towards a shampoo brand, while the 20 people in the control group were not.

Step 2: Data

preference<-read.csv("preference.csv")
preference
##    preference primed
## 1         1.8      0
## 2         0.1      0
## 3         4.0      0
## 4         2.1      0
## 5         2.4      0
## 6         3.4      0
## 7         1.7      0
## 8         2.2      0
## 9         1.9      0
## 10        1.9      0
## 11        0.1      0
## 12        3.3      0
## 13        2.1      0
## 14        2.0      0
## 15        1.4      0
## 16        1.6      0
## 17        2.3      0
## 18        1.8      0
## 19        3.2      0
## 20        0.8      0
## 21        1.7      1
## 22        1.7      1
## 23        4.2      1
## 24        3.0      1
## 25        2.9      1
## 26        3.0      1
## 27        4.0      1
## 28        4.1      1
## 29        2.9      1
## 30        2.9      1
## 31        1.2      1
## 32        4.0      1
## 33        3.0      1
## 34        3.9      1
## 35        3.1      1
## 36        2.5      1
## 37        3.2      1
## 38        4.1      1
## 39        3.9      1
## 40        1.1      1
## 41        1.9      1
## 42        3.1      1

Step 3: Describe the Data

The data is has two columns and 42 rows. One column has quantitative values of each participants preference for the product. The second column is a qualitative column that reveals which participants were primed and which were not. The primed participants have a 1 in this column, while the non-primed participants have a 0 in this column.

Step 4: Identify the Purpose of the Study

The purpose of this study is to find out if priming people will have an effect on their preference for the product that they are primed for.

Step 5: Visualize Data

library(ggplot2)
ggplot(data=preference, mapping=aes(x=primed,y=preference))+geom_point()

Step 6: Interpret the Data

The graph above suggests that the primed group had a greater preference for the product than the non-primed group. This greater preference is suggested because the majority of the points in the primed column are higher than the majority of the points in the non-primed column. However, since the data is so close, a t-test must be performed to clarify if the means are different.

Step 7: Null Hypotheses

The null hypothesis of the study is that there is no difference in preference between the primed and no-primed groups.

Step 8: Alternative Hypothesis

The alternative hypothesis of the study is that there is a difference between the preference of the primed group compared with the non-primed group. This would suggest that priming has an effect on advertising.

Step 9: Type of Test

A t-test will be performed because there are two variables, primed and no-primed, that are being compared.

Step 10: Number of samples

A two sample t-test will be performed because there are two groups: the control group which was not primed and the experimental group which was primed.

Step 11: Check Assumptions

ggplot(data=preference) + geom_qq(mapping=aes(sample=preference, color=as.factor(primed)))

If the data is normal they will lie on a line. The data appears to be fairly close to this line, so it has a normal distribution.

Step 12: Level of Significance

The traditional 0.05 level of significance will be used.

Step 13: Perform test

t.test(formula=preference~as.factor(primed), data=preference)
## 
##  Welch Two Sample t-test
## 
## data:  preference by as.factor(primed)
## t = -3.2072, df = 39.282, p-value = 0.002666
## alternative hypothesis: true difference in means is not equal to 0
## 95 percent confidence interval:
##  -1.577912 -0.357543
## sample estimates:
## mean in group 0 mean in group 1 
##        2.005000        2.972727

Step 14: Interpret the p-value

According to the t-test, the mean of the non-primed group is 2.005, while the mean of the primed group is 2.972. The p-value of the t-test is 0.00266. Since this value is less than the critical value of 0.05, the null hypothesis can be rejected. Therefore we can say with certainty that the means are indeed different.

Step 15: Interpret Confidence Intervals

Zero is not a plausible value in the 95% confidence interval. Therefore, there is a difference between the two groups.

Step 16: Interpret the Sample estimates

Since the null hypothesis can be rejected and zero is not within the confidence intervals, we can conclude that there is a difference between the means. Since there is a difference between the means, they were not recorded by chance, so the mean of the primed group is indeed hightr than the mean of the non-primed group.

Step 17: Conclusion

In conclusion, people who are primed for a certain product will have a greater preference towards this product. This is evident because the mean prefernece for the primed group was 2.972, while the mean preference for the non-primed group was 2.005. We can say that the group that was primed had a greater preference towards the product than the non-primed group because the t-test revealed that the means were different.