E_num {eddington} | R Documentation |
Gets the Eddington number for cycling. The Eddington Number for cycling, E, is the maximum number where a cyclist has ridden E miles in E days.
E_num(rides)
rides |
A vector of mileage, where each element represents a single day. |
The Eddington Number for cycling is related to computing the rank of an integer partition, which is the same as computing the side length of its Durfee square. Another relevant application of this metric is computing the Hirsch index for publications.
This is not to be confused with the
Eddington Number in
astrophysics, N_{Edd}
, which represents the number of protons in the
observable universe.
An integer which is the Eddington cycling number for the data provided.
# Randomly generate a set of 15 rides
rides <- rgamma(15, shape = 2, scale = 10)
# View the rides sorted in decreasing order
setNames(sort(rides, decreasing = TRUE), seq_along(rides))
# Get the Eddington number
E_num(rides)