Learn R Programming

SportsAnalytics (version 0.2)

herfindahl: Concentration indices

Description

This is a proof-of-concept implementation of concentration measures for data with an exogenous order.

Usage

herfindahl(x)
rosenbluth(x)
exogeny(x, ex = order(x))

Arguments

x
Data vector
ex
Order of the data vector

Value

The concenctration index.

See Also

Other concentration: concentration_ratio

Examples

Run this code
## See demo("concentration-bundesliga") for a real-world
## application.

set.seed(1234)
x <- sample(100000, 10)

## Classical concentration indices:
herfindahl(x)
rosenbluth(x)

## Exogenous order is available:
o <- sample(10)
exogeny(x, o)

Run the code above in your browser using DataLab