TLinearModel.jac()

statsmodels.miscmodels.tmodel.TLinearModel.jac TLinearModel.jac(*args, **kwds) jac is deprecated, use score_obs instead! Use score_obs method. jac will be removed in 0.7. Jacobian/Gradient of log-likelihood evaluated at params for each observation.

TLinearModel.initialize()

statsmodels.miscmodels.tmodel.TLinearModel.initialize TLinearModel.initialize() [source]

TLinearModel.information()

statsmodels.miscmodels.tmodel.TLinearModel.information TLinearModel.information(params) Fisher information matrix of model Returns -Hessian of loglike evaluated at params.

TLinearModel.hessian()

statsmodels.miscmodels.tmodel.TLinearModel.hessian TLinearModel.hessian(params) Hessian of log-likelihood evaluated at params

TLinearModel.from_formula()

statsmodels.miscmodels.tmodel.TLinearModel.from_formula classmethod TLinearModel.from_formula(formula, data, subset=None, *args, **kwargs) Create a Model from a formula and dataframe. Parameters: formula : str or generic Formula object The formula specifying the model data : array-like The data for the model. See Notes. subset : array-like An array-like object of booleans, integers, or index values that indicate the subset of df to use in the model. Assumes df is a pandas.DataFrame ar

TLinearModel.fit()

statsmodels.miscmodels.tmodel.TLinearModel.fit TLinearModel.fit(start_params=None, method='nm', maxiter=500, full_output=1, disp=1, callback=None, retall=0, **kwargs) Fit the model using maximum likelihood. The rest of the docstring is from statsmodels.LikelihoodModel.fit

TLinearModel.expandparams()

statsmodels.miscmodels.tmodel.TLinearModel.expandparams TLinearModel.expandparams(params) expand to full parameter array when some parameters are fixed Parameters: params : array reduced parameter array Returns: paramsfull : array expanded parameter array where fixed parameters are included Notes Calling this requires that self.fixed_params and self.fixed_paramsmask are defined. developer notes: This can be used in the log-likelihood to ... this could also be replaced by a more gener

Time Series Filters

Time Series Filters Link to Notebook GitHub In [1]: from __future__ import print_function import pandas as pd import matplotlib.pyplot as plt import statsmodels.api as sm In [2]: dta = sm.datasets.macrodata.load_pandas().data In [3]: index = pd.Index(sm.tsa.datetools.dates_from_range('1959Q1', '2009Q3')) print(index) <class 'pandas.tseries.index.DatetimeIndex'> [1959-03-31, ..., 2009-09-30] Length: 203, Freq: None, Timezone: None In [4]:

Time Series analysis tsa

Time Series analysis tsa statsmodels.tsa contains model classes and functions that are useful for time series analysis. This currently includes univariate autoregressive models (AR), vector autoregressive models (VAR) and univariate autoregressive moving average models (ARMA). It also includes descriptive statistics for time series, for example autocorrelation, partial autocorrelation function and periodogram, as well as the corresponding theoretical properties of ARMA or related processes. It

SUR.whiten()

statsmodels.sandbox.sysreg.SUR.whiten SUR.whiten(X) [source] SUR whiten method. Parameters: X : list of arrays Data to be whitened. Returns: If X is the exogenous RHS of the system. : ``np.dot(np.kron(cholsigmainv,np.eye(M)),np.diag(X))`` : If X is the endogenous LHS of the system. :