Grocer
- Time series
- car2freq — transforms a car into a frequency
- da2m — transformation of daily data into monthly ones
- da2q — transformation of daily data into quarterly ones
- date2fq — finds the frequency associated to a date
- date2num — transforms a date into a number
- date2num_fq — transforms a date into a number and its frequency
- date2num_m — transforms a matrix of dates into numbers
- datelf2hf — transformation of a date into a higher frequency date
- datelf2hf0 — transformation of a date into a higher frequency date
- datets — returns the time span of a ts
- def0_basets — creation of the default frequencies data base
- def_basets — creation of the frequencies data base
- def_dailyform — creation of the data base for the format of daily dates
- delda — differentiates a ts ignoring NA values
- delts — differentiates a ts
- diff_date — returns the difference between 2 dates
- dummy — create a dummy variable
- extrap — extrapolate a ts by another ts
- freq2car — transforms a frequency into a string
- freqts — returns the frequency of a ts
- freqts_c — returns the frequency of a ts in complex form
- growthr — growth rate of a ts
- lagda — lag a ts ignoring NA values
- lagts — lag a ts
- m2a — transforms monthly data into annual ones
- m2q — transforms monthly data into quarterly ones
- num2date — transforms a number into a date
- overlay — overlay several ts
- prtts — print ts
- q2a — transforms quarterly data into annual ones
- reshape — creation of a ts from a vector
- seasdummy — create a seasonal dummy variable
- series — returns the values of a ts
- st_dev — standard deviation of a vector or a ts
- subper — restrict a ts to a subperiod
- ts2vec — transforms a ts into a vector
- values — value of a ts at some date
- var_t — variances of n ts at a given date
- vec2ts — vector to timeseries
- Matrices of Time series
- addts2tsmat — adds a ts to a tsmat
- db2tsmat — Converts a database into a tsmat
- ts2tsmat — Converts time sries into a tsmat
- tsmat2ts — Converts a tsmat into time series
- tsmat_names — Changes how the names of a tsmat are modified after an operation
- Basic functions
- autocum — AR(1) cumulation
- cols — # of columns in a matrix
- com_size — replaces values of matrix x
- commutation — commutation of a matrix
- crlag — circular lag function
- dblist — gives the content of a database
- defaultcoef — finds default coefficients in equations
- detrend — detrend a matrix
- dmult — gauss dmult function
- duplication — Magnus and Neudecker's duplication matrix
- elimination — Magnus and Neudecker's elimination matrix
- expbd2exc — exportation to Excel
- extraptab — extrapolation of statistical tables
- findcoef — find coefficients in an equation
- fuslist — merge vectors of a list
- fusvect — sorted fusion of vectors
- getconfig — Get the name of the O/S
- impexc2bd — importation of a csv excel file
- internet2sci — downlaod a file from Internet
- invpd — mimic Gauss function invpd
- invvech — inverse of vech
- is_empty — check if a variable is empty
- is_scalar — check if a matrix is a scalar
- joinstr — concatenation of strings and strings vectors
- lag — creation of a lagged matrix
- longrun_variance — long run variance of a stationary series
- matdiv — matrix quotient
- matmul — matrix elementwise multiplication
- meanc — mimics gauss function meanc
- miss — converts a specified value to NA
- missrv — converts a NA to a specified value
- mlag — lag of a matrix
- mlag0 — lag of a matrix
- mlagb — lag a matrix
- mvblockboot — Multivariate block-bootstrap
- newey_west — Newey_West variance estimator
- packr — deletes rows of a matrix containing missing values
- polymult — mimics gauss function polymult
- ptrend — matrix of polynomial trend
- readxls2bd — importation of an excel file
- repmat — mimics Matlab function repmat
- reshape_gauss — mimics gauss function reshape
- rev — mimics gauss function rev
- rows — # of rows in a matrix
- sci_unzip — unzip a zipped file
- search_cte — find the indexes of constant colums
- seqa — production of a sequence of values
- shiftr — mimics gauss function shiftr
- sortc — mimics gauss function sortc
- spencer — filters a series with a Spencer filter
- stdc — mimics gauss function stdc
- str2mat — mimics matlab function str2mat
- str2vec — string to vector of strings
- strsubst_trueobj — replace a "true' string by another one in a string
- studentize — studentize a ts, a vector or a matrix
- tdiff — produce matrix differences
- transdif — differenciation and Box-Cox transformation
- trend — exponentiated time trend
- trimr — strip a matrix
- undrift — removes the drift or a linear time trend
- uninstall_grocer — uninstall grocer
- var2cor — covariance to correlation
- varcov0 — covariance matrix
- vec — stacks columns of a matrix
- vec2col — vector into column vector
- vec2row — vector into row vector
- vech — stacks a symmetric matrix
- vech_gauss — mimics gauss function vech
- vecr — stacks rowwise
- xpnd1 — mimics gauss function xpnd
- General Functions for estimation
- bounds — setting estimation bounds
- explolist — splitting of a list
- explon — explosion of several sequences of variables
- explone — explosion of one sequence of variables
- explots — explosion of a list of ts
- explouniv — explosion of a sequence of variables
- explovars — explosion of a sequence of variables
- lagbounds — lag bounds in a regression
- res2ts — result vector object to timeseries
- Optimisation
- hessian — finite symmetric difference Hessiann
- maxlik — maximization function
- numz0 — numerical derivative
- optimg — Grocer optimization function
- Single equation regressions
- ar1_grad — gradient for ols model with AR1 errors
- ar1_like — log-likelihood for ols model with AR1 errors
- define_func2inv — store a list of functions and their inverse
- deming — deming linear estimation
- deming1 — deming linear estimation
- dynfore — Dynamic simulation of an equation
- hwhite — White's adjusted heteroscedastic estimation
- invxpx — inversion of X'X
- iv — instrumental variables
- iv1 — instrumental variables
- lad — least absolute deviations regression
- mcov — White's X'WX
- nls — non linear least squares
- nwest — Estimation with Newey-West correction on standard errors
- nwest1 — Estimation with Newey-West correction on standard errors
- ols — ordinary least squares
- ols0 — ordinary least squares
- ols1 — ordinary least squares
- ols2 — ordinary least squares
- ols2_cons — constrained ordinary least squares
- ols_cons — constrained ordinary least squares
- olsar1 — maximum likelihood estimation of an autocorrelated model
- olsar1_1 — maximum likelihood estimation of an autocorrelated model
- olsarma — ordinary least squares with ARMA errors
- olsarma1 — ordinary least squares with ARMA errors
- olsc — Cochrane-Orcutt estimation of an autocorrelated model
- olsc0 — Cochrane-Orcutt estimation of an autocorrelated model
- olsc1 — Cochrane-Orcutt estimation of an autocorrelated model
- olspec — ordinary least squares with specification tests
- olst — ols with t-distributed errors
- qreg — quantile regression estimation
- qreg1 — quantile regression estimation
- ridge — ridge regression
- robust — robust regression
- rolreg — Compute rolling or recursive out-of-sample prevision
- statfore — static forecast
- theil — Theil-Goldberger mixed estimator
- Econometric tests and diagnostics
- AndPlob — Andrews and Ploberger brekapoint tests
- archz — ARCH test
- archz0 — ARCH test
- arlm — Lagrange multiplier autocorrelation test
- arlm0 — Lagrange multiplier autocorrelation test
- arlm0_multi — LM multivariate test of autocorrelation
- bkw — BKW multicollinearity diagnostic
- bkw_scale — BKW scaled multicollinearity diagnostic
- bkwols — BKW scaled multicollinearity diagnostic
- bpagan — Breusch and Pagan heteroskedasticity test
- bpagan0 — Breusch and Pagan heteroskedasticity test
- chowtest — Chow usual test
- chowtest0 — Chow usual test
- clwest — Approximately normal test proposed by Clark and West (include test of martingal difference hypothesis)
- cusumb — backward cusum stability tests
- cusumf — forward cusum stability tests
- cusumq_tab — cusum squared confidence band
- dchange — Test for directional accuracy
- des_stat — basic statistics
- dfbeta — BKW influential observation diagnostics
- diebmar — Diebold and Mariano test for predictive accuracy
- doornhans — Doornik and Hansen normality test
- doornhans0 — Doornik and Hansen normality test
- hetero_sq — Xi² heteroskedasticity test
- hetero_sq0 — Xi² heteroskedasticity test
- hetero_sq0_multi — LM multivariate test of heteroskedasticity
- jbnorm — Jarque and Bera normality test on the residuals of a regression
- jbnorm0 — Jarque and Bera normality test on the residuals of a regression
- jbnorm_var1 — Jarque and Bera normality test on the residuals of a regression
- li_mcleod — Li McLeod autocorrelation test
- ljungbox — Ljung-Box autocorrelation test
- predfail — out of sample predictive failure test
- predfailin — Chow predictive failure test
- predfailin0 — Chow predictive failure test
- recresid — recursive residuals
- reliability — reliability of the coefficients in a regression
- reset — Ramsey RESET test
- reset0 — Ramsey RESET test
- waldchi — Wald F-test
- waldf — Wald F-test
- waldf0 — Wald F-test
- white — White's heteroskedasticity test
- white0 — White's heteroskedasticity test
- Unit roots and cointegration
- adf — adf unit root test
- cadf — ADF statistic for residuals from a cointegrating regression
- critecm — critical values and p-values for the error correction test
- ers — Elliott-Rothenberg-Stock unit root test
- kpss — KPSS unit root test
- olsecm — Error correction test for cointegration
- phil_perr — Phillips-Perron unit-root test
- rztcrit — critical values for the cadf Zt statistic
- schmiphi — computes Schmidt-Phillips test
- schmiphi_tab — critical values for the Schmidt-Phillips statistic
- Johansen cointegration mmethod
- Multivariate regressions
- eq2xcol — Transformation of a system of equations into a matrix vector
- eqlist — recovers objects names in an equation
- exploeqs — Transformation of 2sls or 3sls equations
- explosys — Transformation of sur equations
- sur — Zellner Seemingly Unrelated Regression
- syslist — recovers objects names in a system of equations
- threesls — Three-Stage Least-squares Regression
- twosls — Two-Stage Least-squares Regression
- VAR estimations
- Hetero_TVP_VAR — Time varying structural VAR
- Hetero_TVP_VAR1 — Time varying structural VAR
- Hetero_TVP_VAR_irf — IRF for a Time varying structural VAR
- Hetero_TVP_VAR_stdresid — standard deviations of residuals for a Time varying structural VAR
- VAR — estimates a VAR model
- becm — performs bayesian error correction model estimation
- bvar — performs bayesian VAR estimation
- bvar1 — low level estimation of a bayesian VAR model
- ecm — performs error correction model estimation
- irf — Calculates Impulse Response Function for VAR
- irf0 — Low-level Impulse Response function
- irf_asy — asymptotic Impulse Response function for VAR
- irf_mc1 — Monte-Carlo Impulse Response function for VAR
- rolirf — Calculates Impulse Response Function for rolling VAR
- rolvar — computes rolling VAR
- rolvar_granger — Granger (non-)causality tests for a rolling VAR
- scstd — determines bvar function scaling factor
- theilbv — Performs Theil-Goldberger for theilbv model
- tvp_var_diagnos — computes MCMC convergence diagnostics for TVP VAR
- tvp_var_diagnos_all — computes MCMC convergence diagnostics for all TVP VAR parmaeters
- tvp_var_diagnos_hyperp — computes MCMC convergence diagnostics for TVP VAR hyperparameters
- tvpvar_prior0 — returns prior tlist needed by Hetero_TVP_VAR function
- var1 — estimates a VAR model (low level)
- vare — residuals from a VAR estimation
- varf — VAR forecasting
- vargranger — Granger (non-)causality tests from a VAR
- varwithfac — estimation of a VAR models with exogenous factors
- ARMA and VARMA tools
- acf — autocorrelation function
- arma2param — explodes a Varmax model for estimation uses
- arma_dv — Computes the partial derivatives in a VARMA model
- mak — centered moving average for a matrix
- makts — centered moving average for a time series
- maok — k-periods uncentered moving average for a matrix
- maokts — k-periods uncentered moving average for a time series
- pacf — Partial autocorrelation function
- theta2arm2 — transformation of VARMA estimate into the corresponding matrices
- theta2arma — transformation of VARMA model into its reduced form
- transf_roots — reverses roots lower than 1 in a L polynom
- varma — estimation of a (V)ARMA(X) model
- varmaf — forecasts from a VARMA model
- GARCH models
- Automatic estimation
- auto_test — build specification tests function and vector of names
- automatic — automatic general to specific regression
- automatic_signed — automatic general to specific regression with sign constraints on coefficients
- autovar2var — transforms VAR taken from Automatic estimation into a standard VAR
- test_spec0 — five specification tests
- test_varspec0 — three default specification tests for VAR estimation
- Kalman filter estimation
- filter — Kalman filter
- filter_like — Kalman filter log-likelihood
- kalman — Kalman filter estimation
- smoothing — Kalman smoother
- tvp — Time varying parameters estimation
- tvp_param1 — transformation of tvp parameters into kalman compatible ones
- tvp_param1a — transformation of tvp parameters into kalman compatible ones
- tvp_param1ad — transformation of tvp parameters into kalman compatible ones
- tvp_param1d — transformation of tvp parameters into kalman compatible ones
- tvp_param2 — transformation of tvp parameters into kalman compatible ones
- tvp_param2a — transformation of tvp parameters into kalman compatible ones
- tvp_param2ad — transformation of tvp parameters into kalman compatible ones
- Supplementary distibution functions
- Business cycle tools
- agf — autocovariance generating function
- banerji — performs banerji test to evaluate the leading profile of a series against another one
- bkfilter — Baxter-King filter
- brybos — Bry-Boshan turning points datation
- cffilter — Christiano-Fitzgrald filter
- define_recession — define the location of peaks and troughs
- hpfilter — Hodrick Prescott filter
- hpofilter — Hodrick Prescott one-sided filter
- spectral — non parametric spectral analysis of time series
- specvarma — compute parametric spectral analysis of time series
- Contributions
- balance_identity — Balances an identity numerically approximatively true
- contrib — contribution of an exogenous variable
- contrib_logq2gra — contributions to an annual growth rate
- mainf — Infinite Moving average representation
- Panel equation regressions
- cdtest — Panel cross-sectional dependence test
- cdtest_he0 — Panel cross-sectional dependence test
- cdtest_lmadj_he0 — Panel cross-sectional dependence test for heterogeneous panels
- cdtest_lmadj_ho0 — Panel cross-sectional dependence test
- movblockboot — Moving-block bootstrap
- paneldb — Construct a tlist in grocer panel format
- panelfit — Compute fitted value implied by panel estimation
- pbetween — between Estimation for Panel Data
- pbetween1 — between Estimation for Panel Data
- pcce — Common correlated effects estimators
- pccemg1 — Mean group common correlated effects estimator
- pccep1 — Pooled common correlated effects estimator
- pdccemg1 — Mean group common correlated effects estimator for dynamic models
- pdccemg_jkn1 — Mean group common correlated effects estimator with half-panel jackknife correction for dynamic models
- pfixed — Panel equation regressions
- pfixed1 — Random Effects Estimation for Panel Data
- pfixed_hac1 — Panel equation regressions
- pfixed_mbb1 — Panel equation regressions
- phaussman — Haussman test on panel estimations
- ppooled — Panel equation regressions
- ppooled1 — Pooled Estimation for Panel Data
- ppooled_hac1 — Panel equation regressions
- prandom — Random Effects Estimation for Panel Data
- prandom1 — Random Effects Estimation for Panel Data
- Panel unit root tests
- ADF_Individual — ADF Unit Root Tests on Individual Time Series
- BNG_ur — Bai and Ng Panel Unit Root Test
- BNG_ur1 — Bai and Ng Panel Unit Root Test
- Chang_IV — Chang Panel Unit Root Test
- Chang_IV1 — Chang Panel Unit Root Test
- Choi — Choi Panel Unit Root Test
- Choi1 — Choi Panel Unit Root Test
- IPS — Im, Pesaran and Shin Panel Unit Root Test
- IPS1 — Im, Pesaran and Shin Panel Unit Root Test
- Levin_Lin — Levin and Lin Panel Unit Root Test
- Levin_Lin1 — Levin and Lin Panel Unit Root Test
- Maddala_Wu — Maddala and Wu Panel Unit Root Test
- Maddala_Wu1 — Maddala and Wu Panel Unit Root Test
- Moon_Perron — Moon and Perron Panel Unit Root Test
- Moon_Perron1 — Moon and Perron Panel Unit Root Test
- Pesaran — Pesaran Panel Unit Root Test
- Pesaran1 — Pesaran Panel Unit Root Test
- Time series disaggregation
- chowlin — Temporal disaggregation using the Chow-Lin method
- chowlin1 — Temporal disaggregation using the Chow-Lin method
- aggreg1 — Generates a temporal aggregation matrix
- bfl — Temporal disaggregation using the Boot-Feibes-Lisman method
- bfl1 — Temporal disaggregation using the Boot-Feibes-Lisman method
- denton — Multivariate temporal disaggregation with transversal constraint
- denton1 — Multivariate temporal disaggregation with transversal constraint
- difonzo — Multivariate temporal disaggregation with transversal constraint
- difonzo1 — Multivariate temporal disaggregation with transversal constraint
- etalcalinsee — Disaggregation using Insee's method
- fernandez — Temporal disaggregation using the Fernandez method
- fernandez1 — Temporal disaggregation using the Fernandez method
- litterman — Temporal disaggregation using the Litterman method
- litterman1 — Temporal disaggregation using the Litterman method
- Markov-switching models
- cod_kern — divides data into quantiles with a kernel method
- ms_estimate — Markvov Switching regression model
- ms_forecast — forecast from a Markvov Switching regression model
- ms_mean — Markov Switching mean-variance model
- ms_mean_oos — run out-of-sample a MS-mean
- ms_quali — Estimates a ms turning point model
- ms_reg — Markvov Switching regression model
- ms_reg_oos — run out-of-sample a MS regression
- ms_var — Markov Switching VAR model
- ms_var_oos — run out-of-sample a MSVAR
- msvar_draw — simulate an artifical MS-VAR process
- msvar_irf — impulse response functions (irf) for a Markov-switching VAR model
- msvar_irf_cb — msvar irf with confidence bands
- MSVAR_stderr — Markvov Switching 2nd order moments
- Bayesian Model Averaging
- DMA — Dynamic model averaging
- DMA1 — Dynamic model averaging
- bintodec — During each BMA step, convert "base 2" models codification into bits
- bma_g — Bayesian model averaging
- bma_g1 — Bayesian model averaging
- bmapost_g — Evaluate log marginal posterior of a BMA model
- densbma_g — Print the posterior density function of estimated coefficients by BMA method
- find_new — Determine if the selected variables in a BMA step represent a new model
- jump_g — MCMC with reversible jump to sample variables for changing model size in BMA
- mc3_g — MCMC model composition to sample variables for changing model size in BMA
- Generalized Method of Moments
- gmm — Generalized Method of Moments
- gmm1 — Generalized Method of Moments
- gmmAndMon — Andrews-Monahan HAC estimators
- gmmCcapmJ — Gradients of moment condition for power utility CCAPM example
- gmmCcapmM — Moments condition for power utility CCAPM example
- gmmDiagW — Plots GMM weighting matrix
- gmmDtest — performs D test of model comparaison for GMM
- gmmLM — LM test for GMM
- gmmLinJ — Jacobian of moment conditions for linear GMM estimation
- gmmLinM — Provide moment conditions for linear GMM estimation
- gmmLsFunc — GMM objective function
- gmmLsGrad — GMM gradients of the objective function
- gmmMomtRestr — Performs test of moment restriction
- gmmMsdJ — Jacobian for Mean/StdDev GMM estimation
- gmmMsdM — Provide moment conditions for Mean/StdDev GMM estimation
- gmmNlWald — Wald test for GMM with nonlinear restrictions
- gmmRdef — Computes the value for the restrictions in a nonlinear Wald test
- gmmS — Spectral density matrix in GMM
- gmmWald — Wald test
- Factor Analysis
- fac_kalman — dynamic factor analysis with the Kalman filter
- fac_pca — Static factor analysis
- fac_pca1 — Static factor analysis
- Qualitative Econometrics Functions
- logit — logit regression
- multilogit — multivariate logit regression
- multilogit1 — multivariate logit regression
- ologit — multivariate ordered logit regression
- ologit1 — multivariate ordered logit regression
- oprobit — multivariate ordered probit regression
- oprobit1 — multivariate ordered probit regression
- probit — probit regression
- tobit — Tobit estimation
- Gauss to Scilab translation
- Symbolic Analysis
- add_derivative — add a derivative to the list of analytic ones
- analyse_eq — breaks down an equation into elementary bricks
- deriv_eq — derivate an equation decomposed in a tlist
- rebuild_eq — build an equation from an analytic tlist
- Printings and graphs
- dealyna — splits y series containing NAs
- drawx — draw a readable x axis
- drawy — draw a readable y axis
- fan_chart — draws a fan-chart
- font_title — changes the font of the title
- histg — plots as an histogram a probability distribution function
- histo_ts — plots series with bars as in Excel
- mat2latex — LaTex matrix or LaTex table representation of a scilab matrix
- mpltseries — multiple 2d plot in one page
- ndigits — Rounds all elements of a matrix to the desired number of decimals
- param_g — determines the font parameters
- plt_cusum — plots the results of the cusum test
- plt_dfb — plots dfbetas
- plt_dff — plots dffits, studentized residuals ...
- pltacf — plots partial autocorrelation fonction
- pltdensbma_g — plots the posterior density function of coefficients in a BMA regression
- pltfac_kalm — plots the residuals of an ARMA estimation
- pltirf1 — plots impulse functions
- pltirf2 — plots impulse functions
- pltms_prob — plots smoothed or filtered probabilities of a Markov switching regression
- pltms_quali — plots smoothed or filtered probabilities of a qualtitative turning point estimation
- pltms_resid — plots residuals from a Markov switching regression
- pltms_yyhat — plots the raw and adjusted series from a Markov switching regression
- pltseries — 2d plot
- pltseries0 — 2d plot
- plttvp — plots tvp results
- pltuniv — plots univariate results
- pltvarma — plots the residuals of an ARMA estimation
- printmat — prints a matrix
- printsep — prints a separator
- prt_test — prints the results of specification tests embodied in a tlist results
- prtauto — prints automatic() results
- prtauto_multi — prints some automatic() results
- prtauto_univ — prints some automatic() results
- prtbma_g — prints Bayesian Model Averaging results
- prtcdtest — Display of the Panel cross-sectional dependence test
- prtchi — prints a Chi2 test
- prtdiebmar — prints the result from the Diebold-Mariano test
- prtdisag — prints the results of a time series disaggregation
- prtfac_kalm — prints fac_kalm estimation results
- prtfac_acp — prints static factor estimation results
- prtfish — prints a Fisher test
- prtgmm — prints gmm estimation results
- prthaussman — prints the results of a panel Haussman test
- prtjohan — prints Johansen cointegration results
- prtjohvec — prints Johansen cointegration vectors
- prtms — prints Markov switching regression results
- prtms_quali — prints the results of a HMM estimation based upon qualitative data
- prtres — prints any regression results
- prtsys — prints sur estimation results
- prttvp — prints tvp estimation results
- prtunitr — prints unit root estimation results
- prtuniv — prints univariate estimation results
- prtvar — prints VAR estimation results
- prtvarf — prints VAR or VARMA forecast results
- prtvarma — plots partial autocorrelation fonction
- yscale — determines y scale