* chapter_7_table_23 The following data represent the relative effectiveness of three forms of psychotherapy for alleviating depression. Fifteen individuals were randomly assigned to one of three groups. After the fact, these individuals where placed into one of three categories based on the severity of their depression. Thus, this data set represents a 3 by 3 nonorthogonal factorial design with post hoc blocking. This analysis proceeds in the typical way for factorial designs. However, because the design is nonorthogonal, care must be taken to ensure the desired type of sums of squares is used. Here we have used three model statements (in three different applications of the GLM procedure) to illustrate several types of sums of squares. Notice that for the Type I sums of squares the order the effect is included on the model statement line makes matters. ; LIBNAME md 'd:\data files by type\sas data files\tables'; Data c7t23; SET md.chapter_7_table_23; * Here we perform Type III and Type II sums of squares. Notice how you can specify multiple types of sums of squares with only one model statement line.; PROC GLM DATA=c7t23; CLASS therapy severity; MODEL score = therapy severity therapy*severity / SS3 SS2; RUN; * Here we use the Type I sums of squares and enter severity first. We do this by placing it before therapy on the model statement line.; PROC GLM DATA=c7t23; CLASS therapy severity; MODEL score = severity therapy severity*therapy / SS1; RUN; * Here we use the Type I sums of squares and enter therapy first. We do this by placing it before severity on the model statement line.; PROC GLM DATA=c7t23; CLASS therapy severity; MODEL score = severity therapy therapy*severity / SS1; RUN;