Animal Crossing Turnip Markets
The goal is to use Bayesian estimation and Kelly strategy to optimally play the AC:NH turnip market.
It is interesting because it is a non-trivial model with some memory. An interesting question will be exploration vs. exploitation. To what extend do we want to take the current offer, versus waiting for more information.
Model
In the reverse engineered source code we find the following model:
Pattern state transition probabilities
\begin{pmatrix} 0.20 & 0.30 & 0.15 & 0.35 \\ 0.50 & 0.05 & 0.20 & 0.25 \\ 0.25 & 0.45 & 0.05 & 0.25 \\ 0.45 & 0.25 & 0.15 & 0.15 \\ \end{pmatrix}
Based on the pattern, one of fo
Bayesian inferencing
Exploitation
In the first week we observe the following values, starting on Thursday AM:
57, 125, 64, 56, 124, 91
Q. Given this information, what is the probability distribution of pattern
?
f(p) = \Prc{\mathtt{pattern} = p}{X_o = x}
This matches pattern zero with declen1 = 3
, hilen1 = 4
, hilen3 = 2
.
Q. Assuming it is indeed that pattern, what is the probability distribution for baseprice
?
\begin{aligned} \Prc{\mathtt{baseprice} = p}{X_o = x} &= \frac{ \Pr{\mathtt{baseprice} = p ∩ X_o = x} }{ \Pr{X_o = x} } \end{aligned}
= \Prc{\mathtt{baseprice} = p}{X_o = x}
\begin{aligned} X_0 &∼ U(90, 110) \\\\ X_1 &∼ U(0.9, 1.4) \\\\ X_2 &= X_0 ⋅ X_1 \end{aligned}
\Pr{\vec X = \vec x} = \Pr{X_0 = x_0} ⋅ \Pr{X_1 = x_1} ⋅ \Prc{X_2 = x_2}{X_0 = x_0 ∧ X_1 = x_1}
https://ermongroup.github.io/cs228-notes/
Given a set of vertices V and a parent function π: V → \powerset{V}
\Pr{\vec X = \vec x} = \prod_V^v \Prc{X_v = x_v}{\vec X_{π(v)} = \vec x_{π(v)}}
p_{\vec X}\p{\vec x} = \prod_V^v p_v\p{x_v, \vec x_{π(v)}}
Questions
Q. How many Turnips should you buy on Sunday?
-
It looks like all prices are scaled by baseprice, so it should only depend on the probability distribution over patterns?
-
We want to maximize the long-term growth.
-
We want to limit risk of ruin.
-
We want to limit
-
We want to take into account income streams.
-
We want to take into account occasional withdrawals.
-
We want to account for imperfect execution when evaluating strategy.
Q. When should you sell the Turnips?
- What is the distribution of payoff?
- When should we sell, and when should we wait for more data?
- Should we sell all at once or spread the sell-off?
- What is the cost of flawed strategy execution?
- What is the cost of false assumptions?