[wiki:FsTutorial top] | [wiki:FsTutorial/GroupAnalysis previous]

Specify contrast vectors to test hypotheses

The design matrix generated from the FSGD file consists of the last three columns of:

SubjectID  Male  Female  Age

   004      1      0     22
   008      0      1     88
   017      1      0     25
   021      1      0     22
   032      1      0     79
   039      0      1     69
   040      0      1     24
   045      0      1     78
   049      1      0     19
   067      1      0     71
   073      1      0     77
   074      1      0     85
   080      1      0     23
   084      1      0     21
   091      0      1     23
   092      1      0     29
   093      0      1     22
   095      0      1     70
   097      1      0     74
   099      0      1     93
   102      0      1     82
   103      0      1     66
   106      1      0     27
   108      1      0     28
   111      0      1     81
   114      0      1     87
   123      0      1     69
   124      0      1     30
   128      1      0     90
   129      0      1     65
   130      1      0     68
   131      0      1     80
   133      0      1     73
   136      0      1     78
   138      0      1     26 
   140      0      1     18
   141      0      1     20
   144      1      0     78
   145      1      0     80 
   149      1      0     77

There are three regressors. The first regressor codes membership in the Male group. The second codes for membership in the Female group. The last is the age for the subject. The contrast vector for testing the given subjects for straight correlation between thickness and age can be specified as:

[0 0 1]

The contrast vector has three components because there are three regressors.

Try constructing the contrast vector for testing the same data for difference between males and females independent of age. BR

[wiki:FsTutorial/MaleFemaleContrastSolution Click here for the answer.]