pspp-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

reading csv data set


From: someone
Subject: reading csv data set
Date: Sun, 31 Dec 2017 09:15:03 -0500

Could I ask what syntax you used to read my csv data set?

Thanks again for all your feedback

Gene



-----Original Message-----
From: someone <address@hidden>
To: public.ftr <address@hidden>; pspp-users <address@hidden>
Sent: Sat, Dec 30, 2017 7:35 pm
Subject: reading csv data set

Thanks. I'm not really clear on what you mean. 
"integrating several field delimiter into a single one"
"Only when you stop the last functionality the importation went as expected."

Can you please explain or give example?

Thanks for your help.

Gene


-----Original Message-----
From: ftr public <address@hidden>
To: someone <address@hidden>; pspp-users <pspp-address@hidden>
Sent: Sat, Dec 30, 2017 4:09 pm
Subject: Re: reading csv data set

Hi,
I imported the ods data file with the following syntax:
GET DATA /TYPE=ODS
/FILE="(file path)\pd_data_cia.ods"
/READNAMES=ON.
and it worked.

I also imported the csv file into Libreoffice Calc to see the data. When using the comma as a field delimiter I realised that the function of integrating several field delimiter into a single one made that the imported data and the column headers did not fit : there were too few data columns. Only when you stop the last functionality the importation went as expected.
 
Thanks for the idea of a direct importation of ods files into PSPP of which I was unaware.

- ftr

On 30/12/2017 18:49, someone wrote:
Hi

Thanks for the response. I imported the ods file through the gui interface. That is, 
file
import data
went to my directory, clicked on the ods data set
next
got the screen importing spreadsheet data
next
apply

I did notice that, when I read the ods file, pspp, in the output viewer, showed this

get data
 /type=ods
 /file="C:\Users\Owner\Documents\icaap\data\testdata\PD_data_cia.ods"
 /sheet=index 1
 /readnames=on
 /cellrange=range "a1:al236".


So to try to read the csv file, I tried this

get data
  / type=txt 
  / file="C:\Users\Owner\Documents\icaap\data\testdata\PD_data_cia.csv"
  / arrangement=delimited
  / firstcase=2
  / delimiters=",".

now, only one error:
.19: error: Syntax error at end of command: expecting '/'.

Does that help?

Thanks

Gene



-----Original Message-----
From: ftr public <address@hidden>
To: pspp-users <address@hidden>
Sent: Sat, Dec 30, 2017 10:05 am
Subject: Re: reading csv data set

Hi Gene,
I also tried to import the csv data file and got into difficulties.
How did you import the ods file ? Can you send the syntax ?
What is funny is that the country data set has no case, i.e. country, names.
Regards,
ftr

On 30/12/2017 01:00, someone wrote:
Hi all

I'm trying to read in a data set, in csv. I also have xls and ods versions, all here

All the files I'm looking at are versions of the pd_data_cia data set.

I -have- imported the ods version, but when I try to import the csv version, I just get blank. I go to file, import data, go to my directory, and all the files are listed. I click on pd_data_cia.cvs, and then on the upper left of the screen, where it says select file to import, I cannot select any of the options.

I am using pspp version 1.0.1-g818227, downloaded a couple of days ago from here
I'm on windows, 64 bit operating system, I think windows 10.

I also tried using the command line, and, well, not doing it right, perhaps someone can help? These are the lines I tried

get data
  / type=txt 
  / file=’C:\Users\Owner\Documents\icaap\data\testdata\PD_data_cia.csv’
  / arrangement=delimited
  / firstcase=2
  / delimiters=","

Thanks

Gene Shackman



reply via email to

[Prev in Thread] Current Thread [Next in Thread]