Line 1: |
Line 1: |
| '''This page is intended as an introduction to some commonly used basic hypothesis tests. Before using any of these, it is important that the concepts behind hypothesis testing are understood. These concepts are explained on [[Hypothesis testing|this page]].'''<br> | | '''This page is intended as an introduction to some commonly used basic hypothesis tests. Before using any of these, it is important that the concepts behind hypothesis testing are understood. These concepts are explained on [[Hypothesis testing|this page]].'''<br> |
| | | |
− | Hypothesis tests are very commonly used in epidemiological investigations, and a wide number of tests are available. These can be classified into groups according to the [[Data types|data types]] in question, according to whether a specific underlying distribution is assumed when performing the test (in which case, the test is known as a '''parametric test'''), and according to whether or not the data are matched or independent (i.e. whether comparisons are being made at the individual level or the group level).<br> | + | Hypothesis tests are very commonly used in epidemiological investigations, and a wide number of tests are available. These can be classified into groups according to the [[Data types|data types]] in question, according to whether a specific underlying distribution is assumed when performing the test (in which case, the test is known as a '''parametric test'''), and according to whether or not the data are matched or independent (i.e. whether comparisons are being made at the individual level or the group level). As described earlier, ''qualitative'' data are not numerical in nature, and include categorical and ordinal data (such as the breed of dog, or the body condition score of a cow). ''Quantitative'' data are numerical, and include variables such as weight, age and height.<br> |
| | | |
| ==Comparing a qualitative variable between different groups== | | ==Comparing a qualitative variable between different groups== |
| ===Chi-square test=== | | ===Chi-square test=== |
| + | The chi-square test is one of the most commonly used hypothesis tests, and allows the comparison of any qualitative exposure with any qualitative outcome (given that certain assumptions are met). As a simple example, it may be used to investigate the effect of previous exposure to substance x on disease experience amongst a group of animals - as shown in the table below: |
| + | {| class="wikitable" |
| + | |- |
| + | | Disease status || Exposed || Unexposed || Total |
| + | |- |
| + | | Diseased || a<sub>1</sub> || a<sub>0</sub> || m<sub>1</sub> |
| + | |- |
| + | | Non-diseased || b<sub>1</sub> || b<sub>0</sub> || m<sub>0</sub> |
| + | |- |
| + | | Total || n<sub>1</sub> || n<sub>0</sub> || n |
| + | |} |
| + | A chi-square test could also be used to investigate whether the body condition score of a horse was associated its lameness score, for example: |
| + | {| class="wikitable" |
| + | |- |
| + | | Lameness score || Body condition score 1-3 || Body condition score 4-6 || Body condition score 7-9 || Total |
| + | |- |
| + | | 0 || a<sub>1</sub> || a<sub>2</sub> || a<sub>3</sub> || m<sub>a</sub> |
| + | |- |
| + | | 1 || b<sub>1</sub> || b<sub>2</sub> || b<sub>3</sub> || m<sub>b</sub> |
| + | |- |
| + | | 2 || c<sub>1</sub> || c<sub>2</sub> || c<sub>3</sub> || m<sub>c</sub> |
| + | |- |
| + | | 3 || d<sub>1</sub> || d<sub>2</sub> || d<sub>3</sub> || m<sub>d</sub> |
| + | |- |
| + | | 4 || e<sub>1</sub> || e<sub>2</sub> || e<sub>3</sub> || m<sub>e</sub> |
| + | |- |
| + | | 5 || f<sub>1</sub> || f<sub>2</sub> || f<sub>3</sub> || m<sub>f</sub> |
| + | |- |
| + | | 6 || g<sub>1</sub> || g<sub>2</sub> || g<sub>3</sub> || m<sub>g</sub> |
| + | |- |
| + | | Total | n<sub>1</sub> || n<sub>2</sub> || n<sub>3</sub> || n |
| + | |} |
| | | |
| ===Fisher's exact test=== | | ===Fisher's exact test=== |