Optimal Sample Size Before a Directional Bet

Expectation · Hard · Free problem

An asset's one-step return is $R \sim N(\mu, \sigma^2)$ where $\mu$ is unknown and $\sigma^2$ is known. Before placing a trade, you choose a position $w \in \{-1, 0, +1\}$ (short, flat, or long) with payoff $wR$.

Before choosing $w$, you may pay a cost $c$ per signal to observe $n$ i.i.d. signals $Y_1, \ldots, Y_n$ where $Y_i \sim N(\mu, \tau^2)$ (noise level $\tau^2$ is known). You then pick $w$ based on the sample mean $\bar{Y}_n$. To keep things symmetric, take $\mu = +\delta$ or $\mu = -\delta$ with equal probability, for a known $\delta > 0$.

  1. Given that you have sampled $n$ signals, derive the optimal decision rule for $w$.
  2. Compute the expected profit from sampling $n$ signals, net of the cost $nc$.
  3. Find the optimal sample size $n^{*}(c)$ that maximizes net expected profit.
  4. Find the threshold $c^{*}$ below which sampling at all is worthwhile.

Hints

  1. Given $n$ signals, your best estimate of $\mu$ is $\bar{Y}_n$. The optimal position is simply to bet in the direction of your estimate: $w^{*} = \text{sign}(\bar{Y}_n)$.
  2. The gross expected profit from $n$ signals (under a symmetric prior) is $G(n) = \delta(2\Phi(\delta\sqrt{n}/\tau) - 1)$. This increases in $n$ but with diminishing returns since $\Phi$ flattens out. Net profit is $G(n) - nc$.
  3. To find the optimal $n$, take the derivative of $\Pi(n) = G(n) - nc$ and set it to zero: $G'(n) = c$. The derivative involves the normal PDF $\phi$ and gives a transcendental equation in $n$ that must be solved numerically. For the threshold $c^{*}$, do NOT use $G'(0)$ -- that derivative diverges. Compare the whole first signal against staying flat instead: $c^{*} = G(1)$.

Worked Solution

How to Think About It: You are deciding whether to pay for information before making a directional bet. Without any signals, you know nothing about $\mu$ -- you have no basis to go long or short, so you stay flat ($w = 0$) and earn zero. With signals, you estimate $\mu$ from $\bar{Y}_n$ and bet in the direction of the estimate. The value of sampling is the expected improvement in payoff from having this estimate. You are essentially buying a signal and asking: how many observations are worth it at cost $c$ each?

Quick intuition: more signals reduce the estimation noise on $\mu$. But the marginal value of the $n$-th signal is decreasing (you already know roughly what $\mu$ is). So the optimal $n$ balances information gain against cost -- a classic diminishing returns problem.

Quick Estimate: Take $\delta = \tau = 1$ and $c = 0.05$. With $n = 4$ signals the standard error of $\bar{Y}_n$ is $\tau/\sqrt{n} = 0.5$, so you call the sign correctly with probability $\Phi(2) \approx 0.977$: gross value $\approx 1 \times (2(0.977) - 1) = 0.95$ against a cost of $4 \times 0.05 = 0.20$, netting about $0.75$. Push to $n = 16$ and the gross value only creeps up to $\approx 1.00$ while the cost quadruples to $0.80$, netting $0.20$. The gross value saturates at $\delta$ almost immediately while the cost grows linearly, so the optimum is small -- a handful of signals, not dozens.

Formal Solution:

Part 1 -- Optimal decision rule.

Given $\bar{Y}_n$, choose $w$ to maximize $E[wR \mid \bar{Y}_n] = w \, E[\mu \mid \bar{Y}_n]$, using that $R$ is independent of the signals once $\mu$ is fixed. This is linear in $w$, so the optimum sits at an endpoint of $\{-1, 0, +1\}$ -- there is never a reason to stay flat once you have looked.

Under the symmetric two-point prior, the posterior odds on $\mu = +\delta$ against $\mu = -\delta$ are $\exp(2n\delta\bar{Y}_n/\tau^2)$, which exceed 1 exactly when $\bar{Y}_n > 0$. So $E[\mu \mid \bar{Y}_n]$ carries the sign of $\bar{Y}_n$, and:

$$w^{*} = \text{sign}(\bar{Y}_n) = \begin{cases} +1 & \text{if } \bar{Y}_n > 0 \\ 0 & \text{if } \bar{Y}_n = 0 \\ -1 & \text{if } \bar{Y}_n < 0 \end{cases}$$

Part 2 -- Expected profit from $n$ signals.

With $w^{*} = \text{sign}(\bar{Y}_n)$, the payoff is $\text{sign}(\bar{Y}_n) \cdot R$. Take expectations:

$$E[\text{sign}(\bar{Y}_n) \cdot R] = E\left[ E[\text{sign}(\bar{Y}_n) \cdot R \mid \mu] \right]$$

For fixed $\mu$: $\bar{Y}_n \sim N(\mu, \tau^2/n)$ and $R \sim N(\mu, \sigma^2)$, independent of $\bar{Y}_n$ given $\mu$. So:

