to: Index and Menu

Simple Interactive Statistical Analysis


Go to procedure

Data Input for t-test procedures

Explanation.

Provides more easy input for SISA's procedures which do t-test analysis. It concerns the following procedures:

This procedure concerns three webpages which follow on one another.

  1. Data specification and input
  2. Copy of the procedure input page
  3. Results of the analysis

Input.

For the two independent samples procedure the first variable in the first data column is considered to be a dichotomous factor variable which explains an outcome or dependent variable in the second column. Set a value in the top "factor values" box which splits the data into two groups. For a continuous interval outcome variable leave the value "ContV" in the "Outcome values" box. For a dichotomous proportion outcome value give a value in the "Outcome values" box which splits the outcome variable into two. Hitting the "make input" button sends you to the t-test input box.

For the single sample procedure set a very low value in the top "factor values" box so that only one group is left. Leave the value "ContV" in the "Outcome values" box. Give the population or historical value with which you want to compare your sample in the t-test input box which you get after hitting the "make input" button. For a dichotomous outcome value you should use the binomial procedure.

For the pairwise t-test you should have two continuous variables which relate to two quantitative measurements on the same variable on the same person. Leave the "ContV" in the "Outcome values" box and insert a non numerical value in the top "factor values" box or leave this box empty. After hitting the "make input" button the program calculates the mean change and the standard deviation of this change and sends you to a copy of the pairwise procedure page for further testing. For two measurements on a dichotomus value, for example, if you study the change overtime in the absence or presence of a disease, you should use the McNemar procedure.

The data for all this can be copied for example from a spreadsheet or word processor or the data can be typed in manually into the "Input data here:" field. The numbers in the input field have to be separated by spaces, or returns, or semicolons, or colons, or tabs, but can NOT be separated by comma’s or full stops. The data in the input field is read row wise, so first the data in the first row followed by the second, the third and all the other rows.

Read weights considers that every third value or the third column is the case weight of the previous two values. The case weight must be numerical, if not the case with its values is ignored and counted as invalid. Weighing corrected t-test info is produced. For a discussion of data weighing and the correction applied please read this paper.

Solve SPSS problems. Delete cases with the data sequence -cariage return-line feed-tab- and the sequence -tab-cariage return-line feed-. Wil mostly solve the problem of system missing values in data copied and pasted from SPSS. Might cause other problems.

Limitations.

Data limitations depend on the speed of your computer and other surprising variables. The formatting and tabulating of large datasets might take a while in which case there might be warnings, just select "continue" and in the end the computer will get there. Cases with unknown characters in the values are skipped, unknown are all non numerical characters except for the separator characters mentioned above. Information on the number of cases read and the number of invallid cases can be found in the address bar in the top of your browser.

Example of input:.

1 25
2 28
2 33
1 24
2 25
1 22
2 34
2 25
. 25
2 21
1 28
1 27
2 25
2 21
2 34

A 15 cases two variables in two columns data set is shown above. It concerns an indicator (factor) variable in the first column indicating males with the value 1 and females with the value 2. For one case the gender is missing. BMI is the dependent variable in the second column.

After pasting the data into the input box we do a test to see whether there is a difference in mean BMI between males and females. For this we dichotomize the independent explanatory factor variable in the first column into males and females by maintaining the default of 2 in the top "factor values" box. Php sends the following info to the t-test input page:

"t-testCopy.php?u1=25.2&u2=27.3&n1=5&n2=9&sd1=2.38&sd2=5.22&RowSplit=2&ColSplit=ContV&read=15&invallid=1"

Mean BMI for n1=5 males u1=25.2 (sd 2.38); mean BMI for n2=9 females u2=27.3 (sd 5.22). The address bar further shows that the program read 15 cases of which the one without the respondent's gender was invallid.

Following we want to know percentages overweight, men and woman. We dichotomize BMI into normal weight, BMI less then 25, and overweight, BMI 25 and above. Php sends the following info to the t-test input page:

"t-testCopy.php?u1=0.4&u2=0.222&n1=5&n2=9&sd1=0&sd2=0&RowSplit=2.00&ColSplit=25&read=6.5&invallid=1"

The t-test shows that 40% (u1=0.4*100) of the males are normal weigth, against 22.2% (u2=0.22*100) of the females.

Lastly, we want to know if our sample differs significantly from the population average. We set the split value in the "factor values" box to 0, to categorize all respondents into one group, and leave the value "ContV" in the "Outcome values" box. Php sends the following info to the t-test input page:

"t-testCopy.php?u1=Exp.Here!&u2=26.57&n1=0&n2=14&sd1=0&sd2=4.43&RowSplit=0&ColSplit=b&read=15&invallid=1"

Mean BMI for all n2=14 respondents equals u2=26.57 (sd=4.43). You can input the expected value for the whole population behind the u1 parameter and reload or put it in the expected value input box on the t-test input page.

Lastly, for a demonstration of the pairwise t-test the example on the pairwise help page is used. We input the data of the table on this helppage into the input field, give both the "factor values" and the "Outcome values" box a non numerical value. Php sends the following info to the pairwise input page:

"pairwiseCopy.php?mean=5.8&n=10&sd=5.43&ttest&RowSplit=a&ColSplit=b&read=10&invallid=0"

Mean change 5.8, number of cases 10, sd of change 5.43, perform t-test, send to pairwise, 10 cases read, none invallid.

TOP of page

Go to procedure

to: Index and Menu

All software and text copyright by SISA