Skip to content

kthorstmann/horst

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

73 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

horst-package

This is a collection of functions used by me and my colleagues in Pschological Diagnostics at Humboldt-University of Berlin.

Until now, there are only very few functions and most of them are tailored to a specific problem, relying on input from specific functions from other packages (see respective help-pages).

Note: Dependencies need to be installed and loaded manually!

  • corHist A histogram of correlations on level-1 and level-2.
  • omegaW A function to compute Omega's W.
  • simpsonCor A plot that allows discovering the Simpsons Paradox.
  • getTable A function that produces a correlation table in Excel which is close enough to an APA correlation table for further editing.
  • matchItems Based on the psych package, this function adds items from a codebook to the result of an efa.
  • plotMod Plots an interaction on three dimensions, one being coloured dots.
  • renameCodebook Using a codebook (for example from excel), function changes names in a data set according to the codebook.
  • findMis finds missing data (or other entries that can be specified) in any given data set.
  • vlookup An immplementation of the VLOOKUP function from Excel.
  • lmerSimple A function to run lmer-models from character strings.
  • lmerPlottt A function to plot t-values of fixed effects from lmer-models
  • tStats A function to extract t-statistics (t, df, p) from a t.test to plot it, use it in word or latex.
  • withinFun Apply a function to each entry in a nested data frame, i. e. compute the mean of a measurement for each subject in a longitudinal study.
  • nestedAlpha A function to compute alpha for nested scales, for example in multilevel data.
  • valid_recode Recodes values according to a predefined vector of elements into 1 and 0 (useful for recoding values of an knowledge test with open questions).
  • sort_mod Get sorted modification indices from lavaan.
  • lav_fit Get fitmeasures from lavaan objects as ready text.
  • modus Get the modus of a variable.
  • make_bold Format entries in a data frame such that they will be displayed as bold in Markdown.

Installing the package:

Run the following code lines:

install.packages("devtools")
library(devtools)
devtools::install_github("kthorstmann/horst")

About

A small r package with functions used by me and some of my colleagues at HU Berlin

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages