Broadly Useful Convenient and Efficient R Functions


[Up] [Top]

Documentation for package ‘bruceR’ version 2024.6

Help Pages

bruceR-package bruceR: *BR*oadly *U*seful *C*onvenient and *E*fficient *R* functions
%%COMPUTE%% Multivariate computation.
%allin% A simple extension of '%in%'.
%anyin% A simple extension of '%in%'.
%nonein% A simple extension of '%in%'.
%notin% The opposite of '%in%'.
%partin% A simple extension of '%in%'.
%^% Paste strings together.
.mean Multivariate computation.
.sum Multivariate computation.
add Create, modify, and delete variables.
added Create, modify, and delete variables.
Alpha Reliability analysis (Cronbach's alpha and McDonald's omega).
bruceR bruceR: *BR*oadly *U*seful *C*onvenient and *E*fficient *R* functions
cc Split up a string (with separators) into a character vector.
ccf_plot Cross-correlation analysis.
CFA Confirmatory Factor Analysis (CFA).
CONSEC Multivariate computation.
Corr Correlation analysis.
cor_diff Test the difference between two correlations.
cor_multilevel Multilevel correlations (within-level and between-level).
COUNT Multivariate computation.
Describe Descriptive statistics.
dtime Timer (compute time difference).
EFA Principal Component Analysis (PCA) and Exploratory Factor analysis (EFA).
EMMEANS Simple-effect analysis and post-hoc multiple comparison.
export Export data to a file (TXT, CSV, Excel, SPSS, Stata, ...) or clipboard.
formatF Format numeric values.
formatN Format "1234" to "1,234".
formula_expand Expand all interaction terms in a formula.
formula_paste Paste a formula into a string.
Freq Frequency statistics.
GLM_summary Tidy report of GLM ('lm' and 'glm' models).
Glue Print strings with rich formats and colors.
grand_mean_center Grand-mean centering.
granger_causality Granger causality test (multivariate).
granger_test Granger causality test (bivariate).
group_mean_center Group-mean centering.
HLM_ICC_rWG Tidy report of HLM indices: ICC(1), ICC(2), and rWG/rWG(J).
HLM_summary Tidy report of HLM ('lmer' and 'glmer' models).
import Import data from a file (TXT, CSV, Excel, SPSS, Stata, ...) or clipboard.
lavaan_summary Tidy report of lavaan model.
LOOKUP Search, match, and look up values (like Excel's functions 'INDEX + MATCH').
MANOVA Multi-factor ANOVA.
MEAN Multivariate computation.
med_summary Tidy report of mediation analysis.
MODE Multivariate computation.
model_summary Tidy report of regression models.
p Compute _p_ value.
p.chi2 Compute _p_ value.
p.f Compute _p_ value.
p.r Compute _p_ value.
p.t Compute _p_ value.
p.z Compute _p_ value.
PCA Principal Component Analysis (PCA) and Exploratory Factor analysis (EFA).
pkg_depend Check dependencies of R packages.
pkg_install_suggested Install suggested R packages.
Print Print strings with rich formats and colors.
print_table Print a three-line table (to R Console and Microsoft Word).
PROCESS PROCESS for mediation and/or moderation analyses.
RECODE Recode a variable.
regress Regression analysis.
rep_char Repeat a character string for many times and paste them up.
RESCALE Rescale a variable (e.g., from 5-point to 7-point).
RGB A simple extension of 'rgb()'.
Run Run code parsed from text.
scaler Min-max scaling (min-max normalization).
set.wd Set working directory to the path of currently opened file.
set_wd Set working directory to the path of currently opened file.
show_colors Show colors.
STD Multivariate computation.
SUM Multivariate computation.
theme_bruce A nice 'ggplot2' theme that enables Markdown/HTML rich text.
TTEST One-sample, independent-samples, and paired-samples t-test.