27.03.2013 Views

SPSS® 12.0 Command Syntax Reference

SPSS® 12.0 Command Syntax Reference

SPSS® 12.0 Command Syntax Reference

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

SQRT(arg) Square root. SQRT(SIBS) is 1.41 when SIBS equals 2.<br />

Transformation Expressions 39<br />

EXP(arg) Exponential. e is raised to the power of the argument. EXP(VARA) is 7.39<br />

when VARA equals 2.<br />

LG10(arg) Base 10 logarithm. LG10(VARB) is 0.48 when VARB equals 3.<br />

LN(arg) Natural or Naperian logarithm (base e). LN(VARC) is 2.30 when VARC<br />

equals 10.<br />

LNGAMMA(arg) Logarithm (base e) of complete Gamma function.<br />

ARSIN(arg) Arcsine. (Alias ASIN.) The result is given in radians. ARSIN(ANG) is 1.57<br />

when ANG equals 1.<br />

ARTAN(arg) Arctangent. (Alias ATAN.) The result is given in radians. ARTAN(ANG2) is<br />

0.79 when ANG2 equals 1.<br />

SIN(arg) Sine. The argument must be specified in radians. SIN(VARD) is 0.84 when<br />

VARD equals 1.<br />

COS(arg) Cosine. The argument must be specified in radians. COS(VARE) is 0.54 when<br />

VARE equals 1.<br />

Statistical Functions<br />

• Each argument to a statistical function (expression, variable name, or constant) must be<br />

separated by a comma.<br />

• The .n suffix can be used with all statistical functions to specify the number of valid<br />

arguments. For example, MEAN.2(A,B,C,D) returns the mean of the valid values for<br />

variables A, B, C, and D only if at least two of the variables have valid values. The default<br />

for n is 2 for SD, VARIANCE, and CFVAR, and 1 for other statistical functions.<br />

• The keyword TO can be used to refer to a set of variables in the argument list.<br />

SUM(arg list) Sum of the nonmissing values across the argument list.<br />

MEAN(arg list) Mean of the nonmissing values across the argument list.<br />

SD(arg list) Standard deviation of the nonmissing values across the argument list.<br />

VARIANCE(arg list) Variance of the nonmissing values across the argument list.<br />

CFVAR(arg list) Coefficient of variation of the nonmissing values across the argument<br />

list. The coefficient of variation is the standard deviation divided by<br />

the mean.<br />

MIN(arg list) Minimum nonmissing value across the argument list.<br />

MAX(arg list) Maximum nonmissing value across the argument list.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!