PROC MEANS
calculates the
t statistic as
where

is the sample mean,

is the number of nonmissing values for a variable,
and

is the sample standard deviation. Under the null
hypothesis, the population mean equals

. When the data values are approximately normally
distributed, the probability under the null hypothesis of a
t statistic
as extreme as, or more extreme than, the observed value (the
p-value)
is obtained from the
t distribution with

degrees of freedom. For large

, the
t statistic is asymptotically
equivalent to a
z test.
When you use the WEIGHT
statement or WEIGHT= in a VAR statement and the default value of VARDEF=,
which is DF, the Student's
t statistic is calculated
as
where

is the weighted mean,

is the weighted standard deviation, and

is the weight for

observation. The

statistic is treated as having a Student's
t distribution
with

degrees of freedom. If you specify the EXCLNPWGT
option in the PROC statement, then

is the number of nonmissing observations when the
value of the WEIGHT variable is positive. By default,

is the number of nonmissing observations for the
WEIGHT variable.