Read matrix data from csv file

Moderators: statman, Analyst Techy, andris, Fierce, GerineL, Smash

Posts: 11
Joined: Mon Apr 16, 2012 12:25 pm

Read matrix data from csv file

Postby gandalf » Tue Dec 02, 2014 9:38 am


I have some data in a .csv file. The first row and the first column have identifier fields. So, I am guessing I do not need to import these fields. The matrix size is 3029 X 3029 barring the first row and column. I am trying to read this into SPSS using the following syntax. However, I am getting some errors.

Code: Select all


READ A /FILE="C:\Desktop\matrices\AM.csv" /FIELD = 2 to 3030 /size= (3029;3029).

This is the error I am getting

>Error # 12302 in column 143. Text: ;
>Syntax error.
>Execution of this command stops.
Token ) expected.

The MATRIX statement skipped.

Run MATRIX procedure:

------ END MATRIX -----

Can some please guide me in the right direction? Thanks in advance.

Who is online

Users browsing this forum: No registered users and 3 guests