Learn R Programming

discursive (version 0.1.1)

oe_shannon: Compute Shannon entropy

Description

Internal function to compute Shannon entropy in relative word counts across a set of elements in a character vecotr. Entropy is re-scaled to range from 0 to 1. Function used in discursive_range().

Usage

oe_shannon(x)

Value

Numeric vector with the same length as x.

Arguments

x

Character vector containing open-ended responses.