I get a bit confused about different definitions of entropy and/or self-information.
Entropy?
$$ H(X) = - \sum_{x \in X} P_X(x) \cdot \log{\left(P_X(x)\right)} $$
Self-information?
$$ I(x) = - \log{P_X(x)} $$ $$ I(X) = - \sum_{x \in X} \log{\left(P_X(x)\right)} $$
When do I use which formulate to calculate what? Generally, I am interested in the average information content of a text. Here I would calculate the frequency of each word, the probability, sum up the negative logarithm of this probability and average it by the number of words.
What am I missing here?