RATS 6.35 was a fairly major update to RATS. This page provides detailed information on the new features, options, and functions that were introduced in 6.35:
| SWEEP | This new instruction is a multi-purpose tool for regressing one set of variables on another. You can use it to “sweep” out the effects of short-run variables in cointegration analysis, or dummies in other types of regressions. With the GROUP option, you can allow a regression to vary across groups of data, building up the residuals or fitted values from the heterogeneous regressions. See page 39 for more details. |
Version 6.35 included the following improvements to these instructions:
| AR1 | New TITLE option for providing a custom title for the estimation output. The new option PRHOS saves the estimated values when using the HETEROGENOUS (or DIFFERING) option when estimating a panel data set. |
| CALENDAR | We redesigned the CALENDAR instruction with a simpler approach to specifying frequencies. The old syntax still works, but we think new users will find the new format easier to use and read. See detailed documentation on pages 32 to 38. |
| CATALOG | New LIKE option, for displaying information on series that match a wildcard expression. |
| DATA | The Professional version of RATS now supports ODBC database connectivity, which allows users to extract data from a variety of data sources using SQL commands. |
| DDV | New EQUATION option for estimating an existing equation. Also, DDV now saves all estimated parameters in the %BETASYS and %XXSYS arrays. |
| DLM | Major revisions, including many new options and option choices. |
| EIGEN | New GENERAL option for computing generalized eigenvalues. |
| GCONTOUR | New FOOTER option for adding a footer label to the graph. |
| GRAPH | Version 6.35 offers many improvements, including thicker line styles and an improved algorithm for determining tick marks and labels for the vertical and horizontal axes. For example, RATS is now much more likely to select multiples of 5 or 10 for the vertical marks. SPIKE is a new choice for the STYLE and OVERLAY options—similar to a bar graph, but with narrow “spikes” instead of wide bars. The FOOTER option adds a footer label to the graph, while the FRAME option allows you to control the presence of the “frame” around the edge of the graph. Finally, the SMPL option allows you to graph a subset of observations. |
| LDV | New EQUATION option for estimating an existing equation. |
| LGT | New EQUATION option, as above. |
| NLSYSTEM | New MODEL option for estimating an existing model. |
| PRB | New EQUATION option, as above. |
| PREG | Now saves the log-likelihood in %LOGL when using METHOD=SUR. |
| PRTDATA | New LIKE option for displaying series that match a wildcard expression. |
| REPORT | The SPECIAL option now works with ACTION=FORMAT. |
| RLS | New CONDITION option allows you to condition on a specified number of observations, not just the %NREG observations. |
| SCATTER | New SPIKE and STEP choices for the STYLE and OVERLAY options. New FRAME, FOOTER, and SMPL options (as on GRAPH). |
| SPGRAPH | You can now nest SPGRAPH blocks inside other SPGRAPH blocks, to create more complex tables of graphs. New FOOTER option, as on GRAPH. |
| WINDOW | New QUADRATIC and TRIANGULAR choices for the TYPE option (TRIANGULAR is synonym for the existing TENT choice). |
Also, most estimation instructions now define %NFREE, the number of freely estimated (i.e. unconstrained) parameters.
The Edit menu offers new commands to help you manage your program code and comment lines. These options are only available when you have one or more lines of text in selected:
| Format Comments | Useful for turning several lines of text information into a formatted block of comments. This reformats the lines to a consistent length, and inserts * (comment) symbols at the beginning of each line. Use Edit–Undo if you don’t like the results. |
| Comment-Out Lines | Adds an * symbol to the beginning of each selected line. |
| Uncomment Lines | Removes * (comment) symbols from the beginning of each selected line. |
| Indent Lines | Indents the selected lines (you can repeat this operation to indent further) |
| Unindent Lines | Unindents the selected lines. |
6.35 added three new matrix concatenation operators:
| ~ | Does a horizontal concatenation of two arrays. Both arrays must have the same number of rows. |
| ~~ | Does vertical concatenation. Both arrays must have the same number of columns. |
| ~\ | Creates a block diagonal matrix from two arrays. |
| %BESSELJ(N,X) | Returns the Bessel function of the first kind, for x given order n. |
| %CLOSESTDATE(Y,M,D,DOW) | Returns the number of the day within a month that is the closest occurrence of the specified day of the week (DOW) to the year, month, and day specified. Useful for identifying the date of holidays like Martin Luther King Day, which is observed in the U.S. on the Monday closest to January 20th. |
| %CLOSESTWEEKDAY(Y,M,D) | Returns the day number of the weekday closest to the date specified by year, month, and day. For example, %closestweekday(2004,7,4) returns “5”, because the closest weekday to that day was July 5 (a Monday). |
| %CORRTOCV(C,V) | Converts a correlation matrix (C) and a vector of variances (V) into a covariance matrix. |
| %DOW(Y,M,D) | Returns the day of the week (Monday=1 through Sunday=7) for the date given by year, month, and day. |
| %EASTER(Year) | This will only work with a seven day per week CALENDAR setting. It returns the date of the Easter holiday in the Western Christian tradition as a number of days after March 22 (the earliest possible Easter date). For example, to display the date of the holiday in 2007, you could do: display %datelabel((2007:3:22)+%easter(2007)) |
| %FLOATINGDATE(Y,M,D,DOW,N) | Returns the day number of the nth occurrence of the specified day of the week in the given month. Useful for determining the date of floating holidays defined based in this manner, such as the Thanksgiving holiday in the U.S. |
| %GEVCDF(X,K,Mu,Sigma) | Returns the cdf of the Generalized Extreme Value distribution, for tail index k, location parameter Mu, and scale parameter Sigma. |
| %GPCDF(X,K,Mu,Sigma) | Returns the cdf of the Generalized Pareto distribution, for tail index k, location parameter Mu, and scale parameter Sigma. |
| %INVGEV(P,K,Mu,Sigma) | Returns the inverse of the Generalized Extreme Value distribution, for probability p, tail index k, location parameter Mu, and scale parameter Sigma. |
| %INVGP(P,K,Mu,Sigma) | Returns the inverse of the Generalized Pareto distribution, for probability p, tail index k, location parameter Mu, and scale parameter Sigma. |
| %INVTCDF(P,D) | Returns the inverse cdf of the t distribution, for probability p and degrees of freedom d. |
| %LOGCDF(Variance,X) | Returns the log of a mean zero Normal cdf. |
| %LOGGEVDENSITY(X,K,Mu,Sigma) | Returns the log of the density function for the Generalized Extreme Value distribution for x, given tail index k, location parameter Mu, and scale parameter Sigma. |
| %LOGGPDENSITY(X,K,Mu,Sigma) | Returns the log of the density function for the Generalized Pareto distribution for x, given tail index k, location parameter Mu, and scale parameter Sigma. |
| %LTINV(L) | For a packed matrix L, this returns the inverse of the lower-triangular portion. |
| %LTOUTERXX(L) | For a packed matrix L, this returns the outer product of the lower-triangular portion. |
| %MODELCOMPANION(M) | Returns the companion matrix for a MODEL. The model must only include linear equations—the function will not work if the model includes non-linear formulas. |
| %RANMAT(M,N) | Returns an m x n rectangular matrix filled with random draws from a Standard Normal(0,1) distribution. |
| %RANSPHERE(n) | Returns a uniform draw of an n-element vector on the unit sphere. |
| %STEREO(V) | Converts an n-1 element vector to an n vector on the unit sphere. |
| %TCDFNC(X,D,NC) | Returns the cdf of x for a non-central t distribution, with degrees of freedom d, and non-centrality parameter nc. |
| %TDENSITYNC(X,D,NC) | Returns the density function of x for a non-central t distribution, with degrees of freedom d, and non-centrality parameter nc. |