gemmr.pearson_sample_size

gemmr.pearson_sample_size(rs=(0.1, 0.3, 0.5), criterion='power', target_power=0.9, alpha=0.05)

Calculate required sample sizes for accurate estimation of Pearson correlation.

Parameters:
  • rs (tuple-like of floats between 0 and 1) – power is calculated for these assumed true correlations

  • criterion (str) – must be ‘power’

  • target_power (float between 0 and 1) – target power

  • alpha (float between 0 and 1) – type 1 error rate

Returns:

sample_sizes – gives the required sample size for each assumed true correlation

Return type:

dict {r: sample_size}

References

Cohen (1988), Statistical power analysis for the behavioral sciences