This requires bumping the package version to 2 decimals only.
Preparing for CRAN submission.
nice_normality: breaks.auto argument now uses na.rm = TRUE to support missing values
nice_normality: breaks.auto argument added to allow control of the density plot in this aspect.
nice_density: Switch back to not using the Sturges method per default.
nice_table: Internal change to stay compatible with new flextable version
nice_density: Now uses na.rm = TRUE internally to support data with missing values.
find_mad: New argument mad.scores to return robust zscore (MAD) scores instead of raw scores (now default to TRUE).
nice_density: Now uses the Sturges method to define the optimal number of bins automatically. Also adds two new arguments: breaks.auto = TRUE, if one does not want to use the Sturges method, and bins = 30, to define bins manually, if needed.
cormatrix_excel2: Added a third (sixth) colour for one star significances (* = p < .05), and add an argument for printing the correlation matrix to the console too (or not), print.mat.
nice_na: integrated a feature request to include the number of rows that were all NAs.
New function: cormatrix_excel2: a new version of cormatrix_excel relying on the openxlsx2 package and that allows incorporating significance stars along the correlation matrix, as well as a second sheet containing the matrix of p-values. Experimental until openxlsx2 reaches CRAN.
Fixed nice_randomize as it had been outputting the wrong output format for within-subject designs when moving from plyr to dplyr (+ updated runsheet tutorial).
nice_table: changed back from layout = "fixed" to layout = "autofit" now that flextable fixed the unnecessary line breaks for confidence intervals
cormatrix_excel: corrected values for small, medium, large correlations (from 0.0-0.3: small; 0.3-0.6: medium; 0.6-1.0: large to 0.0-0.2: small; 0.2-0.4: medium; 0.4-1.0: large).
Changed default method of base cor function from “na.or.complete” to the most liberal one to match SPSS: “pairwise.complete.obs”.
Added a use argument to specify which one to use in case a user wants a different option.
Automatized integration with the report package so we don’t have to specify the e.g. report = "lm" argument manually.
Added optional arguments for table title and footnote.
Many functions (based on goodpractice package recommendations):
Changed sapply for lapply since sapply is not recommended and using vapply with list outputs was too complicated.
Shortened line codes to < 80 characters.
Replaced 1:length(…) or 1:nrow(…) by seq_along(…).
nice_na: added scales argument to specify specific scales
New function: nice_NA; nicely reports NA values according to existing guidelines. This function reports both absolute and percentage values of specified column lists.
nice_density and nice_normality: added the possibility to provide no group argument so as to have a plot of all data.
nice_violin: made default contour lines thicker, but also added argument border.size to allow customization.
nice_violin: Corrected a bug whereas the Cohen’s d wasn’t added to the plot if manual annotation (as opposed to automatic) comparisons were made. Also, the default test used in geom_signif::geom_signif() was the Wilcox test. It has been changed to the t-test to avoid confusion when results mismatch. Finally, the contour lines were made thicker since at high resolution they appeared too thin.
New function: format_d to format d values as e.g., 0.30 instead of 0.3 e.g., on violin plots.
nice_violin: Added the ability to add the Cohen’s d to the plot
find_mad: improved reporting of ID and row number
nice_table: changed default table width (again)
nice_table: changed default table width
find_mad: corrected a bug whereas having a dataframe with no outliers in certain situations generated an error
nice_density and nice_normality: added the histogram option to add an histogram to the density plot.
Created an internal ggplot2 APA “theme” to avoid code redundancy across plots
nice_table: greatly improved underlying code: more clarity (dplyr) and less repetition (with added internal functions)
nice_violin: reverted theme to original default (alpha = 1 and black border) from modified theme some time ago (alpha = .70, white border). Users wishing to keep the original style can simply specify these options in their script.
New function: nice_contrasts for planned contrasts (multiple group pairwise comparisons)
find_mad: Now only prints individual variables that do have outliers. However, it now lists all variables checked at the top to avoid possible confusion.
Also reformatted arguments vertically instead of horizontally within functions for clarity (doesn’t affect users or documentation proper).
nice_t_test: Added support for one-sample t-test.
new functions for the median absolute deviation (MAD): find_mad to find outliers based on the MAD, scale_mad to scale (standardize) data based on the MAD, and winsorize_mad to winsorize (bring outliers in +/3 SD) based on the MAD.
nice_table: brought a correction to the automatic 95% CI so that when numbers are rounded to 0, the zeros still show (e.g., 0.20 instead of 0.2).
nice_normality: improved implementation of the title argument
nice_table: added N as italic in header
integration with broom package: moved columns Method and Alternative to beginning for consistency with treatment of the report package.
Fixed appropriate decimals display for degrees of freedom with actual decimals (e.g., for Welch t-test).
nice_t_test: Added optional Bonferroni correction argument (and other corrections if possible). Other corrections to be implemented in the future.
nice_t_test: changed from package effsize to effectsize for effect size because the Cohen’s d value for paired samples wasn’t consistent with other packages.
Integration with report package: combined CI_low and CI_high for method t.test (just like for method lm)
Added an optional short argument to get a more concise table output from the report package integration
Fixed a slight model number mix-up in nice_slopes.
Added support for paired t-tests (only adaptation of Cohen’s d was necessary) and updated documentation to give multiple examples of t-test customization.
Added warning to nice_t_test informing users about the Welch t-test being used per default (through base R t.test’s default) and how to change it. Also added option to turn off this warning.
new function: nice_lm to format any existing lm model object in a proper format for nice_table, including sr2
new function: nice_lm_slopes to format simple slopes for any existing lm model object in a proper format for nice_table, including sr2
nice_mod and nice_slopes:
Added model number when more then one model.
Also added an optional mod.id = TRUE argument, to display the model number, when there is more than one model.
Also reordered default order of rows when there is a second moderator present as it makes more sense to group the same models completely together for different levels of the second moderator.
By combining the row names within the list object rather than in the combined dataframe, we also don’t have to worry about changing names, etc. anymore. Thus it is now cleaner and not missing with variable names.
nice_mod and nice_slopes: Added an argument b.label to rename b, e.g., to capital B if using standardized data for it to be converted to the Greek beta symbol automatically in the nice_table function.
nice_mod and nice_slopes: Corrected a bug whereas having column names with periods would cut off the variable names before the dots because of the automatic correction of the interaction term row names which contain periods as well.
Added a NEWS.md file to track changes to the package.
Improved report package integration with nice_table