Learn R Programming

Cultural evolution in R

The cultevo R package provides tools, measures and statistical tests often used in the study of cultural evolution, in particular for measuring the compositionality of signalling systems as well as computing string and meaning distance matrices. It also provides an accurate implementation of Page's test for monotonicity of ranks.

See the Function reference for a full list of functions.

Installation

In order to install the latest development version you first need the devtools package

install.packages("devtools")

then install the latest code from the github repository via

devtools::install_github("kevinstadler/cultevo")

Citation

This package can be cited as:

Stadler, Kevin (2018) cultevo: Tools, Measures and Statistical Tests for Cultural Evolution. R package version 1.0.2. https://kevinstadler.github.io/cultevo/

A BibTeX entry for LaTeX users is

  @Manual{cultevo,
    title = {cultevo: Tools, Measures and Statistical Tests for Cultural Evolution},
    author = {Kevin Stadler},
    year = {2018},
    note = {R package version 1.0.2},
    url = {https://kevinstadler.github.io/cultevo/}
  }

License

This project is licensed under the terms of the MIT license, Copyright (c) 2014-2018 Kevin Stadler.

Copy Link

Version

Install

install.packages('cultevo')

Monthly Downloads

228

Version

1.0.2

License

MIT + file LICENSE

Maintainer

Kevin Stadler

Last Published

April 24th, 2018

Functions in cultevo (1.0.2)

count.substring.occurrences

Count occurences of all possible substrings in one more strings.
normalisedlevenshteindists

Compute the normalised Levenshtein distances between strings.
read.dist

Read a distance matrix from a file or data frame.
repmatrix

Extend a matrix by repetition of elements.
binaryfeaturematrix

Convert a meaning matrix to a binary 'meaning-feature-present' matrix.
check.dist

Check or fix a distance matrix.
orderinsensitivedists

Calculate the bag-of-characters similarity between strings.
page.test

Page test for monotonicity of ranks.
sm.compositionality

Spike's segmentation and measure of additive compositionality.
enumerate.substrings

Enumerate all substrings of a string.
ssm.compositionality

Find a segmentation that maximises the overall string coverage across all signals.
hammingdists

Pairwise Hamming distances between matrix rows.
temperature.colors

Create a vector of 'temperature' colors (from blue over white to red).
wrap.meaningdistfunction

Make a meaning distance function vectorisable.
enumerate.meaningcombinations

Enumerate meaning combinations.
segment.string

Split strings into their constituent segments.
shuffle.locations

Permute the rows and columns of a square matrix.
mantel.test

Perform one or more Mantel permutation tests.