A brief introduction to Minitab
INTRODUCTION
Minitab is a statistical package designated mainly as a teaching tool.
Although, it is easy to use, it is quite powerful and flexible for
moderate size data sets.
Minitab allows you to store a worksheet of data and does some
statistical manipulations with it. It is possible to access minitab
in either bingsuns account or Windows.
I recommend yo to use the minitab in Windows version in
engineering building: rooms G10, G17 and Classroom 4 at the South POD.
In suns, to access minitab type the command:
bingsun2% minitab
Minitab will then start up with the following prompt:
MINITAB Statistical Software, Enhanced Version
Release 9.1 for SUN
(C) Copyright 1992 Minitab Inc. - All Rights Reserved
JULY 14, 2000 - SUNY - BINGHAMTON
Worksheet size: 8000 cells
For information on: Type:
-------------------------- ---------------
How to use Minitab HELP
Customer service HELP OVERVIEW 14
Documentation HELP OVERVIEW 15
What's new in this release NEWS
MTB>
"MTB " is the Minitab command prompt; other prompts are "DATA " which is given during interactive entry of data values - and "SUBC " which indicates that Minitab expects a subcommand or command continuation.
In Windows, to access minitab, you click in the minitab icon.
When you run a minitab session you will get a worksheet of data to you can do arithmetic and statistical manipulations. The worksheet consists of a sheet of constants (denoted K1, K2, K3, ...), columns (denoted C1, C2, C3, ...) and matrices (denoted M1, M2, M3, ...). To store data in the constant K1, use
MTB> let k1=990
To store data in the vector C1, use
MTB> set c1
MTB> 11 14 15 15 3
MTB> end
You can name variables:
MTB> name c1 'age'
At any point in the session, you can find out what is in the worksheet (all k's, c's and m's that you have defined) typing
MTB> INFO
Column Name Count
C1 5
Constant Name Value
K1 990.000
You can do operations and statistical manipulations with the data in your worksheet by inputting commands. For example, the command
MTB> let c3=c1+c2
Adds the vectors c1 and c2 and stores the result in C3 in your worksheet. You need to have defined c1 and c2 before hand. After you do this, you do not see c3 in your screen. To see c3, use print. For example, with the previous entered data:
MTB> let c2=c1+k1
MTB> print c2
C2
1001 1004 1005 1005 993
In windows, you have a menu. You can to a session window and do the commands above. For many simple commands, you can use the menu. For example going to Window>Session you can input data directly.
GETTING HELP ON MINITAB
There is a online help, that gives you plenty of information in how to use minitab, for example if you type
MTB> help
* You are using MINITAB Statistical Software, Enhanced Version *
To see: Type:
----------------------------- ---------------------------------
A list of all command topics HELP COMMANDS
A list of all overview topics HELP OVERVIEW
Information on a command HELP commandname [subcommandname]
----------------------------- ---------------------------------
For example: HELP COMMANDS
HELP PLOT
HELP PLOT TITLE
To leave Minitab, type STOP.
If you type :
MTB> help regression
you get help in the command regression. If you type :
MTB> help regr resi
you get help in the subcommand residuals form the command regression.
In Windows, you can help going to the menu Help, which is at the end of the menu.
EXITING FROM MINITAB
When you have finished using Minitab, you can return to the operating system level by using any of the commands:
MTB> quit
MTB> stop
In Windows, you can exit the program as any regular program (clicking in the x).
TYPES OF FILES
When using minitab, you may use several types of files: .MTW, .DAT, .LIS, .MTJ and .MTB. The use of all these files is optional.
If the worksheet is stored, this file will have the ending .MTW. To save the worksheet (the data in the minitab memory; c's and k's that you have defined) type:
MTB> save 'file'
This command will store your current worksheet in the file 'filename.MTW' To come back to that worksheet, you can retrieve it by typing :
MTB> retr 'filename'
In Windows, to save a file, you do the menu: File>save worksheet. To retrieve a file you do: File>open worksheet
Files ending .DAT denote files with data. These are ASCII files. The following summarises data file handling commands on Unix: read, set, insert, write. To get from the .DAT file to minitab you use
MTB> Read 'C:NAME.DAT' c5.
In Windows, to get data from a .DAT file, you use File> Import ASCII data. To get data in a .DAT file you use: File> Export ASCII data.
A file name.LIS records all commands and non-graphical statistical output. Session window output is separate from your worksheet. The Session window keeps about 25 printed pages' worth of output at time, then discards the first half of the output to make room for more. In unix, you get this file by typing outfile. Everything that is shown on the screen will also be written to the unix file "name.LIS". You stop to record by typing nooutfile.
In Windows, to start recording in the file name.LIS, type
File> Other files> Start recording
You can always print and/or save the contents of your Session window by choosing
File> Print Window or File> Save Window As.
Log input, filename optional, default filename is minitab.MTJ, assumed suffix is .MTJ. Puts a copy of all the lines you type (commands and data) in a journal file. JOURNAL stays in effect until you type NOJOURNAL. If you type JOURNAL again with the same file name, input lines are appended to this file. In Windows, you use:
File> Other Files >Start Recording History.
The files named name.MTB designed macros. A macro is a program (a collection of minitab commands). in unix, macros are handled with the commands: store, execute.
ENTERING DATA
Minitab can store numbers in: To enter the value of constants you can do
MTB> let k1=990
To enter the value of vector you can do
MTB> set c1
MTB> 11 14 15 15 3
MTB> end
or
MTB> READ C1 C2
DATA> 23 21
DATA> 25 17
DATA> 40 52
DATA> 56 30
DATA> 12 19
DATA> END
You also can enter patterned data from the Session window. For example,
MTB> set c6
DATA> 1:4 3(30) 2(7)
DATA> end
puts 1 2 3 4 30 30 30 7 7 into column c6.
You also can create a data a unix with data and pass this
data to the worksheet doing:
MTB> read 'file' C1
Altenatively, you also can pass your data from the worksheet into unix by doing:
MTB> write c1 'file'
In your unix directory the file will be ending in .DAT. These commands work with several columns and matrices (see the minitab help).
In Windows, you can enter the data directly in the columns you want.
SOME ARITHMETIC COMMANDS
It is possible to do simple arithmetic (add, subtract, multiply and divide and square roots). The next commands are self explanatory:
MTB> let c3=c1+c2
MTB> let c3=c1-c2
MTB> let c3=c1*c2
MTB> let c3=c1/c2
MTB> let k1=sqrt(5)
MTB> let k1=2**(1/3)
SOME STATISTICS COMMANDS
MTB> mean C3
print the mean of the numbers stored in column C3.
MTB> stdev C3
print the standard deviation of the numbers stored in column C3.
MTB> corr c1 c2
print the linear correlation coefficient between the two columns.
MTB> describe C3
print various descriptive statistics, including maximum, mean, median, of the numbers in C3.
MTB> tinterval c1
find a 95 % confidence interval using the data in c1 and the t statistic.
PLOTTING DATA
There are several commands to plot data. These commands can have subcommands. For example,
MTB> hist c1
Histogram of x N = 10
Midpoint Count
-2.0 1 *
-1.5 3 ***
-1.0 1 *
-0.5 0
0.0 0
0.5 2 **
1.0 1 *
1.5 2 **
MTB> dotplot c1
.
. : . . . . ..
---+---------+---------+---------+---------+---------+---x
-2.10 -1.40 -0.70 0.00 0.70 1.40
MTB> boxplot c1
----------------------------------
---------I + I-------
----------------------------------
----+---------+---------+---------+---------+---------+--x
-2.10 -1.40 -0.70 0.00 0.70 1.40
There are commands to graph one variable versus another.
MTB> plot c1 c2
- *
1.2+ *
- *
x - *
- *
-
0.0+
-
-
-
-
-1.2+ *
- * * *
-
-
- *
-2.4+
----+---------+---------+---------+---------+---------+--y
-1.40 -1.05 -0.70 -0.35 0.00 0.35
There are two types of graphing options; standards graphs and professional graphs. Most commands only works in one of these options. To change to standard graphs use
MTB gstd
To change to professional graphs use
MTB gpro
DISTRIBUTIONS
The cumulative distribution of certain distributions can be found using the command cdf. For example,
MTB> set c3
DATA> 1 3 5
DATA> end
MTB> cdf c3;
SUBC> binomial 5 0.5.
K P(X LESS OR = K)
1.00 0.1875
3.00 0.8125
5.00 1.0000
Possible distributions and their parameters are
bernoulli p = k
binomial n = k p = k
poisson mu=k
integer a=k b= k
discrete values in c, probabilities in c
normal [mu=k [sigma=k]]
uniform [a=k b=k]
t df=k
f df1=k df2=k
chisquare df=k
INVCDF finds a value x corresponding to a given probability p with respect of the specified distribution. For example,
MTB> invcdf 0.05;
SUBC> t 15.
0.0500 -1.7531
The command random finds random samples. For example,
MTB> random 100 c1;
SUBC> t 15.
will fill out c1 with a random sample of size 100 from a t distribution with 15 degrees of freedom.
MACROS IN MINITAB
A Minitab macro is a set of Minitab commands and macro statements stored in a file which can be executed all at once. The most common way to create a macro file is by using a word processor or editor. There are three types of macro; execs files, global macros and local macros.
An execs macro is just an Unix file with some minitab commands. Different commands are typed in different lines. It is recommended that you type 'end' at the end of the file. To run this file just type:
MTB> exec 'namefile' k1
This allows to run the commands in the file 'namefile' k1 times, without having to type them again and again. First you need to create in Unix a file 'namefile' with the minitab commands (one command per line) and t.
Global and local macros can have special collection of minitab commands (such as if, while and goto). These files use the default extension MAC and are invoked using the symbol %.
MTB> %namefile