Many of the capabilities of RATS are made available through the use of procedures. Procedures are text files of RATS instructions which function much like a builtin instruction, but with greater flexibility. Consider, for instance, a DickeyFuller test. This is just a simple linear regression with a specific set of variables. A augmented DickeyFuller test with lags chosen by some means requires a set of linear regressions. There is no great advantage to having this "hardcoded" into a RATS instruction (like LINREG itself) since the calculation is quite straightforward. The advantage of providing the DF test through a procedure is that it's easy to modify either by you, or by us.
RATS ships with over 300 procedures, with more created all the time. Because procedures are so important to the use of RATS, it's important for the program to be able to find the most current versions. RATS maintains a set of search directories. This is generally set up properly when you first install the program, but you can change the directory, or add additional ones for your own procedures.
If you execute a procedure with (say)
@dfunit lgdp
RATS will automatically search for a file whose name matches that of the procedure, with a .SRC extension, so in this case dfunit.src. The search path(s) are set in the program's preferences in the Procedures Directories field on the Directories tab. If you have more than one directory listed, it will start with the first, then, if it's not found, move to the next. By putting your own directory above the standard one, you can use an altered copy before the distribution one.
The most important of the procedures are listed in this section alphabetically. For other procedures (or even for the ones shown here), you can open the .SRC file and read the comments to see how they work.
Generates ArellanoBond set of instruments 

Performs autocorrelation analysis on a series 

Computes autocorrelations from partial autocorrelations 

Selects optimal lag length to be used for an ADF test 

AndersonDarling test for normality 

AndrewsGuggenberger estimate of fractional difference 

AndrewsPloberger Structural Break Test 

AndrewsPloberger Structural Break Test for GARCH/Maximum Likelihood 

Computes Information Criteria for AR models using YuleWalker or Burg 

Tests a series for ARCH effects 

Sets up a DLM based upon an ARMA model 

Graphs the spectral density for an input ARMA model 

Estimates factors in a factor model using BaiNg formulas 

BaiPerron Test for Multiple Structural Changes 

Bayesian Unit Root test 

Battery of independence tests 

BrockDecherScheinkman test for i.i.d. 

Computes parameters required for beta distribution 

Hinich bicorrelations test for autocorrelation 

Automated ARIMA model selection 

Aids in selection of differencing operations 

@BJEST 
Estimates an ARIMA model 
Estimates and forecasts an ARIMA model 

BoxJenkins identification tool 

@BJTHEIL 
Computes Theil U statistics for an ARIMA model 
Aids in selection of preliminary transformation 

Band pass filter using BaxterKing method 

BeveridgeNelson decomposition 

Does BreuschPagan (and related) tests for random effects 

Does Monte Carlo draws from a VAR with BQ factorization 

Breitung test for unit roots in panel data 

BryBoschan business cycle dating (PaganHarding for quarterly data) 

BlackScholes option pricing procedure 

@CANCORR 
Computes canonical correlations for two sets of series 
Identifying turning points and cyclical phases of a series 

Band pass filter using ChristianoFitzgerald method 

ChowDenning multiple variance ratio test 

@CHOWLIN 
Distributes a series to a higher frequency using related series (obsolete: use @DISAGGREGATE instead) 
Decomposes a series into trend, seasonal, irregular 

Conditional forecasting procedure 

Corrado nonparametric event test 

@CORRINTEGRAL 
Computes a correlation integral for a series 
Computes and graphs cross correlations of two series 

Computes and graphs phase and coherence 

Complex series symmetrizer 

Durbin’s Cumulated Periodogram for serial correlation 

Computes and displays CUSUM and CUSUMQ tests 

Stability tests on a covariance matrix of series 

@CXLOGDENSITY 
Computes Whittle likelihood using complex matrices 
@CXLOGDENSITYCV 
Computes concentrated multivariate Whittle likelihood using complex matrices 
@DENTON 
Distributes a series to a higher frequency using proportional Denton method (obsolete: use @DISAGGREGATE instead) 
DickeyFuller unit root test 

General disaggregation (interpolation/distribution) procedure 

Distribution from one frequency to a higher frequency 

Computes a Divisia index 

Impulse Reponse Function from a StateSpace model 

DieboldMariano Forecast Comparison Test 

Computes Autoregression Representations using DurbinLevinson recursion 

@EBA 
Extreme Bounds Analysis, from Granger and Uhlig 
@EGCRTVAL 
Computes "exact" critical values for DickeyFuller unit root and EngleGranger cointegration tests. 
EngleGranger test for Cointegration 

EngleGranger test for Cointegration on 1st stage residuals 

Computes empirical likelihood for a set of moment conditions 

Enders/Granger threshold unit root tests 

EndersSiklos test for cointegration with threshold effect 

Creates an ACF from an ARMA equation 

ElliottRothenbergStock unit root tests 

Computes exact (limit) inverse with “infinite” components 

General Nyblom fluctuations test 

