The "fine manual" entry for WRITE (under MATRIX - END MATRIX) is a bit short
on examples, and the /FIELD sub-command is somewhat confusing. But the
following seems to work okay.
data list list / var1 to var3 (3f5.0).
1 7 13
2 8 14
3 9 15
4 10 16
5 11 17
6 12 18
GET X /VARIABLES VAR1.
/OUTFILE = 'C:\temp\neu.txt'
/FIELD = 1 TO 10 BY 5
/FORMAT = f5.0.
> Thanks a lot for your answers!
> With the first command (Compute) I had no success?!
> The second hint works but not satisfying..
> Here it is (in case of my example)..
> GET X /VARIABLES VAR1.
> WRITE RESHAPE(x,3,2)
> / OUTFILE=' D:\....\test\neu.txt'
> / FIELD = 1 TO 2 BY 2.
> Print x. *for immediate correction in the SPSS-output
> END MATRIX.
> The output (now as .txt file) is still a columnvector, but why?
> I assume that I did a mistake using the Field subcommand?!
> Hope you can help me once again!
> Thanks a million!
"When all else fails, RTFM."
NOTE: My Hotmail account is not monitored regularly.
To send me an e-mail, please use the address shown above.
View this message in context: http://spssx-discussion.1045642.n5.nabble.com/export-variable-as-matrix-ASCII-tp4868248p4869991.html
Sent from the SPSSX Discussion mailing list archive at Nabble.com.
To manage your subscription to SPSSX-L, send a message to
LISTSERV@LISTSERV.UGA.EDU (not to SPSSX-L), with no body text except the
command. To leave the list, send the command
For a list of commands to manage subscriptions, send the command