Friedman's test

zarikahn 23,984 views 34 slides May 09, 2016
Slide 1
Slide 1 of 34
Slide 1
1
Slide 2
2
Slide 3
3
Slide 4
4
Slide 5
5
Slide 6
6
Slide 7
7
Slide 8
8
Slide 9
9
Slide 10
10
Slide 11
11
Slide 12
12
Slide 13
13
Slide 14
14
Slide 15
15
Slide 16
16
Slide 17
17
Slide 18
18
Slide 19
19
Slide 20
20
Slide 21
21
Slide 22
22
Slide 23
23
Slide 24
24
Slide 25
25
Slide 26
26
Slide 27
27
Slide 28
28
Slide 29
29
Slide 30
30
Slide 31
31
Slide 32
32
Slide 33
33
Slide 34
34

About This Presentation

The Friedman test is a non-parametric alternative to ANOVA with repeated measures.


Slide Content

Lecture objective Nonparametric tests Friedman’s test History When to uses Assumptions Basic idea Examples How to run it in SPSS

NON PARAMETRIC TESTS FRIEDMAN’s TEST

Non Parametric tests A nonparametric test is one that is performed without making any restrictive assumptions about the form of the population distribution and associated parameters. It provide alternatives to parametric test & has many advantages and disadvantages..

Friedman’s test Friedman test is a non parametric statistical method developed by Dr. Milton Friedman

Dr. Milton Friedman Born July 31, 1912 Died November 16, 2006 (aged 94) Contributions: Price theory (monetarism) Applied macroeconomics Floating exchange rates Permanent income hypothesis Volunteer military. Friedman test

Awards: National medal of science (1988) President medal of freedom (1988) Nobel memorial prize in economic sciences(1976) John bates clark medal (1951)

FRIEDMAN’s TEST The Friedman test is a non-parametric alternative to ANOVA with repeated measures. It is used to test for differences between groups when the dependent variable being measured is ordinal. The Friedman test tests the Null hypothesis of identical populations for dependent data. The test is similar to the Kruskal -Wallis Test. It uses only the rank information of the data.

Assumptions 1. The r blocks are independent so that the measurements in one block have no influence on the measurements in any other block. 2. The underlying random variable of interest is continuous (to avoid ties). 3. The observed data constitute at least an ordinal scale of measurement within each of the r blocks. 4. There is no interaction between the m blocks and the k treatment levels. 5. The c populations have the same variability. 6. The c populations have the same shape.

Steps involved in testing 1) Formulation of hypothesis 2) Significance level 3) Test statistics 4) Calculations 5) Critical region 6) Conclusion

1) Formulation of hypothesis we check the equality of means of different treatments as in ANOVA, the null hypothesis will be stated as: H o = M 1 =M 2 =……=M k H 1 = not all medians are equal

2) Level of significance: it is selected as given if not given 0.05 is taken. 3) Test statistics: where R . j 2 is the square of the rank total for group j ( j = 1, 2, . . . , c ) m is the number of independent blocks k is the number of groups or treatment levels

4) Calculations: Start with n rows and k columns. Rank order the entries of each row independently of the other rows. Sum the ranks for each column. Sum the squared column totals. Using test statistic calculate the value of Q.

5) Critical region: Reject H if Q ≥ critical value at α = 5% If the values of k and/or n exceed those given in tables, the significance of Q may be looked up in chi-squared ( χ 2 ) distribution tables with k-1 degrees of freedom.

6) Conclusion: If the value of Q is less than the critical value then we’ll not reject H . If the value of Q is greater than the critical value then we’ll reject H .

Example 1: The manager of a nationally known real estate agency has just completed a training session on appraisals for three newly hired agents. To evaluate the effectiveness of his training, the manager wishes to determine whether there is any difference in the appraised values placed on houses by these three different individuals. A sample of 12 houses is selected by the manager, and each agent is assigned the task of placing an appraised value (in thousands of dollars) on the 12 houses. The results are summarized as follows.

At the 0.05 level of significance, use the Friedman rank test to determine whether there is evidence of a difference in the median appraised value for the three agents. What can you conclude? Houses Agent1 Agent 2 Agent 3 1 181.0 182.0 183.5 2 179.9 180.0 182.4 3 163.0 161.5 164.1 4 218.0 215.0 217.3 5 213.0 216.5 218.4 6 175.0 175.0 216.1 7 217.9 219.5 220.1 8 151.0 150.0 152.4 9 164.9 165.5 166.1 10 192.5 195.0 197.0 11 225.0 222.7 226.4 12 177.5 178.0 179.7

