﻿WEBVTT

1
00:00:03.033 --> 00:00:11.199
In this video, you will learn to performa one-way ANOVA using theOne-Way ANOVA task in SAS Studio.

2
00:00:11.200 --> 00:00:17.133
Let’s say that we want to determinewhether age is related to sense of smell.

3
00:00:17.133 --> 00:00:27.666
We can address this question by using a one-
way ANOVA to predict a continuous measure of 
sense of smell from a five-category age variable.

4
00:00:27.666 --> 00:00:38.066
First, click on Tasks in the panel onthe left side of the window. The bottomcategory of tasks is labeled Statistics.

5
00:00:38.066 --> 00:00:48.232
If you do not already see the contentsof the statistics category, double-clickon Statistics to expand the category.

6
00:00:48.233 --> 00:00:58.133
Next, double-click on One-Way ANOVA.The task menu appears to the right.

7
00:00:58.133 --> 00:01:03.733
Now that we have selected a task,we do not need to keep the paneon the left-hand side open.

8
00:01:03.733 --> 00:01:03.766
Click on the Maximize View buttonto close the Tasks pane.

9
00:01:03.766 --> 00:01:09.866
Click on the Maximize View buttonto close the Tasks pane.

10
00:01:09.866 --> 00:01:10.366
Click on the Maximize View buttonto close the Tasks pane.

11
00:01:10.366 --> 00:01:18.099
At a minimum, the One-Way ANOVA taskrequires a data set, a dependent variable,and an explanatory variable.

12
00:01:18.100 --> 00:01:23.900
Click on the icon next to the fieldfor the data set name.

13
00:01:23.900 --> 00:01:31.100
Select a data set for the analysis by double-
clicking on the name of the library and then 
double-clicking on the name of the data set.

14
00:01:31.100 --> 00:01:37.966
We will use the upsit data set from the libsas 
library.

15
00:01:37.966 --> 00:01:49.099
To specify the dependent variable, clickon the plus sign next to Dependentvariable and then click on smell.

16
00:01:49.100 --> 00:02:01.900
To specify the explanatory variable, clickon the plus sign next to Explanatoryvariable and then click on agegroup.

17
00:02:01.900 --> 00:02:10.566
The code window on the right now containsSAS syntax for running a one-way ANOVAwith the SAS Studio defaults.

18
00:02:10.566 --> 00:02:16.499
Because SAS generates codefor our analysis and then updatesthe code as we specify options,

19
00:02:16.500 --> 00:02:22.700
the interactive code generator canserve as a guide for those who wishto learn SAS programming.

20
00:02:22.700 --> 00:02:32.766
Though we could run the current syntax,we will instead examine the OPTIONS tab first.

21
00:02:32.766 --> 00:02:39.766
The OPTIONS tab allows us to specify optional 
tests to be run and to choose plots to be output.

22
00:02:39.766 --> 00:02:48.132
By default, the One-Way ANOVA taskconducts a test for normality, checks for 
homogeneity of variance using Levene’s test,

23
00:02:48.133 --> 00:02:56.633
conducts Welch’s variance-weighted ANOVA,and performs pairwise comparisons betweenall levels of the explanatory variable

24
00:02:56.633 --> 00:03:03.166
using the Tukey method to controlfor Type I experimentwise error rate.

25
00:03:03.166 --> 00:03:08.499
These tests can be suppressed, and in somecases, the testing methods can be changed.

26
00:03:08.500 --> 00:03:08.533
For example, instead of using Levene’stest for homogeneity of variance, wemight use the Brown & Forsythe test.

27
00:03:08.533 --> 00:03:13.666
For example, instead of using Levene’stest for homogeneity of variance, wemight use the Brown & Forsythe test.

28
00:03:13.666 --> 00:03:16.299
For example, instead of using Levene’stest for homogeneity of variance, wemight use the Brown & Forsythe test.

29
00:03:16.300 --> 00:03:22.766
By default, the One-Way ANOVA taskproduces a box plot for each valueof the explanatory variable.

30
00:03:22.766 --> 00:03:31.066
Let’s also request diagnostics plots byclicking the box next to Diagnostics plot.

31
00:03:31.066 --> 00:03:39.532
This is generally a good idea, as the resultingplots provide a method for graphicallychecking for normality and homoscedasticity.

32
00:03:39.533 --> 00:03:52.799
Now that we have specified the optionsfor our analysis, we run the programby clicking on the Run button.

33
00:03:52.800 --> 00:03:56.300
The right side of the screenshould now display the results.

34
00:03:56.300 --> 00:04:06.900
In order to better see our results,we can click on the Code/Resultsbutton in the top left of the screen.

35
00:04:06.900 --> 00:04:15.566
This maximizes the Code/Results window.To return to the previous view, you couldsimply click on Split.

36
00:04:15.566 --> 00:04:25.832
The window now shows the syntax for our 
analysis, rather than the results. To returnto the results, click on the RESULTS tab.

37
00:04:25.833 --> 00:04:30.899
Alternatively, we could click on the LOG tab to see the log.

38
00:04:30.900 --> 00:04:35.866
The output begins by listing thelevels of the explanatory variable.

39
00:04:35.866 --> 00:04:41.132
The next table tells us that thedata set contains 180 observations.

40
00:04:41.133 --> 00:04:48.933
Because the data set doesn’t containmissing data, all 180 observationswere included in the analysis.

41
00:04:48.933 --> 00:04:55.766
Next comes the overall analysisof variance table, which providesa test of the overall ANOVA model.

42
00:04:55.766 --> 00:05:02.299
The test is significant, indicating that sense of 
smell significantly differs across the age groups.

43
00:05:02.300 --> 00:05:13.166
Below we have the R-square value, the 
coefficient of variation, the root mean square 
error, and the mean of the dependent variable.

44
00:05:13.166 --> 00:05:17.199
The next two tables provide testsfor each effect in the analysis.

45
00:05:17.200 --> 00:05:28.800
Because this is a one-way ANOVA, however, 
these two tables provide redundant informationfrom the overall analysis-of-variance table.

46
00:05:28.800 --> 00:05:38.733
Because we checked the Diagnosticsbox on the OPTIONS tab, SAS providesus with a panel of diagnostics plots.

47
00:05:38.733 --> 00:05:45.299
SAS then displays the default box plot.

48
00:05:45.300 --> 00:05:51.266
Levene’s test for homogeneity of variance ispresented next, followed by Welch’s ANOVA.

49
00:05:51.266 --> 00:05:57.966
Because Levene’s test is significant, we should 
favor Welch’s test over the regular ANOVA test.

50
00:05:57.966 --> 00:06:05.999
Like the overall test, Welch’stest is also significant.

51
00:06:06.000 --> 00:06:14.833
The next section of output contains pairwisecomparisons between all of the age groups.

52
00:06:14.833 --> 00:06:24.033
The final piece of output provides testsfor normality of residuals. All four testsindicate non-normality of the residuals.

53
00:06:24.033 --> 00:06:31.966
Based on these tests, we may wantto consider re-analyzing the datausing a robust analysis of variance.

54
00:06:31.966 --> 00:06:40.599
This concludes our video on performinga one-way ANOVA in SAS Studio.

