Data
dat
- id (string)
- pet (string)
- time (string)
- y (float): Happiness Score
dat <- read.csv('data/dat_data.tsv', sep='\t')
Analysis 1: A1
scienceverse::t_test(y ~ pet, dat)
#>
#> Welch Two Sample t-test
#>
#> data: y by pet
#> t = -0.3, df = 117, p-value = 0.7
#> alternative hypothesis: true difference in means is not equal to 0
#> 95 percent confidence interval:
#> -2.19 1.57
#> sample estimates:
#> mean in group cat mean in group dog
#> 8.62 8.93
Stored Results
- statistic:
0.3234
- parameter:
117.3873
- p.value:
0.747
- conf.int:
-1.5737
2.1881
- estimate:
8.9267
8.6195
- null.value:
0
- stderr:
0.9498
- alternative:
two.sided
- method:
Welch Two Sample t-test
- data.name:
y by pet
- n:
60
60
Analysis 2: A2
scienceverse::t_test(y ~ time, dat)
#>
#> Welch Two Sample t-test
#>
#> data: y by time
#> t = -0.5, df = 118, p-value = 0.6
#> alternative hypothesis: true difference in means is not equal to 0
#> 95 percent confidence interval:
#> -2.37 1.39
#> sample estimates:
#> mean in group morning mean in group night
#> 8.53 9.02
Stored Results
- statistic:
-0.5117
- parameter:
117.5653
- p.value:
0.6098
- conf.int:
-2.3653
1.3939
- estimate:
8.5302
9.0159
- null.value:
0
- stderr:
0.9491
- alternative:
two.sided
- method:
Welch Two Sample t-test
- data.name:
y by time
- n:
60
60