pyblp.ProblemResults.compute_elasticities

ProblemResults.compute_elasticities(name='prices')

Estimate matrices of elasticities of demand, \(\varepsilon\), with respect to a variable, \(x\).

For each market, the value in row \(j\) and column \(k\) of \(\varepsilon\) is

(1)\[\varepsilon_{jk} = \frac{x_k}{s_j}\frac{\partial s_j}{\partial x_k}.\]
Parameters

name (str, optional) – Name of the variable, \(x\). By default, \(x = p\), prices.

Returns

Stacked \(J_t \times J_t\) estimated matrices of elasticities of demand, \(\varepsilon\), for each market \(t\). Columns for a market are in the same order as products for the market. If a market has fewer products than others, extra columns will contain numpy.nan.

Return type

ndarray

Examples