Software for STAT 626, Summer 1999

H. Joseph Newton
Professor of Statistics
Executive Associate Dean, College of Science
Texas A&M University

The software for the course is called timeslab and was written for the PC in 1988 to accompany the course's text. For information on how to download and install timeslab, click here .

Introduction to Timeslab

Timeslab is a command driven interactive DOS program which can be run under windows 95, 98, or NT. It has the ability to read data sets, calculate descriptive statistics, fit models, estimate spectra, and forecast future values of time series. It has built in graphics that can be easily exported to word processors. It has a built in text editor. It has its own matrix language that can be used to create programs so that timeslab can be customized almost endlessly.

In this document we introduce the reader to the basics of the use of the timeslab program. The following topics are covered:

  1. Starting, stopping, getting help
  2. Data types
  3. Inputting data
  4. Graphics

Starting, stopping, getting help

When timeslab starts, you will see a list of all of its commands followed by the timeslab prompt which is a question mark. To stop timeslab, you enter the command quit.

When timeslab starts, it is waiting for you to tell it what to do. An example of something you can do is

? x=wn(0,10)
? x
the first line of which uses the wn command to generate 10 N(0,1) random numbers and put them into the array called x, while the second line shows that saying the name of a variable results in it being displayed on the screen:
 normal white noise series               
     1 |  -1.15740      -1.09655     -0.168238     -0.197440      0.934374    
     6 |  0.379097      0.322437      0.578831      0.540704      0.749487    
(the numbers in the left column are the indices of the values in the second column, and the values are read across the rows).

To get a list of all the timeslab commands, one enters the command

? help
To get help for a particular command, enter help(command name), for example,
? help(wn)
 WN                x=WN(seed,n)  or  x=WN(seed,n,dist) 
   Generate a white noise series of length n using seed as the random 
   number generator seed. dist is one of the following distributions :
   dist :  1:N(0,1)          2:U(0,1)             3:unit exponential 
           4:logistic        5:Cauchy             6:extreme value 
           7:lognormal       8:double exponential                                
   The form x=WN(seed,n) generates a Gaussian series.


Data types

The listing above of the white noise array x shows that arrays have a name (here it is x) a label (such as "normal white noise series" in this example), a length (here it is 10), and values. You can have as many as 60 arrays and the total number of elements in all arrays combined must be 10,000 or less.

In addition to arrays (which are always treated as floating point real numbers), timeslab also has integer scalars, integer reals, and string variables as in

? n=100
? c=2.75
? fname='air.dat'
You can also have 60 of each of these. Variable names can have at most 15 characters and must start with a letter.

To see what variables have been defined, one enters the info command

? info
which gives
 Number of arrays and Free Elements:       1 9990
 x                  10  normal white noise series               
 n               =             100
 c               =      2.75000000
 fname           = air.dat        
for what we have done so far (note that there are 9,990 "free elements" as we have defined a single array containing 10 elements).


Inputting data