Report on diamond prices

Test the hypothesis that the average price of diamonds in the available data is larger than $4500 after filtering out the cheapest diamonds (< $1000)

result <- single_mean(
  diamonds, 
  var = "price", 
  comp_value = 4500, 
  alternative = "greater", 
  data_filter = "price >= 1000"
)
summary(result)
Single mean test
Data      : diamonds 
Filter    : price >= 1000 
Variable  : price 
Confidence: 0.95 
Null hyp. : the mean of price = 4500 
Alt. hyp. : the mean of price is > 4500 

      mean        sd     n n_missing
 5,100.963 4,028.164 2,186         0

    diff     se t.value p.value   df      5% 100%    
 600.963 86.155   6.975  < .001 2185 4959.19  Inf ***

Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
plot(result, plots = c("hist", "simulate"))