Analysis Scripts

On this page, I have links to a handful of scripts that I have written that might make your life easier. Many of these scripts are linked elsewhere on this website, but I wanted to make them all easier to find. All scripts on this page are completely free for you to use however you want. Below are links / brief descriptions of each script.


If you are doing the Meaning Extraction Method, you can use the “binary”, “verbose”, or “raw count” outputs for your Principal Component Analysis. I have written an R script for running the PCA, which you are free to use — the script is located here.


The “raw count” document term matrix is something that you can use to run Latent Dirichlet Allocation, in addition to other types of analyses. If you are new to LDA, or you simply need an R script that makes LDA easy to use with MEH’s raw count output, I have written one that you may freely use. It can be downloaded here.


If you would like to get texts from your spreadsheets into separate .txt files prior to analysis with MEH, I have made a few different scripts available at https://github.com/ryanboyd/CSVtoTXTscripts. With some modifications, you can do things like aggregate your texts into specific files, etc. — essentially, aggregating texts as you desire prior to analysis with MEH.


If you want to compare word frequencies / likelihoods from 2 different corpora, I have written a script that calculates all of the same same indices that are found on Paul Rayson’s extremely helpful page. Essentially, you can get 2 separate frequency lists from MEH (1 for each corpus), then apply this script.