Author Archives: aptech

Discrete Choice Analysis Tools v2.0

NEW! Discrete Choice Analysis Tools 2.0

Easier to Use: From input to results, and everything in between!

  • Fast and efficient handling of large data sets
  • Large scale data classification
  • Publication quality formatted results tables with optional exportation
  • Updated implementation for simple data input, parameter control, and estimation
  • New logistic regression modelling for large scale classification including L2/L1 regularized classifiers and L2/ L1-loss linear SVM with cross-validation and prediction
Discrete Choice Analysis Tools 2.0 provides an adaptable, efficient, and user-friendly environment for linear data classification. It's designed with a full suite of tools built to accommodate individual model specificity, including adjustable parameter bounds, linear or nonlinear constraints, default or user specified starting values, and user specified Gradient and Hessian procedures. Newly incorporated data and parameter input procedures make model set-up and implementation intuitive. Discrete Choice Analysis Tool v2.0 is a next generation GAUSS discrete choice analytics tool for:
    -Econometricians and Micro-economists -Political choice researchers -Survey data analysts -Sociologist -Epidemiologists -Insurance, safety and accident analysts ...And more!

Supported Models: Encompasses a large variety of linear classification models:

  • NEW! Large Scale Data Classification: Performs large-scale binary linear classification using support vector machines [SVM] or logistic regression [LR] methodology. Available options include cross-validation of model parameters and prediction plotting. Easy to access output includes estimated prediction weights, predicted classifications and cross-validation accuracy.
  • Adjacent Categories Multinomial Logit Model: The log-odds of one category versus the next higher category is linear in the cutpoints and explanatory variables.
  • Logit and Probit Regression Models: Estimates dichotomous dependent variable with either Normal or extreme value distributions.
  • Conditional Logit Models: Includes both variables that are attributes of the responses as well as, optionally, exogenous variables that are properties of cases.
  • Mutltinomial Logit Model: Qualitative responses are each modeled with a separate set of regression coefficients.
  • Negative Binomial Regression Model (left or right truncated, left or right censored, or zero-inflated): Estimates model with negative binomial distributed dependent variable. This includes censored models - the dependent variable is not observed but independent variables are available - and truncated models where not even the independent variables are observed. Also, a zero-inflated negative binomial model can be estimated where the probability of the zero category is a mixture of a negative binomial consistent probability and an excess probability. The mixture coefficient can be a function of independent variables.
  • Nested Logit Regression Model: Derived from the assumption that residuals have a generalized extreme value distribution and allows for a general pattern of dependence among the responses thus avoiding the IIA problem, i.e., the "independence of irrelevant alternatives."
  • Ordered Logit and Probit Regression Models: Estimates model with an ordered qualitative dependent variable with Normal or extreme value distributions.
  • Possion Regression Model (left or right truncated, left or right censored, or zero-inflated): Estimates model with Poisson distributed dependent variable. This includes censored models - the dependent variable is not observed but independent variables are available - and truncated models where not even the independent variables are observed. Also, a zero-inflated Poisson model can be estimated where the probability of the zero category is a mixture of a Poisson consistent probability and an excess probability. The mixture coefficient can be a function of independent variables.
  • Stereotype Multinomial Logit Model: The coefficients of the regression in each category are linear functions of a reference regression.

Outputs: GAUSS Easy to access, store, and export:

  • NEW! Predicted counts and residuals
  • Parameter estimates
  • Variance-covariance matrix for coefficient estimates
  • Percentages of dependent variables by category (where applicable)
  • Complete data description of all independent variables
  • Marginal effects of independent variables (by category of dependent variable, when applicable)
  • Variance-covariance matrices of marginal effects

Reporting: Performs and reports a number of goodness of fit tests including for model performance analysis:

  • Full model and restricted model log-likelihoods
  • Chi-square statistic
  • Agresti's G-squared statistic
  • Likelihood ratio statistics and accompanying probability values
  • McFadden's Psuedo R-squared
  • McKelvey and Zovcina's Psuedo R-Squared
  • Cragg and Uhler's normed likelihood ratios
  • Count R-Squared
  • Adjusted count R-Squared
  • Akaike and Bayesian information criterions
Platform: Windows, Mac, and Linux Requirements: GAUSS/GAUSS Engine/GAUSS Light v14 or higher

Saving and loading GAUSS matrix files

Saving and loading GAUSS matrix files

GAUSS allows you to read and write data from many different file types such as Excel, ASCII text and database files. All of these file formats have their place, but you should learn to read and write native GAUSS matrix files, because it is very simple and very fast.

Basic saving and loading

Let's start by creating a small matrix and saving it with the GAUSS save command:
//create a 4x2 matrix
x = { 3.2 5.2,
      5.3 6.3,
      2.5 1.5,
      6.3 9.2 };

//save the data in 'x'
//in a GAUSS matrix file
save x;
In its most basic usage, as seen above, the GAUSS save command saves the contents of a GAUSS matrix to a file. The name of the file will be the same as the name of the GAUSS variable, but with a .fmt file extension. In this case, the file will be named x.fmt. Since we did not specify a path location, GAUSS will create this file in the current working directory. We can load the file we created with the load command:
load x;
As you may have guessed, this line of code above will look for a file named x.fmt in the current working directory and assign its contents to a GAUSS global variable called x.

Specifying a different file or variable name

Sometimes you will want the saved matrix file to have a different name than the GAUSS global variable that originally held the data. Continuing with the x from above, we can save it as the file new_var.fmt with the following statement:
save new_var.fmt=x;
Since the file is being assigned to, it is on the left side of the equals sign. The variable, x is the source and is therefore on the right side of the equals sign. When load'ing a matrix file into a GAUSS variable with a different name, the order from above is reversed. Since the GAUSS variable is being assigned to, it is now on the left side of the equals sign. For example:
load new_x=x.fmt;
As in our first examples in this tutorial, we do not have to specify the file extension. We could enter this:
load new_x=x;
However, the file extension is recommended in this case because it makes the code more explicit and thus easier to understand later.

Specifying a different path

To specify a full path in which you would like your data saved (or loaded), you can simply add the path to the file name in our examples from above. For example:
save C:\gauss\myproject\x.fmt=x;
load new_x=C:\gauss\myproject\x.fmt;

Setting the save path and load path

If you have a separate file folder for the data in your project, it would be nice to tell GAUSS the path once rather than on each use of the save and load command. You can do this by setting the save path and the load path.

You set the save path by passing the word path as a flag to the save command. For example:
save path=C:\gauss\myproject;
After executing the command above, all subsequent variables save'd with the save command will be placed in the C:\gauss\myproject directory. So, this code snippet:
save path=C:\gauss\myproject;
save x;
save y;
save z;
would produce the same effect as:
save C:\gauss\myproject\x.fmt=x;
save C:\gauss\myproject\y.fmt=y;
save C:\gauss\myproject\z.fmt=z; 
The load path works in the same way as the save path, by passing the path flag to the load command:
load path=C:\gauss\myproject\mydata;
This sets the location in which the load command will look for matrix files.