filmov
tv
Design Matrices using Patsy in Python

Показать описание
The files for this tutorial will be made available on GitHub soon.
In this video tutorial I discuss the preparation of tabular data for use in statistical python packages such as statsmodels. The patsy package is ideal for creating design matrices that can be used in statsmodels.
Design matrices in models include the dependent vector and the matrix of independent variables. Functions in patsy can generate these from tabular data. The patsy package can also preprocess the data. It can, for instance, generate design matrices with interaction terms, add new variables to a feature matrix, transform the values of a variable, and many other such transformation.