Hello,
I am currently working to try to import data into SPSS. I created the .dat file with StatTransfer from the Stata-formatted file. Looking at the .sps file, it appears that one of my variables which should be 70 characters (and is specified as such in the EpiData Manager) contains only 1 character.
I noticed this issue while rewriting the syntax to pull the data into SPSS. Our variables are embedded within the string variables (e.g., EPIVAR = 56 -> VAR1 = 5 VAR2 = 6).
We used spaces as missing data. Could it be an issue with missing data? It shouldn't be, if the field is specified as 70 characters!
How can this be? It is making me very anxious.
There are a number of issues in relation to export and import to SPSS (and SAS plus Stata)
These are for text fields related to the use or lack of use of utf-8 representation. I am not sure how Stattransfer handles text encoding, so some experimentation with exports and specification of these would be welcomed.
I am aware that one user managed via placing the text fields at the end of the dataform and asked for a "point by point" recipe, but have not received any answer yet.
In other words - please try in relation to specification of character encoding and let us know of the results on the list. (we do not have access to SPSS)
regards Jens Lauritsen EpiData Association
On 07/17/2013 03:25 AM, epidata-list@lists.umanitoba.ca wrote:
Hello,
I am currently working to try to import data into SPSS. I created the .dat file with StatTransfer from the Stata-formatted file. Looking at the .sps file, it appears that one of my variables which should be 70 characters (and is specified as such in the EpiData Manager) contains only 1 character.
I noticed this issue while rewriting the syntax to pull the data into SPSS. Our variables are embedded within the string variables (e.g., EPIVAR = 56 -> VAR1 = 5 VAR2 = 6).
We used spaces as missing data. Could it be an issue with missing data? It shouldn't be, if the field is specified as 70 characters!
How can this be? It is making me very anxious. _______________________________________________ EpiData-list mailing list EpiData-list@lists.umanitoba.ca http://lists.umanitoba.ca/mailman/listinfo/epidata-list
I am familiar with Stat/Transfer. It tends to truncate variables to the longest length of data filled into the field - at least that has been my experience when using it to convert EpiData files to SAS. So if you have missing data for that field in every row in your data, it will truncate it to a length of 1, even if you've specified the field as having a length of 70. You could confirm whether this is the problem by filling up the variable in one of the rows in Stata, re-converting it using Stat/Transfer and then seeing if the length has changed.
Katie
-----Original Message----- From: epidata-list@lists.umanitoba.ca [mailto:epidata-list@lists.umanitoba.ca] Sent: Wednesday, July 17, 2013 1:37 AM To: epidata-list@lists.umanitoba.ca Subject: Re: [EpiData-list] Field Length Issue
There are a number of issues in relation to export and import to SPSS (and SAS plus Stata)
These are for text fields related to the use or lack of use of utf-8 representation. I am not sure how Stattransfer handles text encoding, so some experimentation with exports and specification of these would be welcomed.
I am aware that one user managed via placing the text fields at the end of the dataform and asked for a "point by point" recipe, but have not received any answer yet.
In other words - please try in relation to specification of character encoding and let us know of the results on the list. (we do not have access to SPSS)
regards Jens Lauritsen EpiData Association
On 07/17/2013 03:25 AM, epidata-list@lists.umanitoba.ca wrote:
Hello,
I am currently working to try to import data into SPSS. I created the .dat file with StatTransfer from the Stata-formatted file. Looking at the .sps file, it appears that one of my variables which should be 70 characters (and is specified as such in the EpiData Manager) contains only 1 character.
I noticed this issue while rewriting the syntax to pull the data into SPSS. Our variables are embedded within the string variables (e.g., EPIVAR = 56 -> VAR1 = 5 VAR2 = 6).
We used spaces as missing data. Could it be an issue with missing data? It shouldn't be, if the field is specified as 70 characters!
How can this be? It is making me very anxious. _______________________________________________ EpiData-list mailing list EpiData-list@lists.umanitoba.ca http://lists.umanitoba.ca/mailman/listinfo/epidata-list
participants (1)
-
epidata-list@lists.umanitoba.ca