t.test(carb ~ am, data = mtcars, var.equal = TRUE)
#>
#> Two Sample t-test
#>
#> data: carb by am
#> t = -0.31565, df = 30, p-value = 0.7545
#> alternative hypothesis: true difference in means between group 0 and group 1 is not equal to 0
#> 95 percent confidence interval:
#> -1.391178 1.018709
#> sample estimates:
#> mean in group 0 mean in group 1
#> 2.736842 2.923077