danse / exmargination

Extract information from margin files
Other
0 stars 0 forks source link

How to measure fragmentation? #4

Open danse opened 7 years ago

danse commented 7 years ago

Could fragmentation be measured by calculating the median, for example in the collection and tornado visualisations, rather than the mean?

danse commented 7 years ago
Prelude Data.List Safe> let median a = at (sort a) (div (length a) 2)
Prelude Data.List Safe> median [1, 1, 1, 1, 3, 3]
1
danse commented 7 years ago

The true difference is the interval where the index is calculated. Even the mean would help, but i need to consider the mean within every interval, rather than the mean between different intervals

danse commented 7 years ago

So this would be a different monoid instance of a data point, where append calculates something like the mean, rather than the sum

danse commented 7 years ago

It would be cool to calculate this on the frontend first, in order to get an intuitive understanding about how it works. See danse/crumbs#17