IN Subcommand (MATCH FILES command)
IN creates
a new variable in the resulting file that indicates whether a case
came from the input file named on the preceding FILE subcommand. IN applies only to the file specified on the immediately preceding FILE subcommand.
-
INcan be used only for a nonparallel match or table lookup. -
INhas only one specification—the name of the flag variable. - The variable created by
INhas the value 1 for every case that came from the associated input file and the value 0 if the case came from a different input file. - Variables created by
INare automatically attached to the end of the resulting file and cannot be dropped. IfFIRSTorLASTis used, the variable created byINprecedes the variables created byFIRSTorLAST.
Example
MATCH FILES FILE='/data/week10.sav'
/FILE='/data/week11.sav'
/IN=INWEEK11
/BY=EMPID.
-
INcreates the variable INWEEK11, which has the value 1 for all cases in the resulting file that had values in the input file week11.sav and the value 0 for those cases that were not in file week11.sav.