Public Member Functions | Static Public Attributes

biogeme::BIOGEME_OBJECT Class Reference

This class gathers the components needed by biogeme to perform the estimation or the simulation. More...

List of all members.

Public Member Functions

def __init__
def __once__

Static Public Attributes

 ESTIMATE = None
 Expression of the likelihood function to be maximized.
 SIMULATE = None
 Enumerate expression to perform sample enumeration.
 EXCLUDE = None
 Expression identifying the observations to be ignored in the data file.
 WEIGHT = None
 Expression computing the weight of each observation, for WESML.
 VARCOVAR = None
 Not implemented.
dictionary STATISTICS = {}
 Dictionary of expressions computing statistics on the data.
dictionary CONSTRAINTS = {}
 Dictionary of expressions defining constraints on the parameters to be estimated.
dictionary PARAMETERS = {}
 Obsolete.

Detailed Description

This class gathers the components needed by biogeme to perform the estimation or the simulation.


Constructor & Destructor Documentation

def biogeme::BIOGEME_OBJECT::__init__ (   self )

Member Function Documentation

def biogeme::BIOGEME_OBJECT::__once__ (   self )

Member Data Documentation

dictionary biogeme::BIOGEME_OBJECT::CONSTRAINTS = {} [static]

Dictionary of expressions defining constraints on the parameters to be estimated.

In general, it is preferable not to use these constraints. There is most of the time a way to write the model with unconstrained parameters. The two typical examples are:

  • Constrain a parameter beta to be nonnegative: replace it by the exponential of another parameter.
  • A set of parameters b1, b2, ... bn must sum up to one. Replace them by their normalized version: bi = ci / (c1 + c2 + ... + cn), where c1, ... cn are unconstrained parameters to be estimated.
  • A combination of the two gives bi = exp(ci) / (exp(c1) + exp(c2) + ... + exp(cn))

Expression of the likelihood function to be maximized.

Example:

 BIOGEME_OBJECT.ESTIMATE = Sum(log(prob),'obsIter') 

Expression identifying the observations to be ignored in the data file.

Example:

 BIOGEME_OBJECT.EXCLUDE = (TRAVEL_TIME < 0)
dictionary biogeme::BIOGEME_OBJECT::PARAMETERS = {} [static]

Obsolete.

Enumerate expression to perform sample enumeration.

Example:

 simulate = Enumerate('Choice prob.', prob)
 BIOGEME_OBJECT.SIMULATE = Enumerate(simulate,'obsIter') 
dictionary biogeme::BIOGEME_OBJECT::STATISTICS = {} [static]

Dictionary of expressions computing statistics on the data.

The index of each entry is associated with the value in the report. Example calculating the null loglikelihood of a choice model:

    total = 0 
    for i,a in availability.items() :
        total += (a != 0)
    nl = -Sum(log(total),iterator)
    BIOGEME_OBJECT.STATISTICS['Null loglikelihood'] = nl

Not implemented.

Expression computing the weight of each observation, for WESML.

Typically, a variable in the data file. Example:

 BIOGEME_OBJECT.WEIGHT = weight 

The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables