Team A on average scores 2.1 goals/match, Team B on average scores 1.6 goals/match. Using R simulate 1000 realisations of the match and estimate the probability of team A winning, team B winning and the probability of a tie.
So far I have found 1000 simulations for how many goals each team would score in each mach using:
queueA = rpois(lambda=2.1, n=1000) & queueB = rpois(lambda=1.6, n=1000)
But am having problems marrying up the scores for each game and thus finding the required probabilities.
Hint: If you have two vectors
queueAandqueueBin $\texttt{R}$, try typingThat should return the number of elements in
queueAthat are greater than the corresponding element inqueueB. You can use this to find the number of games where A beat B.