Estimates cointegrating vectors using Fully Modified Least Squares 

Factors covariance matrix with specific vector column/row 

Computes and graphs the gain and phase of a pair of series 

Computes parameters required for gamma distribution 

@GARCHFORE 
Univariate GARCH forecasting procedure 
Generates weights and grid points for GaussHermite numerical integration 

@GEDDRAW 
Generates draws for a generalized error distribution 
@GENCOMBOS 
Generate all combinations of a set of integers 
Local to unity GLS detrending routine 

Automated ARIMA model selection (seasonal models) 

GrangerNewbold forecast comparison test 

GewekePorterHudak estimate of fractional differencing 

@GRAPHMATRIX 
Graphs a RECTANGULAR array of series on separate graphs 
GregoryHansen test for Cointegration with breaks 

Generates a series with an equally spaced grid 

Hadri test for unit roots in panel data 

Generates Halton sequences 

@HANNANRISSANEN 
Estimates an ARIMA model using the HannanRissanen algorithm 
Performs a HEGY seasonal unit root test for quarterly data 

@HILLGEV 
Estimates tail index for a distribution using Hill’s method 
@HINICHTEST 
Hinich bispectrum test for linearity and Gaussianity 
Histogram procedure 

@HJBOUNDS 
Computes HansenJagannathan bounds for a set of returns 
HodrickPrescott filter (obsolete) 

HarrisTzavalis unit root test for panel data 

Computes a Hurst exponent 

InclanTiao test for breaks in variance 

@IMHOF 
Computes CDF for quadratic form in Normal(0,1) variables 
Interpolation from one frequency to a higher one 

Computes parameters required for inverse chisquared distribution 

Computes parameters required for inverse gamma distribution 

Im, Pesaran and Shin panel unit root test 

Johansen ML Cointegration analysis 

KPSS (Kwiatowski, Phillips, Schmidt, and Shin) stationarity test 

@KSCPOSTDRAW 
Draws from posterior density needed in stochastic volatility model 
@LAGPOLYROOTS 
Creates table of the roots of a lag polynomial 
LevinLinChu test for unit roots in panel data 

Limited information maximum likelihood estimation 

Creates matrices for local (level or trend) DLM 

Calculates initial guesses for component variances in a local level/trend 

Local smoothing regression 

@LOGMVSKEWT 
Function for log density of multivariate skewt distribution 
Computes parameters required for log normal distribution 

%LOGSKEWTDENSITY 
Function for log density of skewt distribution 
LumsdainePapell unit root test with structural breaks 

Estimates a dynamic FE model with correction for bias 

LeeStrazicich unit root tests with one or more structural breaks 

Computes Information Criteria for MA models using innovations algorithm 

@MACKINNONCV 
Computes Mackinnon’s Critical values for DF and EG tests 
Performs MannWhitney test for comparison of samples 

Functions supporting Markov Chain Models (obsolete use @MSSETUP instead) 

@MATPEEK 
Extracting/inserting information from/into rectangular arrays (obsolete: use %XSUBMAT and %PSUBMAT functions instead) 
Organizes tables of FEVD’s with confidence bands 

Organizes graphs of IRF’s with confidence bands 

Performs a McLeodLi test for 2nd order dependence 

Calculates sample statistics from MCMC realizations 

Organizes error bands for IRF’s based upon MC results 

Does Monte Carlo draws from a VAR to generate IRF’s 

Mean group estimator for panel data 

@MEPLOT 
Does Mean Excess Return plots 
Computes and graphs a spectrum using Maximum Entropy Method 

@MHEGY 
Implements the monthly version of the “HEGY” tests 
@MIXED 
Mixed estimation of a single equation 
Mixed estimation of an equation with a Bayesian prior 

Monte Carlo Integration of VAR Impulse Response confidence bands 

@MSEMSETUPSTD 
Markov switching procedures for EM estimation 
Markov switching linear regression procedures 

Markov switching general support procedures 

Markov switching linear systems regression procedures 

Markov switching VAR setup procedures 

Multiple structural change analysis per BaiPerron 

Multivariate test for ARCH 

@MVBNDECOMP 
Multivariate BeveridgeNelson decomposition via a VAR 
Multivariate GARCH forecasting 

Extracts a VECH representation from GARCH estimates 

Creates a TiaoBox cross correlation matrix 

Multivariate JarqueBera normality test 

Hosking’s Multivariate Q statistic 

Generates dummies based upon NBER cycle dates 

Computes Hodrick standard errors 

@PACF2AR 
Generates coefficients for an AR from input covariances 
Panel data unit root/cointegration testing procedure (Pedroni tests) 

Panel data group mean DOLS 

Panel data group mean FMOLS 

Does analysis of up to two threshold breaks in a fixed effects panel model 

Polynomial Distributed Lags regression 

@PDLREG 
Polynomial Distributed Lags regression 
Compute various unit root tests with breaks 

Compute various PerronNg “M” unit root tests 

