Closed A-Lounsbury closed 3 months ago
This test
krmodel = [ [ [[2, 12], [5, 6], [9, 0]], [[0, 24], [19, 5], [10, 10]], [[1, 3], [7, 5], [5, 25]], ] ] G = SimGame(2) G.enterData(2, [3, 3], krmodel) G.print() print() G.printBestResponses()
outputs
2, 12 5, 6 9, 0 0, 24 19, 5 10, 10 1, 3 7, 5 5, 25 1, 1 0, 0 0, 0 0, 1 1, 0 1, 1 0, 0 0, 0 0, 1
Expected output is
2, 12 5, 6 9, 0 0, 24 19, 5 10, 10 1, 3 7, 5 5, 25 1, 1 0, 0 0, 0 0, 1 1, 0 1, 0 0, 0 0, 0 0, 1
Fixed. Was accessing self.payoffMatrix[0][profile[1]][j].getListNode(1).payoff instead of self.payoffMatrix[0][profile[0]][j].getListNode(1).payoff.
self.payoffMatrix[0][profile[1]][j].getListNode(1).payoff
self.payoffMatrix[0][profile[0]][j].getListNode(1).payoff
This test
outputs
Expected output is