= SPSS Print = The '''`PRINT`''' command writes data to an external file. Compare to [[SPSS/Write|WRITE]]. The difference is that `PRINT` will begin each line with a space character, and will delimit values with a space character unless an '''output format''' is specified. <> ---- == Usage == {{{ print outfile="path/to/file" / foo bar baz. print outfile="path/to/file encoding="1252" / foo bar baz. print outfile="path/to/file" / 'a string literal' foo 'another string literal' bar. }}} By default, variables are printed according to their [[SPSS/DataFormats#Print_Format|print format]]. An [[SPSS/DataFormats#Input_and_Output_Formats|alternative format]] can be specified following the variable names. {{{ print outfile="path/to/file" / foo 1-10 (F,2) bar 11-20 (A). print outfile="path/to/file" / foo (F10.2) bar (A10). }}} The `PRINT` command can be used to create [[SPSS/ReadingData#Multi-Record_Data|multi-record data]]. {{{ print outfile="path/to/file" /1 foo /2 bar. }}} ---- == Data Model == The `PRINT` command is queued as a pending transformation. ---- == See also == [[https://www.gnu.org/software/pspp/manual/html_node/PRINT.html|PSPP manual for PRINT]] ---- CategoryRicottone