Friday, March 21, 2014

MINITAB III

  • Data can be entered horizontally or vertically (as Rows or Columns).In the top left corner of the Worksheet window, there is a cell with an arrow in it.  Click this cell to change the action of the Enter key. 

  • Pointing down arrow  then the cursor will go down the column when you press Enter.  

  • Arrow pointing to the right( →) - then the cursor will go across the row, to the next column when you press Enter. 
Consider the following collection of data

Temperature(C)Water consumption (ml)
15470
17500
19540
21550
23620
25680
27740
i

Calculating
Using calculator
  • If the data in columns are to be changed before calculating statistical values that can be done using calculator. Ex: calculate store temperature in Fahrenheit or volume in another scale
  • Open calculator using menu Calc and selecting option Calculator


In this calcaultor on left hand side the columns and constants are dispalyed.
  • Store result in variable: If a single value is calculated it can be stored in a constant or in a column. For multiple values a column must be used.
  • Expression: the expression can be built in this text box. For that numbers ,simbols and functions can be used. To obtain results have to click on Ok button. 


Save
  • Minitab has facilitated to save the data as the entire project or the worksheet. Saving the worksheet as a separate file is a good practice.
  • By using File menu and options Save Project/ Save Current Worksheet data can be saved in a storage device.
Statistical Analysis
Minitab is a software that can be used to calculate many statistical details based on a collection of data. Under the menu Stat there are number of options relates with statistic experiments, these options vary on software version.
For the above collection of data
Find the mean and standard deviation for the temperature/water data,
  1. Select  Stat > Basic Statistics > Display Descriptive Statistics
  2. In the Variables box, select C1 (Temperature).
  3. Click OK.

Definitions of the terms in the output
  1. N = number of data items in the sample 
  2. N* = number of items in the sample that have missing values (N* does not show up when all the items in the sample have values) 
  3. Mean = average 
  4. Median = 50th percentile 
  5. TrMean= the 5% trimmed mean 
  6. StDev = standard deviation 
  7. SE Mean = standard error of the mean (standard deviation divided by the square root of the sample size) 
  8. Minimum = smallest data value 
  9. Maximum = largest data value 
  10. Q1 = 25th percentile = first quartile 
  11. Q3 = 75th percentile = third quartile
Graphs
  1. To draw a histogram, select Graph > Histogram.
  2. In the Graph Variables box, select C1 (Temperature).
  3. Click Ok.  
Note: You can change the settings for the width of the bars  in the histogram by clicking Options  on the histogram dialog box and making the desired changes.)


  1. To draw a boxplot, select Graph > Boxplot.
  2. In the Graph Variables box under the
     Y select C1 (Temperature).
     The X column is for categories.  
  3. Click Ok. 



  1. To graph a scatterplot for the water consumption based on the temperature,
     select Graph > Scatter Plot.
  2. In the Graph Variables box,
    under the Y, select C2 (Water Consumption)
     and under the X, select C1 (Temperature).
  3. Click Ok


To save graphs the entire project has to be saved using Save Project As or Save Project options

Exercise


Reg NoSubject 1Subject 2Subject 3Subject 4
PS/0899/00278828576
IS/0999/00356585469
LS/090/00425504535
MS/009/00589928987
OS/099/00868728978
WS/079/01050587954
QS/089/01245684658

1.       Enter the data in above table to the worksheet.
2.       Change the marks of subject 1 by adding 5 marks using calculator.
3.       Find Row and column statistics by customizing the selections available.
4.       Find Descriptive statistics using Basic statistics menu on these data based on subjects.
5.        Generate graphs using Graph menu based on subjects.

MINITAB II

Data Entry
  Enter following data using the keyboard.

