View Single Post
  #199  
Old 12-25-2015, 03:54 PM
Raev Raev is offline
Planar Protector


Join Date: Sep 2014
Posts: 2,290
Default

Quote:
Originally Posted by quido [You must be logged in to view images. Log in or Register.]
However shitty I am it's not as shitty as trying to compute the variance among a set of three non-numeric values.
Statistics works just fine in the discrete case. The spore king is a classic multinomial distribution: each random variable (a dead spore king) is one of N (3) possibilities. The variance is one (although, not a particularly enlightening one) estimation of how varied the resulting sets of items can be. A multinomial distribution has a covariance matrix where:
  • The diagonal entries X[i,i] have value n * p_i * (1- p_i), the same as the binomial distribution.
  • The covariance entries X[i,j] have value - n * p_i * p_j, with the variance being negative because the more of one kind you get, the less you get of the others.

If you don't believe me, feel free to check wikipedia. Anyway, to compute the covariance matrix X we first estimate the drop rates:

Code:
find . -name *.txt  | xargs grep "looted a Fungus Covered Scale Tunic" 2>/dev/null  | wc -l
35
find . -name *.txt  | xargs grep "looted a Fungi Covered Great Staff" 2>/dev/null  | wc -l
3
find . -name *.txt  | xargs grep "looted a Robe of Living Fungus" 2>/dev/null  | wc -l
18
That's 56 spore king kills, with a 5.3% chance of a staff, 32.1% chance of a robe, and a 62.5% chance of a tunic. Since I highly doubt Nilbog enters values to the 1/10 of a percent, I'm rounding to {Staff: 5%, Robe: 30%, Tunic: 65%}.

Letting n = 1 for simplicity, and ordering the outcomes as {tunic, robe, staff} gives X = {{0.2275, -0.195, -0.0325}, {-0.195, .21, -.015}, {-0.0325, -0.15, .0475}}. .2275 is the variance of the tunic as I mentioned earlier.

Quote:
Originally Posted by quido [You must be logged in to view images. Log in or Register.]
Raev, if you can just compute the variance I will give you a million plat and acknowledge your infinite superiority. Show me the number. Inquiring minds want to know.
Ball's in your court pal!