|
DataMuseum.dkPresents historical artifacts from the history of: DKUUG/EUUG Conference tapes |
This is an automatic "excavation" of a thematic subset of
See our Wiki for more about DKUUG/EUUG Conference tapes Excavated with: AutoArchaeologist - Free & Open Source Software. |
top - metrics - downloadIndex: T t
Length: 2705 (0xa91) Types: TextFile Names: »trans«
└─⟦87ddcff64⟧ Bits:30001253 CPHDIST85 Tape, 1985 Autumn Conference Copenhagen └─⟦this⟧ »cph85dist/stat/doc/cat/trans«
TRANS(1) UNIX User's Manual TRANS(1) NAME trans - transform numerical input columns SYNOPSIS trans operations DESCRIPTION _▶08◀T_▶08◀r_▶08◀a_▶08◀n_▶08◀s allows a series of simple transformations on numerical input columns. Each command line option defines a simple transformation with a single character operation and a numerical operand. The final value is printed by itself on a line, thus, the output of _▶08◀t_▶08◀r_▶08◀a_▶08◀n_▶08◀s is always a single column. These output columns can be combined using _▶08◀a_▶08◀b_▶08◀u_▶08◀t. Operations = value = operand. The output value is set to the fol- lowing operand. This operation is usually the first on a line. Without it, the output value defaults to the input line number. + value = value + operand. - value = value - operand. * value = value * operand. / value = value / operand. ^ value = value ^ operand. This is the power function, value to the operand exponent. a value = abs (value). f value = floor (value). c value = ceil (value). s value = sqrt (value). l value = log (value). L value = log10 (value). e value = exp (value). Operands xN The letter 'x' followed by an integer column number is replaced by the input column value. N A number, integer or floating point, is used as the Printed 5/30/85 March 5, 1985 1 TRANS(1) UNIX User's Manual TRANS(1) operand to the operation. EXAMPLE The following produces the product of the first two columns added to the third column. Note that the quotes are required because the * is a special character in the shell. trans =x1 "*x2" +x3 The following produces the logarithm of the square root of twice column 2. trans =x2 "*2" sqrt log Note that only the first character of the unary operations sqrt and log are meaningful. DIAGNOSTICS At most 100 columns are allowed. At most 20 operations are allowed. Illegal operations are caught before they are done. SEE ALSO unixstat(1), abut(1), dm(1) AUTHOR Gary Perlman BUGS Fields longer than 20 characters are truncated without com- ment. For numerical fields, this is not a problem. _▶08◀T_▶08◀r_▶08◀a_▶08◀n_▶08◀s is a primitive replacement for systems that cannot compile _▶08◀d_▶08◀m. KEYWORDS statistics, data analysis, data manipulation/transformation Printed 5/30/85 March 5, 1985 2