StudentDOBExam 1Exam 2Exam 3
Perera.L.1/9/1980756288
Kumara.P.3/22/1985667873
Sarath.D.9/25/1986929698
Nalin.S.7/15/1987867779
Rangana.K.2/8/1980959292
Samanthi.D.5/2/1984797185
Other Methods of Importing Data
  •   From External Files (Like from Excel)
    •   File > Open Worksheet
  •   Using the Clipboard
    •   Edit > past cells
 Manipulating Data
  • Stack 
    • Combine two or more columns into one column.
      • Data > Stack > Columns…



  • Unstack 
    • Separate one or more columns into blocks of columns.
      • Data > Unstack Columns
  • Coding Data
    • Converts data to text, numeric or date/time data.
      • Data > Code > …



  • Copying Data
    • Copy data from columns, constants and matrices to new columns, constants or matrices.
      • Data > Copy >



  • Summarizing Data
    • Signs: Convert negative, zero and positive values to -1, 0 and +1.
    • Parsum: calculates and stores partial sums (similar to cumulative sum) .
      • Calc > Calculator



  • Ranking Data
    • Rank the data values in order of magnitude.
      • Data > Rank



  • Sorting Data
    • Orders text or numeric data in one or more columns. Missing values are sorted last in numeric columns and first in text columns.
    • Data > Sort



  •   Data Display
    • Display data on session window
      • Data > Display Data


Doing Calculations
  • Compute algebraic expressions, comparison and logical operations. 
    • Algebraic expressions: +, -, *, / and **, commands (mean, sum, etc.) 
    • Comparison operations: = or EQ (Equal to); ~=, <>, or NE; < or LT; > or GT; <= or LE; and >= or GE
    • Logical operations: & or AND; | or OR; and ~ or NOT.
      • Calc > Calculator
Entering Patterned Data
  • A sequence of data, repeated data or repeated sequences can be entered easily. 
    • Calc > Make Patterned Data
MINITAB GRAPHS
  • Two types of graphs available 
    • Character graphs
    • High resolution graphs (Professional graphs)




Thursday, March 20, 2014

MINITAB I