PerronRodriguez unit root test allowing for break at unknown date 

Sum of coefficients of a MA representation for a series 

@PHILLIPSHANNAN 
PhillipsHannan Efficient estimator for multivariate regressions 
@POLYMULT 
Multiplying lag polynomial coefficients 
PhillipsOuliarisHansen test for Cointegration 

PhillipsOuliarisHansen test for Cointegration on 1st stage residuals 

PhillipsPerron Unit Root test 

Extracts principal components 

Principal componentsbased factor analysis 

@PRJCONDITIONAL 
Predicted probabilities for conditional logit model 
@PRJMULTINOMIAL 
Predicted probabilities for multinomial logit model 
@PRJPOISSON 
Predictions and marginal effects for Poisson count model 
Graphs a Q plot against a hypothesized distribution 

@QUARTIMAX 
Does factor rotation using quartimax criterion 
@RANGRID 
Random draw from a distribution approximated across grid of points 
@RANMIXTURE 
Random draws from a mixture of Normals 
@RANNORMALTRUNC 
Random draws from a truncated Normal (procedure). Obsolete: use %RANTRUNCATE function instead. 
Regression postprocessing, fancy graph of actual/fitted/resids 

Displays an analysis of variance table from most recent regression 

Displays a table of confidence intervals from most recent regression 

Computes and graphs autocorrelations from residuals 

Computes information criteria for most recent regression 

Computes the exact significance level for the DurbinWatson 

Performs structural break test with bootstrapped pvalues 

Computes partial correlations between the regressors and dep var. 

Panelcorrected standard error calculation 

@REGRECURSIVE 
Regression postprocessing, computes recursive resids, does tests 
Performs Ramsey RESET test on regression 

Creates a TeX equation from the most recent regression 

@REGTREE 
Performs a CART (Classification and Regression Trees) analysis 
@REGWHITENNTEST 
Performs White neural network test on regression 
Performs White heteroscedasticity test on regression 

Performs Wu (or DurbinWuHausman) specification test on regression 

Semiparametric fractional differencing parameter estimation 

Robust LM test for orthogonality of residuals and input series 

Computes rolling regressions for least squares 

@RRGQTEST 
Computes a GoldfeldQuandt test on recursive residuals 
R/S Statistic (classical or Lo’s modified) 

Computes a run test for a twostate series 

Creates the matrices for the seasonal component of a DLM 

Factor covariance matrix with short and long run restrictions 

Forecasting using spectral techniques 

Computes/graphs spectral density 

@SPLOM 
Produces an NxN matrix of SCATTER plots 
Computes various “SchmidtPhillips” tests (TAU) for a unit roots 

Multivariate spectral density of a state space model 

Perfoms Hansen’s stability test for OLS 

Performs a standard battery of specification tests for a state space model 

Test for linearity vs. LSTAR or ESTAR 

Backwards stepwise reduction of a probit model 

@STOCKWAT 
StockWatson and DickeyFuller Unit Root Tests 
Computes structural residuals from standard residuals 

Sets up Gibbs sampler for SUR model 

Computes a GLS matrix weighted estimator for a panel data set 

Estimates cointegrating vectors using dynamic OLS 

Tests cointegration rank using common trends analysis 

Estimates a threshold autoregression, tests for threshold effect 

Hansen’s Test for Threshold Break 

@TLOOKUP 
Provides a procedure for doing table lookups 
@TSAYNLTEST 
Tsay test for neglected nonlinearities 
Tsay arranged regression test for threshold autoregression (TAR) 

Tse test for constant correlation in MVGARCH model 

@TVARSET 
Timevarying VAR setup routine 
Forecast errors for a univariate model 

@UHLIGFUNCS 
Computes criteria for Uhlig signrestricted shocks 
Computes required parameters for uniform distribution 

Extracts unique values from a series 

Sets up a parallel system for bootstrapping a VAR 

@VARCALC 
Does a direct calculation of a simple OLS VAR 
@VARFPE 
Minimum FPE representation for the equations in a VAR 
Computes a state space representation to its implied VAR 

@VARIMAX 
Does factor rotation using varimax criterion 
Organizes graphs of Impulse responses for an estimated VAR 

@VARIRFDELTA 
Computes the covariance matrix of an IRF using the delta method 
@VARLAGMD 
Computes the sums of the VAR lag coefficients (obsolete, use %MODELLAGSUMS function) 
Selects lag length for a VAR model 

@VARMADLM 
Routines for analyzing a VARMA using DLM 
@VARSPECTRUM 
Multivariate spectral density of a Vector Autoregression 
@VRATIO 
Variance ratio unit root test procedure 
Heteroscedasticityrobust serial correlation test 

@WHITTLETEST 
Implements Whittle test for independence of state sequences 
@YULELAGS 
Computes Information Criteria for AR models using YuleWalker (obsolete: use @ARAutoLags instead). 
Estimates a VAR on stationary data using YuleWalker Equations 

ZivotAndrews Unit Root Test 