$$E[\text{sign}(\bar{Y}_n) \cdot R \mid \mu] = \mu \cdot E[\text{sign}(\bar{Y}_n) \mid \mu] = \mu \cdot P(\bar{Y}_n > 0 \mid \mu) - \mu \cdot P(\bar{Y}_n < 0 \mid \mu)$$ $$= \mu \cdot (2\Phi(\mu\sqrt{n}/\tau) - 1)$$

Now average over the two branches of the prior. At $\mu = +\delta$ this is $\delta(2\Phi(\delta\sqrt{n}/\tau) - 1)$; at $\mu = -\delta$ it is $-\delta(2\Phi(-\delta\sqrt{n}/\tau) - 1)$, which equals the same thing. The two branches agree, so the gross expected profit is

$$G(n) = \delta \cdot (2\Phi(\delta\sqrt{n}/\tau) - 1)$$

Read it directly: you make $+\delta$ whenever $\bar{Y}_n$ has the same sign as $\mu$, which happens with probability $\Phi(\delta\sqrt{n}/\tau)$, and $-\delta$ otherwise.

Net expected profit: $$\Pi(n) = G(n) - nc = \delta(2\Phi(\delta\sqrt{n}/\tau) - 1) - nc$$

Part 3 -- Optimal sample size.

Treat $n$ as continuous. Take the first-order condition $\partial \Pi / \partial n = 0$:

$$\frac{\partial G}{\partial n} = c$$

$$\delta \cdot 2\phi(\delta\sqrt{n}/\tau) \cdot \frac{\delta}{2\tau\sqrt{n}} = c$$

$$\frac{\delta^2}{\tau\sqrt{n}} \phi\!\left(\frac{\delta\sqrt{n}}{\tau}\right) = c$$

where $\phi$ is the standard normal PDF. Let $z = \delta\sqrt{n}/\tau$ (so $\sqrt{n} = z\tau/\delta$); then the condition becomes:

$$\frac{\delta^3}{\tau^2} \cdot \frac{\phi(z)}{z} = c$$

The equation $z^{-1}\phi(z) = c\tau^2/\delta^3$ must be solved numerically for $z^{*}$, giving: $$n^{*} = \left(\frac{z^{*} \tau}{\delta}\right)^2$$

For small $c$ (cheap signals), $z^{*}$ is large (many signals); for large $c$, $z^{*}$ is small.

**Part 4 -- Threshold $c^{*}$.**

Sampling at all is worthwhile if some $n \ge 1$ gives $\Pi(n) > 0$. Compare the first signal against staying flat: flat earns $0$, while one signal earns gross $G(1) = \delta(2\Phi(\delta/\tau) - 1)$ at cost $c$. So a single signal beats staying flat iff:

$$\Pi(1) = \delta\left(2\Phi\!\left(\frac{\delta}{\tau}\right) - 1\right) - c > 0$$

Moreover, $G$ is concave in $n$ with $G(0) = 0$ (its derivative $\delta^2 \phi(\delta\sqrt{n}/\tau)/(\tau\sqrt{n})$ is strictly decreasing in $n$), so $G(n)/n$ is decreasing and $G(n) \le n\,G(1)$ for $n \ge 1$. Hence $\Pi(n) \le n(G(1) - c)$: if the first signal is not worth buying, no larger sample is either. The exact threshold is therefore:

$$c^{*} = \delta\left(2\Phi\!\left(\frac{\delta}{\tau}\right) - 1\right)$$

If $c > c^{*}$, stay flat: even the first (most valuable) signal does not justify its cost.

*Pitfall:* evaluating a "marginal value of sampling at $n = 0$" as $\frac{\delta^2}{\tau}\phi(0) = \frac{\delta^2}{\tau\sqrt{2\pi}}$ is invalid -- the true derivative $\partial G/\partial n = \delta^2 \phi(\delta\sqrt{n}/\tau)/(\tau\sqrt{n})$ diverges like $1/\sqrt{n}$ as $n \to 0^{+}$, so there is no finite marginal value at zero and the threshold cannot be obtained that way.

Answer: 1. Optimal rule: $w^{*} = \text{sign}(\bar{Y}_n)$. 2. Net profit: $\Pi(n) = \delta(2\Phi(\delta\sqrt{n}/\tau) - 1) - nc$ under a symmetric two-point prior. 3. Optimal $n^{*}$: solve $\delta^2 \phi(\delta\sqrt{n}/\tau)/(\tau\sqrt{n}) = c$ numerically. 4. Threshold: $c^{*} = \delta(2\Phi(\delta/\tau) - 1)$ -- the gross value of a single signal; only sample if $c < c^{*}$.

Intuition

This problem is a value-of-information (VOI) calculation. The core trade-off is universal: information reduces uncertainty and improves decisions, but collecting information has a cost. The optimal stopping point is where the marginal value of one more signal equals its marginal cost. That the marginal value is decreasing (more signals help less once you already have a good estimate) is what makes the problem have a finite solution.

In real trading, this maps directly to research budget allocation. How many days of alternative data should you buy to calibrate a signal? How many parameter samples in a Monte Carlo do you need before the estimate is good enough to trade on? The answer is always: until the marginal cost of one more observation equals the marginal improvement in expected P&L from better accuracy. The $c^{*}$ threshold is particularly useful -- it tells you which data sources are worth looking at at all, before you worry about how much to buy.

Open the full interactive solver →