Consistency of values generated with a Poisson inverse function and random numbers in Python I have a Python file that simulates 10 000 hypothetical soccer matches between two teams. This is done by generating two sets of 10 000 random numbers between 0 to 1 (10 000 for each team). This is then passed through a Poisson inverse function for each team, which uses the expected goals per team for the match (a value that considers expected goals scored and received per match), to calculate goals per team for each one of the 10 000 matches. I then count the percentage of wins, ties and losses, which will vary depending on the teams considered and their expected goals per match.
I have noticed that if I run this code for a particular team playing against itself, or two teams that have the exact same number of expected goals for a match against each other, the percentage of wins, ties and losses is not consistent, within a margin of error of about 2 %. Roughly speaking, I have not calculated this. This means that a team will for example win against itself 38 % of the time and lose against itself 37 % of the time. I would expect the same percentage of wins/losses for the same team agsinst itself. The discrepancy is in the counts, and is not explained by rounding up the percentages. I am trying to get a better understanding of what is going on, to take this into consideration in the code. Does this have to do with the way Python generates random numbers? Or is there an intrinsic aspect of the Poisson inverse that causes this?  In any case, what could be going on here? I have the feeling that there is a very simple explanation that I am overseeing.

If you are surprised that a large proportion of your simulation runs have an absolute difference between wins and losses of more than $50$ games i.e. more than $\pm 0.5\%$ of the $10000$ games simulated, you should not be. This may happen about $56\%$ of the time.
Suppose the probability of a win against your clone was $37.5\%$, and similarly the probability of a loss was also $37.5\%$, and a draw $25\%$, then in a single game the probability of win-loss being $+1$ is $0.375$ and being $-1$ is $0.375$ and being $0$ is $0.25$.  This distribution has mean $0$ and variance $0.75$.
Take $10000$ i.i.d. simulations and the total wins-losses has mean $0$ and variance $7500$, i.e. a standard deviation of $\sqrt{7500} \approx 86.6$. As a proportion of the $10000$ games, that standard deviation is $0.00866$ or $0.866\%$.
So seeing a simulated difference betweens wins and losses in a range of $\pm200$ games or $\pm 2\%$ of the games is more or less what you might expect: it is about $\pm 2.3$ standard deviations from the mean, and you might expect about $98\%$ of your simulation runs to fall inside this interval.
