Description Usage Arguments Examples
Function for plotting utilities for games in which two players can each choose a strategy from a continuous action space. Best responses function or correspondence are plotted and Nash equilibria identified. sequence from s1 to s2
1 2 3 4 5 6 7 8 9 10 11 12 13 14 | gt_brcplot(n.grid = 100, s1 = 0.01, s2 = 0.99, a1 = seq(s1, s2, length =
n.grid), a2 = a1, u1 = function(a1, a2) { (a1 - a2)^2 },
u2 = function(a1, a2) { -u1(a1, a2) }, nash = TRUE,
starfill = "pink", tips = 8, nashborder = "black", markbr = FALSE,
starfill2 = "red", radius = dist(range(a1))/30, border = NA,
tol = 0.001, type = "surface", player = 1, cont = FALSE,
screen = list(z = -245, x = -75), clevels = 10, brtype = "l",
brcex1 = 0.5, brcex2 = 0.4, brpch = 21, brlwd = 1, BRI = FALSE,
pch1 = 1, pch2 = 21, col1 = "turquoise", col1br = "red",
col1v = "black", col2 = "grey", col2br = "red", col2v = "black",
colbg1br = "white", colbg2br = "white", canvascolor = "white",
xlab = expression(a[1]), ylab = expression(a[2]), zlab = "U",
toptitle = paste("best response plot"), surface_br_pointtype = "l",
at_axis = c(0, 0.5, 1), boxit = TRUE)
|
u1 |
Player 1's utility |
u2 |
Player 2's utility |
1 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.