Introduction
  •   Data preparation and application of statistical techniques using statistical software.
  •   Statistical Software
    • R (Free software), Minitab, SPSS, SAS, Statistica, etc
  •  What is STATISTICS?  
    • A Science of Collection, Analysis, Interpretation or Explanation and Presentation of Data.
      • Collection: Planning, Data Collection, Data Entering & Editing (Data Preparation). 
      •  Analysis: Descriptive (Exploratory) and Inferential Analysis.
  •   What is MINITAB

  •  A software package that is used for data entry, editing, analysis and presentation.   
  • Interpretation…?
  •  Its up to you.
  • Introduction to MINITAB 
    Minitab is a software package that use for statistical data analysis. There are lots of versions of Minitab. In this practical course we are learning Minitab 14
    To start MINITAB 
    • START→ Programs → Minitab 13 for windows → Minitab or 
    • Double click the Minitab icon on the desktop

    The MINITAB Environment

    There are 5 windows 

    Session window
    The session window displays text output/results.Used to execute commands. (Ctrl+M)
    Data window Data windows are where you enter, edit and view the column data for each worksheet. (Ctrl+D)
    Info window The Info window summarizes each open worksheet. Choose which worksheet to view by picking from the drop down list. (Ctrl+I)
    History window The History window records all the commands you have used.
    Graph window Display graphs. You can have up to 15 graph windows open at a time.

    To view all above windows,
    In the menu bar, there is a tab called “Windows”
    Managing Data
    This section is about several data types that are used in Minitab.
    Data Types
    A worksheet can contain three types of data.

    Numeric data
    Numerical data is the only type Minitab will use for statistical calculations. Minitab will not recognize numbers with commas as numbers but will consider them text.
    Text Characters that can consist of letters, numbers, spaces and special characters
    Date and Time Minitab recognizes 3/5/14 as a date and 4:30 as a time but will store these internally as a number so you can manipulate them. The column label will indicate a date or time value by putting a D after the column name (for example C1-D).

    Date format in MINITAB
                          mm/dd/yyyy
                                      eg: 02/25/2014
    Naming Columns in Worksheet 
    A Column Name can not 
    • be longer than 31 characters 
    • start with the symbol ' *'‟ 
    • include the symbol ' # '
     Saving a MINITAB File 
    In MINITAB 13, it has the capability of saving the entire work as a project, including all windows. (Session, worksheet, graphs etc) 
    Otherwise we can save the content of each window as separate files.
    1. Active the window you want to save.
    2. Choose File Save< window type > as 
    3. Select the relevant file type.
    4. Enter a Name for the File. 
    5. Click OK 
    Issuing Commands 
    In MINITAB, there are two ways to access commands. 
    1. With menus
    2. Using session commands 
    Most commands use data in some way. Data are stored on worksheets, and project can contain many worksheets. When you issue command (by any method) that uses the data, the command act on the current worksheet. The current worksheet can be easily identified with three asterisks in the title. Numeric
    Menu Commands 
    Click on an item in the menu bar to open the menu, and then click on a menu item to execute the command, open a sub menu, or open a dialog box. 

    Session Commands 
    Session commands are a useful alternative to menu commands, especially when you want to repeat a group of actions or create an Exec.
     Enable the commands in the session window. 
    It is very useful to practice, enable the commands in the session window before starting any important work with MINITAB. 
    1. Select the session window.
    2. Editor Enable Command. 
    MTB > (MTB prompt) 
    Formatting columns 
    • Naming Columns 
               MTB > NAME C1=’Height’ C2=’Weight’ 
    • To change the column width of the worksheet,  
    C1 C2
    HeightWeight
    1
    2
    3
     First Left Click on the Worksheet and then go to the following path. 

                       Editor →Column →Standard width 

    • To change the column width of a particular column, 
                      Select the corresponding column,
                       Editor →Column → Width 
    • Formatting a numeric column 
                 If you want to change the number of decimal places in a relevant numeric column, Select the column,
                   Editor Format Column Numeric….
    (Automatically it will highlight the data type according to the selected column).

    • Formatting a Date/Time column 
    To change the format of a Date /Time column,
               Editor Format Column Date/Time…
    Delete Rows
    Manip  Delete Rows
    Deletes Rows K……..K from column C……C and moves the remaining rows up to close the gap.
    Ex: Delete 2nd, 5th & 6th rows from columns C1, C2 & C3.

    C1C2C3
    234154
    315175
    224143
    263153
    326167
    306185
    244155

    C1C2C3
    234154
    224143
    263153
    244155
    Erase Variables 
    Erase any combination of columns (including their names), constants, and matrices. 
    Manip  Erase variables 
    (MTB > Erase C1 K) 
    To Exit MINITAB  
    File → Exit

    Calc Open Office Part IV

    Sorting Data
    • The sorting mechanism in a Calc document rearranges the data in the sheet.
      • STEP 1: Select the data that you want to sort.
      • STEP 2: Use Data > Sort to open the Sort dialog.
    • You can sort by up to three columns or rows at a time.

    Sort Dialog Box
    Sort Options


    1. Range contains column labels Check the Range contains column labels checkbox to prevent column headers from being sorted with the rest of the data.
    2. If the Range contains column labels checkbox is not checked, however, then the columns are identified by their column name; Column A, for example.
    Range contains column labels

    Copy sort results to

    • Normally, sorting the data causes the existing data to be replaced by the newly sorted data. 
    • The Copy sort results to checkbox, however, causes the selected data to be left unchanged and a copy of the sorted data is copied to the specified location.


    Conditional Formatting

    • You can set up cell formats to change depending on conditions that you specify. For example, in a table of numbers, you can show all the values above the average in green and all those below the average in red. 
    • Conditional formatting depends upon the use of styles.
    STEPS:
    1. Create your cell/page style
    2. Select the cells to apply conditional formatting
    3. Choose Format > Conditional Formatting
    4. Enter the conditions
    5. Click OK