Changelog
Source:NEWS.md
inferr 0.3.3
Bug Fixes
-
ifr_cochran_qtest()now maps each factor by its own declared level order, accepting factors with different labels and using explicit numeric evidence to resolve the shared coding of numeric columns. -
ifr_cochran_qtest()now resolves the shared numeric0/1or1/2coding before incomplete rows are dropped, so a homogeneous numeric column of all1s follows numeric evidence or consistent factor-label hints, and ambiguous mixtures error instead of being silently misread. -
ifr_os_prop_test()now requires the null probability to be strictly inside(0, 1), because the normal approximation is undefined atprob = 0orprob = 1. -
ifr_runs_test()now computes its p-value from the upper normal tail, so small representable p-values are no longer returned as zero. -
ifr_os_t_test()now detects essentially constant data relative to the mean, so a change of units no longer changes whether the t statistic can be estimated, and numerically degenerate data are rejected. -
ifr_cochran_qtest()now keeps the declared levels of a binary factor, so a homogeneous factor column is accepted when the pairs are discordant elsewhere. -
ifr_runs_test()andifr_cochran_qtest()now report a clear error when the number of runs has zero variance or the data contain no within-subject discordance, instead of returningNaN. -
ifr_mcnemar_test()now computes both chi-square p-values from the upper tail, so small representable p-values are no longer returned as zero. -
ifr_ts_prop_group()now defines one success level before tabulating the groups, so character, logical and 0/1 outcomes work when a group contains only successes or only failures. -
ifr_binom_calc(),ifr_binom_test(),ifr_os_prop_test(),ifr_os_t_test(),ifr_runs_test()andifr_cochran_qtest()now reject invalid counts, probabilities, sample sizes and degenerate samples instead of returning plausible-looking values. The runs and Cochran tests remove incomplete observations with a documented, consistent policy. -
ifr_cochran_qtest()now computes its p-value from the upper tail, so small representable p-values are no longer returned as zero. -
ifr_ts_ind_ttest()now drops unused grouping levels after removing incomplete cases, so a factor that declares a third level does not reject data with two observed groups. -
ifr_os_prop_test()andifr_chisq_assoc_test()now compute p-values from unrounded z and chi-square statistics, so the reported decimals match the statistical reference. -
ifr_os_var_test()now reports the correct confidence interval for the standard deviation. -
ifr_ts_ind_ttest()now uses t quantiles, rather than normal quantiles, for the confidence interval of the mean difference and reports both the pooled and Satterthwaite intervals. -
ifr_cochran_qtest()now recodes logical, 0/1, 1/2 and two-level factor columns to 0/1, and rejects other inputs. -
ifr_oneway_anova()now drops incomplete cases and computes the test statistics from unrounded sums of squares; the printed table shows the p-value instead of0and keeps it within theSig.column. -
ifr_chisq_assoc_test()no longer returnsNaNfor the likelihood ratio statistic when a contingency table contains an empty cell. -
ifr_chisq_gof_test()applies Yates correction only whencorrect = TRUE. -
ifr_os_t_test()andifr_ts_ind_ttest()now compute p-values and confidence intervals from unrounded statistics. -
ifr_levene_test()now works with a character grouping variable and reports the correct number of observations and denominator degrees of freedom when the data contain missing values. -
ifr_ts_var_test()now works with a character grouping variable and requires exactly two groups. -
ifr_ts_prop_test(),ifr_ts_prop_group()andifr_os_prop_test()now reject variables that are not binary. -
ifr_ts_paired_ttest()now drops incomplete pairs instead of failing. -
ifr_os_t_test(),ifr_ts_ind_ttest()andifr_os_var_test()now drop missing values instead of failing. -
ifr_mcnemar_test()now requires a 2 x 2 table when variables are supplied. -
ifr_runs_test()now reports the number of cases remaining afterdrop = TRUE. -
ifr_chisq_assoc_test()now returnsNAfor the phi coefficient when the table is not 2 x 2. - The two-sample proportion test output now labels the two-sided p-value as
Pr(|Z| > |z|). - Missing suggested packages now produce an informative error message.
- The documentation for
ifr_ts_var_test()now lists the acceptedalternativevalues, and the README example runs again. -
ifr_binom_test()andifr_binom_calc()now return and print the two-sided exact p-value, computed with the same rule asstats::binom.test(). -
ifr_binom_test()now returns an object of classifr_binom_test(which also inherits fromifr_binom_calc), as documented. - The binomial test documentation now states that the success is the second factor level.
-
ifr_ts_var_test()now returns the documented two-sided p-value. -
ifr_ts_prop_group()andifr_ts_prop_calc()now compute all p-values from the unrounded z statistic. -
ifr_ts_paired_ttest()now computes p-values and the confidence interval of the mean difference from the unrounded t statistic and standard deviation. -
ifr_binom_test(),ifr_os_prop_test(),ifr_ts_prop_test(),ifr_ts_prop_group()andifr_chisq_gof_test()no longer count missing categorical values as failures or scale expected counts by missing observations. -
ifr_mcnemar_test()caps the exact p-value at 1, bounds the continuity correction at zero, and defines the no-discordant-pairs case. -
ifr_chisq_assoc_test()andifr_chisq_gof_test()bound the continuity correction at zero; the goodness-of-fit deviation and standardized residual use the signed bounded correction. -
ifr_ts_paired_ttest()computes the correlation p-value from the unrounded correlation and the upper tail, so it no longer exceeds 1 for negative correlations. -
ifr_levene_test()no longer interchanges Levene’s mean-centred statistic with Brown and Forsythe’s median-centred statistic. -
ifr_ts_ind_ttest()reports the pooled standard deviation usingn1 + n2 - 2in the denominator. -
ifr_oneway_anova()handles singleton groups, rejects designs without residual degrees of freedom, and uses the upper tail for the p-value so representable p-values are not returned as zero. -
ifr_oneway_anova()andifr_ts_ind_ttest()work when the data contain columns namedxory. -
ifr_ts_var_test()requires exactly two columns, or exactly one outcome column withgroup_var, and validates the groups retained after missing values are removed.
Other changes
- The README and pkgdown site were regenerated, so their printed results and version match the released package.
- The binomial and runs test documentation now use the correct replacement function name, describe
obs_pas observed, and describe the runs threshold correctly. -
library(inferr)no longer contacts CRAN or offers to update packages when the package is attached. - The maintainer email is now
aravindhebbali@rsquaredacademy.com. - The documented source of the
examdata now points to a stable page.
inferr 0.3.1
CRAN release: 2021-05-28
This is a patch release to fix error on R-devel on Debian and Fedora.
inferr 0.3.0
CRAN release: 2018-02-13
This is a minor release for bug fixes and API changes. We have completely revamped the API. All the functions now take a data.frame or tibble as the first argument followed by the variable names. The variable names need not be surrounded by single/double quotes anymore. Please view the guide for more details.
inferr 0.1.1
CRAN release: 2017-05-02
Bug Fixes
-
binom_test()accepts non-binary variables (#1). -
ind_ttest()should throw an error when the grouping variable has more than 2 levels (#2). -
ts_prop_test()should accept only binary variables (#3). -
var_test()should accept only binary variables for thegroup_varinput. The number of continuous variables must also not exceed two. (#4).