The t-statistic is a concept used in the field of statistics and is categorized as a standardized statistic (a mutually agreed upon value determined by statisticians). The t-statistic is used to figure the difference between the sample statistic (the value you are running a statistical test on) and the null value (unknown value). For a hypothesis using the means of your sample statistic, you would turn to this formula for calculating the t-value:
t = (Sample statistic – Null value)/Null standard error.
While using this formula to find the t-value for your sample statistic, keep in mind that x-bar is your sample mean. X-bar is a statistic representing your sample’s mean value while also approximating the population mean. For example, if you were to take a sample of lizards with long and short tails from a larger population, the mean tail length for the lizards in your sample should estimate the true mean value of lizard tail-lengths for the entire population. Therefore, x-bar is simply a sample mean used to estimate the value of a larger population. X-bar is the representative of the population, in a way.
The Null value referrers to an unknown value that you are testing both your H0 and H1 hypotheses against in order to find the t-value. The Null value may be given, but more often times it is undisclosed and assumed to be 0.
The standard error is found in the denominator of the formula and can be calculated by dividing s by the square root of n. The variable n is your population size while s is your standard deviation. You can calculate the standard deviation of your sample by hand or you can use descriptive statistics in Microsoft Excel to determine it for you.
If your hypotheses deal with means, you can use your t-statistic to calculate the p-value, which gives you an idea of how much evidence you can stack against your null hypothesis. If your hypotheses involves proportions, then you will use a z-statistic. Always remember, t-statistic goes with means because it’s “tough,” and z-statistic is used for proportions.
The easiest way to obtain your p-value using your newly calculated t-statistic, is to open up Microsoft Excel and click under “functions” and then find the “TDIST” option. You will provide X, which is the value of your t-statistic, your degrees of freedom, and you will inform the program whether this is a one-tailed test or a two-tailed test. To determine whether your test is one-tailed or two-tailed, observe your H1. If H1 is less than or greater than the Null value, it will be a one-tailed test and you simply enter a “1” in the data field. If H1 is not equal to the Null value, it will be a two-tailed test and therefore you will enter a “2” into the data field. Excel will then deposit your p-value into a blank cell on the worksheet you have open.
References: “Mind on Statistics, 3rd edition” and my personal biostatistics notes.