# Relationship between 2 continuous variables in stats

The tetrachoric/polychoric is made for two categorical variables (read the link often tought in books and (non-math) stat courses) that data has to generate a final . Tie correction is that if for example the ranks are 1 2 2 4 5 6 eg there is a tie. This page shows how to perform a number of statistical tests using SPSS. see What is the difference between categorical, ordinal and interval variables? for . a Fisher's exact test on a 2×2 table, and these results are presented by default. coefficient: the association between two continuous variables. Many statistical For the first of these, the statistical (figure 2), and a value of 0 indicates no.

## Statistical Advisor, Simple Linear Relationships, Two Continuous Variables

Chi-square goodness of fit A chi-square goodness of fit test allows us to test whether the observed proportions for a categorical variable differ from hypothesized proportions. We want to test whether the observed proportions from our sample differ significantly from these hypothesized proportions. Two independent samples t-test An independent samples t-test is used when you want to compare the means of a normally distributed interval dependent variable for two independent groups.

For example, using the hsb2 data filesay we wish to test whether the mean for write is the same for males and females. Because the standard deviations for the two groups are similar In other words, females have a statistically significantly higher mean score on writing An overview of statistical tests in SPSS Wilcoxon-Mann-Whitney test The Wilcoxon-Mann-Whitney test is a non-parametric analog to the independent samples t-test and can be used when you do not assume that the dependent variable is a normally distributed interval variable you only assume that the variable is at least ordinal.

We will use the same data file the hsb2 data file and the same variables in this example as we did in the independent t-test example above and will not assume that write, our dependent variable, is normally distributed.

Why is the Mann-Whitney significant when the medians are equal? Chi-square test A chi-square test is used when you want to see if there is a relationship between two categorical variables. In SPSS, the chisq option is used on the statistics subcommand of the crosstabs command to obtain the test statistic and its associated p-value. Remember that the chi-square test assumes that the expected value for each cell is five or higher. This assumption is easily met in the examples below. The point of this example is that one or both variables may have more than two levels, and that the variables do not have to have the same number of levels.

## What statistical analysis should I use? Statistical analyses using SPSS

In this example, female has two levels male and female and ses has three levels low, medium and high. Please see the results from the chi squared example above.

One-way ANOVA A one-way analysis of variance ANOVA is used when you have a categorical independent variable with two or more categories and a normally distributed interval dependent variable and you wish to test for differences in the means of the dependent variable broken down by the levels of the independent variable. For example, using the hsb2 data filesay we wish to test whether the mean of write differs between the three program types prog.

### What statistical analysis should I use? Statistical analyses using SPSS

The command for this test would be: The mean of the dependent variable differs significantly among the levels of program type. See also Stata Class Notes: Analyzing Data One sample median test A one sample median test allows us to test whether a sample median differs significantly from a hypothesized value.

We will use the same variable, write, as we did in the one sample t-test example above, but we do not need to assume that it is interval and normally distributed we only need to assume that write is an ordinal variable and that its distribution is symmetric.

We will test whether the median writing score write differs significantly from See also Stata Code Fragment: Descriptives, ttests, Anova and Regression Binomial test A one sample binomial test allows us to test whether the proportion of successes on a two-level categorical dependent variable significantly differs from a hypothesized value. See also Chi-square goodness of fit A chi-square goodness of fit test allows us to test whether the observed proportions for a categorical variable differ from hypothesized proportions.

We want to test whether the observed proportions from our sample differ significantly from these hypothesized proportions. To conduct the chi-square goodness of fit test, you need to first download the csgof program that performs this test. You can download csgof from within Stata by typing search csgof see How can I used the search command to search for programs and get additional help?

### Simple Linear Relationships, Two Continuous Variables

Now that the csgof program is installed, we can use it by typing: See also Useful Stata Programs Two independent samples t-test An independent samples t-test is used when you want to compare the means of a normally distributed interval dependent variable for two independent groups.

For example, using the hsb2 data filesay we wish to test whether the mean for write is the same for males and females. In other words, females have a statistically significantly higher mean score on writing Analyzing Data Wilcoxon-Mann-Whitney test The Wilcoxon-Mann-Whitney test is a non-parametric analog to the independent samples t-test and can be used when you do not assume that the dependent variable is a normally distributed interval variable you only assume that the variable is at least ordinal.

You will notice that the Stata syntax for the Wilcoxon-Mann-Whitney test is almost identical to that of the independent samples t-test.

We will use the same data file the hsb2 data file and the same variables in this example as we did in the independent t-test example above and will not assume that write, our dependent variable, is normally distributed.

You can determine which group has the higher rank by looking at the how the actual rank sums compare to the expected rank sums under the null hypothesis. The sum of the female ranks was higher while the sum of the male ranks was lower.

Thus the female group had higher rank.