Solution: Formulation of hypothesis: H : M 1 =M 2 =M 3 H 1 : Not all medians are equal 2) Level of significance: α=0.05 3) Test statistics:

4) Calculation: k=3 m=12 Q=159.29-144 Q=15.29 Houses Agent1 Agent 2 Agent 3 1 181.0 1 182.0 2 183.5 3 2 179.9 1 180.0 2 182.4 3 3 163.0 2 161.5 1 164.1 3 4 218.0 3 215.0 1 217.3 2 5 213.0 1 216.5 2 218.4 3 6 175.0 1.5 175.0 1.5 216.1 3 7 217.9 1 219.5 2 220.1 3 8 151.0 2 150.0 1 152.4 3 9 164.9 1 165.5 2 166.1 3 10 192.5 1 195.0 2 197.0 3 11 225.0 2 222.7 1 226.4 3 12 177.5 1 178.0 2 179.7 3 Sum of ranks 17.5 19.5 35 (17.5 2 +19.5 2 +35 2 )-3 х 12(3+1)  

5) Critical region: Reject H0 if Q > critical value at 5% level of significance. Q tab=6.5 6) Conclusion: we reject H , as Q cal ≥ Q tab , and hence conclude that the appraising ability of three agents are not the same.

Example 2: A water company sought evidence the measures taken to clean up a river were effective. Biological Oxygen Demand (BOD) at 12 sites on the river were compared before clean up, 1 month later and a year after clean up.

Solution: Formulation of hypothesis: H : The clean up procedure has had no effect on the BOD. H 1 : The clean up procedure has affected the BOD. 2) Level of significance: α=0.05 3) Test statistics:

4) Calculations: m=12, k=3 Q=8.43 (32 2 +22.5 2 +17.5 2 )-3 х 12(3+1)  

5) Critical region: Reject H if Q > critical value at 5% level of significance. Q tab =6.5 6) Conclusion: As Q cal ≥ Q tab so we will reject H , hence conclude that the cleanup procedure has effected the BOD.

Question 1: The following data on amount of food consumed (g) by eight rats after 0, 24, and 72 hours of food deprivation appeared in the paper “The Relation Between Differences in Level of Food Deprivation and Dominance in Food Getting in the Rat”. Does the data indicate a difference in the true mean rank of food consumption for the three experimental conditions?

Question 2: The venerable auction house of Snootly & Snobs will soon be putting three fine 17th-and 18th-century violins, A,B, and C, up for bidding. A certain musical arts foundation, wishing to determine which of these instruments to add to its collection, arranges to have them played by each of 10 concert violinists. The players are blindfolded, so that they cannot tell which violin is which; and each plays the violins in a randomly determined sequence (BCA, ACB, etc.). 

Question 3 In this analysis the one variable is the type of animal (fish, reptiles, or mammals), and the response variable is the number of animals on display. From our database, we use three variables reptnum (number of reptiles on display), fishnum (number of fish on display) and mamlnum (number of mammals on display). These scores are shown for the 12 stores below( reptnum , fishnum, mamlnum ). 12,32,34 14,41,38 15,31,45 12,38,32 7,21,12 4,13,11 10,17,22 4,22,9 14,24,20 4,11,8 5,17,19 10,20,8 We have to check that whether the pet shop display same number of pets.

SPSS Method

Question Suppose for example we want to find out if students have a preference for one type of soda over others. They are blindfolded and given a taste test. They are asked to take a sip of Brand X, Brand Y and Brand Z sodas and to rank order their preference for the three sodas where a 1 is the highest rank, a 2 the next highest and a 3 the least preferred soda. The data representing the rankings given by each participant to the three sodas are:

Participants’ Rankings of the Three Brands of Soda Participant Brand X Brand Y Brand Z 1 2 1 3 2 1 3 2 3 1 2 3 4 1 3 2 5 1 3 2 6 1 2 3 7 1 3 2 8 1 2 3 9 1 3 2 10 2 1 3

SPSS method Enter ranks for each sample in different columns and then data analysis is done. Data Analysis 1. Click on Analyze at top of screen then a. Click on Non-Parametric Tests then b. Click on K Related Samples 2. Highlight Brand x by clicking on it then a. Click on arrow > to transfer this name to the Test Variable Box 3. Highlight Brand y by clicking on it then a. Click on arrow > to transfer this name to the Test Variable Box 4. Highlight Brand z by clicking on it then a. Click on arrow > to transfer this name to the Test Variable Box 5. If one the white square next Friedman is not already checked, click on it to place a check mark there 6. Click on Statistics button at bottom corner of screen a. Click on white square next to Descriptive to place a check mark in the box b. Click on continue button 7. Click OK. Doing this will result in analysis being conducted. These results are below.

The End