bertrand_calibrate: Bertrand model calibration

View source: R/bertrand_calibrate.R

bertrand_calibrateR Documentation

Bertrand model calibration

Description

Bertrand model calibration

Usage

bertrand_calibrate(
  param,
  own,
  price,
  shares,
  cost,
  weight = NA,
  returnOutcomes = FALSE
)

Arguments

param

Price coefficient alpha parameter to calibrate

own

Ownership matrix

price

Price

shares

Observed market shares

cost

Marginal costs for each product

weight

Weighting vector of length equal to number of margins provided

returnOutcomes

logical; should equilibrium objects be returned (mean value parameter, prices, shares, costs) as a list.

Details

This function calculate the first-order conditions from a Bertrand price-setting model of competition. This function is only for standard logit demand. For nested logit or generalized nested logit, see bertrand_calibrate_gnl().

Value

Distance between observed values and model predicted values for prices and shares

Examples

alpha  <- -0.9
delta <- c(.81,.93,.82)
c_j <- c(.05,.31,.30)

own_pre = diag(3)

p0 <- c_j*1.1

share1 <- (exp(delta + alpha*p0))/(1+sum(exp(delta + alpha*p0)))
x00 <- c(-1)
wt_vector <- c(1,1,1)

bertrand_calibrate( param = x00,
                    own = own_pre, price = p0,
                    shares = share1, cost  = c_j,
                    weight = wt_vector)


mergersim documentation built on July 21, 2026, 5:09 p.m.