SPSS File Info Dictionary

classic Classic list List threaded Threaded
8 messages Options
Reply | Threaded
Open this post in threaded view
|

SPSS File Info Dictionary

Joel_Rivard
Hi folks,

 

I've been reading through the archive listserv about the "Display File Information" command. I've been using SPSS 11.0 for the past few years and have used the "File Info" command numerous times to create a dictionary. I've recently installed SPSS 14 and can't seem to create the same type of dictionary as in SPSS 11.0.  The following type of dictionary is what I would like to obtain.  

 

SURVMNTH  Survey month of data collection                                     3

          Print Format: F2

          Write Format: F2

 

          Value    Label

 

              1    January 2000

              2    February 2000

              3    March 2000

              4    April 2000

              5    May 2000

              6    June 2000

              7    July 2000

              8    August 2000

              9    September 2000

             10    October 2000

             11    November 2000

             12    December 2000

 

LANINT    Language of interview                                               4

          Print Format: F1

          Write Format: F1

 

          Value    Label

 

              1    English

              2    French

 

I've tried some of the syntax that was posted on the listserv and none of them gave me the type of dictionary that I want.  Is there a specific syntax command that should be used to obtain this type of dictionary?  If not, can we request that this feature be brought back since it was available in SPSS 11.0?

 

Thanks,

Joel

                         

Joël Rivard

Data Technician

Maps, Data & Government Information Centre

Carleton University Library

(613) 520-2600 ext.1685

[hidden email]

 
Reply | Threaded
Open this post in threaded view
|

Re: SPSS File Info Dictionary

Cleland, Patricia (EDU)
Joel,

I had this same problem last fall when I upgraded to v14 and discovered that I couldn't produce the data dictionary in the format I wanted.

After discussions with a number of SPSS staff, I learned that you can't do it in v14 with either FILE INFO or DISPLAY DICTIONARY because SPSS 'improved' the output of those commands as of v14. My workaround has been to keep my copy of v13 available and use it to produce data dictionaries.

If you have installed the Python programmability module, you can use the syntax below that I modified (with a LOT of help from Jon Peck of SPSS!):

-----------------------------------------------------
*print file name, number of vars in file and var information  in file order.
BEGIN PROGRAM.
import spss, spssaux, DisplayDict
print "Data Dictionary for:", spssaux.GetDatasetInfo()
print "Number of Variables:", spss.GetVariableCount()
DisplayDict.dictionary(alphaorder=False)
END PROGRAM.
----------------------------------------


As Richard Ristow once said,"Ah, SPSS, the simple things that you make hard, sometimes".

HTH

Patricia Cleland


-----Original Message-----
From: SPSSX(r) Discussion [mailto:[hidden email]] On Behalf Of Joel_Rivard
Sent: February 15, 2007 9:56 AM
To: [hidden email]
Subject: SPSS File Info Dictionary

Hi folks,



I've been reading through the archive listserv about the "Display File Information" command. I've been using SPSS 11.0 for the past few years and have used the "File Info" command numerous times to create a dictionary. I've recently installed SPSS 14 and can't seem to create the same type of dictionary as in SPSS 11.0.  The following type of dictionary is what I would like to obtain.



SURVMNTH  Survey month of data collection                                     3

          Print Format: F2

          Write Format: F2



          Value    Label



              1    January 2000

              2    February 2000

              3    March 2000

              4    April 2000

              5    May 2000

              6    June 2000

              7    July 2000

              8    August 2000

              9    September 2000

             10    October 2000

             11    November 2000

             12    December 2000



LANINT    Language of interview                                               4

          Print Format: F1

          Write Format: F1



          Value    Label



              1    English

              2    French



I've tried some of the syntax that was posted on the listserv and none of them gave me the type of dictionary that I want.  Is there a specific syntax command that should be used to obtain this type of dictionary?  If not, can we request that this feature be brought back since it was available in SPSS 11.0?



Thanks,

Joel



Joël Rivard

Data Technician

Maps, Data & Government Information Centre

Carleton University Library

(613) 520-2600 ext.1685

[hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: SPSS File Info Dictionary

Peck, Jon
The DisplayDict module gives you a lot of flexibility about exactly what output you want, and the current version, which did not exist when Patricia started with this, can include simple statistics for the variables integrated with the dictionary information.

-Jon Peck

-----Original Message-----
From: SPSSX(r) Discussion [mailto:[hidden email]] On Behalf Of Cleland, Patricia (EDU)
Sent: Thursday, February 15, 2007 1:56 PM
To: [hidden email]
Subject: Re: [SPSSX-L] SPSS File Info Dictionary

Joel,

I had this same problem last fall when I upgraded to v14 and discovered that I couldn't produce the data dictionary in the format I wanted.

After discussions with a number of SPSS staff, I learned that you can't do it in v14 with either FILE INFO or DISPLAY DICTIONARY because SPSS 'improved' the output of those commands as of v14. My workaround has been to keep my copy of v13 available and use it to produce data dictionaries.

If you have installed the Python programmability module, you can use the syntax below that I modified (with a LOT of help from Jon Peck of SPSS!):

-----------------------------------------------------
*print file name, number of vars in file and var information  in file order.
BEGIN PROGRAM.
import spss, spssaux, DisplayDict
print "Data Dictionary for:", spssaux.GetDatasetInfo()
print "Number of Variables:", spss.GetVariableCount()
DisplayDict.dictionary(alphaorder=False)
END PROGRAM.
----------------------------------------


As Richard Ristow once said,"Ah, SPSS, the simple things that you make hard, sometimes".

HTH

Patricia Cleland


-----Original Message-----
From: SPSSX(r) Discussion [mailto:[hidden email]] On Behalf Of Joel_Rivard
Sent: February 15, 2007 9:56 AM
To: [hidden email]
Subject: SPSS File Info Dictionary

Hi folks,



I've been reading through the archive listserv about the "Display File Information" command. I've been using SPSS 11.0 for the past few years and have used the "File Info" command numerous times to create a dictionary. I've recently installed SPSS 14 and can't seem to create the same type of dictionary as in SPSS 11.0.  The following type of dictionary is what I would like to obtain.



SURVMNTH  Survey month of data collection                                     3

          Print Format: F2

          Write Format: F2



          Value    Label



              1    January 2000

              2    February 2000

              3    March 2000

              4    April 2000

              5    May 2000

              6    June 2000

              7    July 2000

              8    August 2000

              9    September 2000

             10    October 2000

             11    November 2000

             12    December 2000



LANINT    Language of interview                                               4

          Print Format: F1

          Write Format: F1



          Value    Label



              1    English

              2    French



I've tried some of the syntax that was posted on the listserv and none of them gave me the type of dictionary that I want.  Is there a specific syntax command that should be used to obtain this type of dictionary?  If not, can we request that this feature be brought back since it was available in SPSS 11.0?



Thanks,

Joel



Joël Rivard

Data Technician

Maps, Data & Government Information Centre

Carleton University Library

(613) 520-2600 ext.1685

[hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: SPSS File Info Dictionary

Joel_Rivard
Thanks Patricia and Jon for getting back to me so quickly,

Looks like we'll be installing the Python programmability module that you mentionned (DisplayDict module). It seems like the best solution out there.

Thanks again,
Joel

Joël Rivard
Data Technician
Maps, Data & Government Information Centre
Carleton University Library
(613) 520-2600 ext.1685
[hidden email]

-----Original Message-----
From: SPSSX(r) Discussion [mailto:[hidden email]] On Behalf Of Peck, Jon
Sent: Thursday, February 15, 2007 3:27 PM
To: [hidden email]
Subject: Re: SPSS File Info Dictionary

The DisplayDict module gives you a lot of flexibility about exactly what output you want, and the current version, which did not exist when Patricia started with this, can include simple statistics for the variables integrated with the dictionary information.

-Jon Peck

-----Original Message-----
From: SPSSX(r) Discussion [mailto:[hidden email]] On Behalf Of Cleland, Patricia (EDU)
Sent: Thursday, February 15, 2007 1:56 PM
To: [hidden email]
Subject: Re: [SPSSX-L] SPSS File Info Dictionary

Joel,

I had this same problem last fall when I upgraded to v14 and discovered that I couldn't produce the data dictionary in the format I wanted.

After discussions with a number of SPSS staff, I learned that you can't do it in v14 with either FILE INFO or DISPLAY DICTIONARY because SPSS 'improved' the output of those commands as of v14. My workaround has been to keep my copy of v13 available and use it to produce data dictionaries.

If you have installed the Python programmability module, you can use the syntax below that I modified (with a LOT of help from Jon Peck of SPSS!):

-----------------------------------------------------
*print file name, number of vars in file and var information  in file order.
BEGIN PROGRAM.
import spss, spssaux, DisplayDict
print "Data Dictionary for:", spssaux.GetDatasetInfo()
print "Number of Variables:", spss.GetVariableCount()
DisplayDict.dictionary(alphaorder=False)
END PROGRAM.
----------------------------------------


As Richard Ristow once said,"Ah, SPSS, the simple things that you make hard, sometimes".

HTH

Patricia Cleland


-----Original Message-----
From: SPSSX(r) Discussion [mailto:[hidden email]] On Behalf Of Joel_Rivard
Sent: February 15, 2007 9:56 AM
To: [hidden email]
Subject: SPSS File Info Dictionary

Hi folks,



I've been reading through the archive listserv about the "Display File Information" command. I've been using SPSS 11.0 for the past few years and have used the "File Info" command numerous times to create a dictionary. I've recently installed SPSS 14 and can't seem to create the same type of dictionary as in SPSS 11.0.  The following type of dictionary is what I would like to obtain.



SURVMNTH  Survey month of data collection                                     3

          Print Format: F2

          Write Format: F2



          Value    Label



              1    January 2000

              2    February 2000

              3    March 2000

              4    April 2000

              5    May 2000

              6    June 2000

              7    July 2000

              8    August 2000

              9    September 2000

             10    October 2000

             11    November 2000

             12    December 2000



LANINT    Language of interview                                               4

          Print Format: F1

          Write Format: F1



          Value    Label



              1    English

              2    French



I've tried some of the syntax that was posted on the listserv and none of them gave me the type of dictionary that I want.  Is there a specific syntax command that should be used to obtain this type of dictionary?  If not, can we request that this feature be brought back since it was available in SPSS 11.0?



Thanks,

Joel



Joël Rivard

Data Technician

Maps, Data & Government Information Centre

Carleton University Library

(613) 520-2600 ext.1685

[hidden email]
Reply | Threaded
Open this post in threaded view
|

AW: SPSS File Info Dictionary

la volta statistics
I recently posted something related to that topic and Jon Peck helped with a
solution.

Here an example. (You need the updated spssaux module  2.0.4):

DATA LIST /ID 1-2 Gender 4 (A) Smoker 6(A).
begin data.
1  M Y
2  F
3    N
4  F Y
5  M Y
6  F
7  M Y
8  M N
9
10 F Y
end data.

VAR LABEL id 'id'.
VAR LABEL Gender 'Gender'.
VAL LABEL Gender ' ' 'n.a.' 'F' 'female' 'M' 'male'.

VAR LABEL Smoker 'Smoking'.
VAL LABEL Smoker ' ' 'n.a.' 'Y' 'yes' 'N' 'no'.

begin program.
import spss, spssaux

vardict = spssaux.VariableDict()
for v in vardict:
    print "\n","-Variable:", v.VariableName,"\n","--Variable Label:
",v.VariableLabel
    valueLabels = v.ValueLabels
    if valueLabels:
       print "--Value Labels:"
       for lbl in sorted(valueLabels):
           print " ", lbl," ", valueLabels[lbl]
end program.


Hope that helps, Christian

-----Ursprüngliche Nachricht-----
Von: SPSSX(r) Discussion [mailto:[hidden email]]Im Auftrag von
Joel_Rivard
Gesendet: Freitag, 16. Februar 2007 14:13
An: [hidden email]
Betreff: Re: SPSS File Info Dictionary


Thanks Patricia and Jon for getting back to me so quickly,

Looks like we'll be installing the Python programmability module that you
mentionned (DisplayDict module). It seems like the best solution out there.

Thanks again,
Joel

Joël Rivard
Data Technician
Maps, Data & Government Information Centre
Carleton University Library
(613) 520-2600 ext.1685
[hidden email]

-----Original Message-----
From: SPSSX(r) Discussion [mailto:[hidden email]] On Behalf Of
Peck, Jon
Sent: Thursday, February 15, 2007 3:27 PM
To: [hidden email]
Subject: Re: SPSS File Info Dictionary

The DisplayDict module gives you a lot of flexibility about exactly what
output you want, and the current version, which did not exist when Patricia
started with this, can include simple statistics for the variables
integrated with the dictionary information.

-Jon Peck

-----Original Message-----
From: SPSSX(r) Discussion [mailto:[hidden email]] On Behalf Of
Cleland, Patricia (EDU)
Sent: Thursday, February 15, 2007 1:56 PM
To: [hidden email]
Subject: Re: [SPSSX-L] SPSS File Info Dictionary

Joel,

I had this same problem last fall when I upgraded to v14 and discovered that
I couldn't produce the data dictionary in the format I wanted.

After discussions with a number of SPSS staff, I learned that you can't do
it in v14 with either FILE INFO or DISPLAY DICTIONARY because SPSS
'improved' the output of those commands as of v14. My workaround has been to
keep my copy of v13 available and use it to produce data dictionaries.

If you have installed the Python programmability module, you can use the
syntax below that I modified (with a LOT of help from Jon Peck of SPSS!):

-----------------------------------------------------
*print file name, number of vars in file and var information  in file order.
BEGIN PROGRAM.
import spss, spssaux, DisplayDict
print "Data Dictionary for:", spssaux.GetDatasetInfo()
print "Number of Variables:", spss.GetVariableCount()
DisplayDict.dictionary(alphaorder=False)
END PROGRAM.
----------------------------------------


As Richard Ristow once said,"Ah, SPSS, the simple things that you make hard,
sometimes".

HTH

Patricia Cleland


-----Original Message-----
From: SPSSX(r) Discussion [mailto:[hidden email]] On Behalf Of
Joel_Rivard
Sent: February 15, 2007 9:56 AM
To: [hidden email]
Subject: SPSS File Info Dictionary

Hi folks,



I've been reading through the archive listserv about the "Display File
Information" command. I've been using SPSS 11.0 for the past few years and
have used the "File Info" command numerous times to create a dictionary.
I've recently installed SPSS 14 and can't seem to create the same type of
dictionary as in SPSS 11.0.  The following type of dictionary is what I
would like to obtain.



SURVMNTH  Survey month of data collection
3

          Print Format: F2

          Write Format: F2



          Value    Label



              1    January 2000

              2    February 2000

              3    March 2000

              4    April 2000

              5    May 2000

              6    June 2000

              7    July 2000

              8    August 2000

              9    September 2000

             10    October 2000

             11    November 2000

             12    December 2000



LANINT    Language of interview
4

          Print Format: F1

          Write Format: F1



          Value    Label



              1    English

              2    French



I've tried some of the syntax that was posted on the listserv and none of
them gave me the type of dictionary that I want.  Is there a specific syntax
command that should be used to obtain this type of dictionary?  If not, can
we request that this feature be brought back since it was available in SPSS
11.0?



Thanks,

Joel



Joël Rivard

Data Technician

Maps, Data & Government Information Centre

Carleton University Library

(613) 520-2600 ext.1685

[hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: SPSS File Info Dictionary

Cathie Atkinson
In reply to this post by Joel_Rivard
Hi List

I finally got a some time to investigate Python
and have downloaded the programs and spssaux.  I
can't find DisplayDict though.  I did a search on
the SPSS website to no avail so I'm clearly
misunderstanding something.  Is it a module?  The
program below won't run without it.  Any help will be greatly appreciated.

Thanks!
Cathie

At 02:55 PM 2/15/2007, Cleland, Patricia (EDU) wrote:

>Joel,
>
>I had this same problem last fall when I
>upgraded to v14 and discovered that I couldn't
>produce the data dictionary in the format I wanted.
>
>After discussions with a number of SPSS staff, I
>learned that you can't do it in v14 with either
>FILE INFO or DISPLAY DICTIONARY because SPSS
>'improved' the output of those commands as of
>v14. My workaround has been to keep my copy of
>v13 available and use it to produce data dictionaries.
>
>If you have installed the Python programmability
>module, you can use the syntax below that I
>modified (with a LOT of help from Jon Peck of SPSS!):
>
>-----------------------------------------------------
>*print file name, number of vars in file and var information  in file order.
>BEGIN PROGRAM.
>import spss, spssaux, DisplayDict
>print "Data Dictionary for:", spssaux.GetDatasetInfo()
>print "Number of Variables:", spss.GetVariableCount()
>DisplayDict.dictionary(alphaorder=False)
>END PROGRAM.
>----------------------------------------
>
>
>As Richard Ristow once said,"Ah, SPSS, the
>simple things that you make hard, sometimes".
>
>HTH
>
>Patricia Cleland
>
>
>-----Original Message-----
>From: SPSSX(r) Discussion
>[mailto:[hidden email]] On Behalf Of Joel_Rivard
>Sent: February 15, 2007 9:56 AM
>To: [hidden email]
>Subject: SPSS File Info Dictionary
>
>Hi folks,
>
>
>
>I've been reading through the archive listserv
>about the "Display File Information" command.
>I've been using SPSS 11.0 for the past few years
>and have used the "File Info" command numerous
>times to create a dictionary. I've recently
>installed SPSS 14 and can't seem to create the
>same type of dictionary as in SPSS 11.0.  The
>following type of dictionary is what I would like to obtain.
>
>
>
>SURVMNTH  Survey month of data
>collection                                     3
>
>           Print Format: F2
>
>           Write Format: F2
>
>
>
>           Value    Label
>
>
>
>               1    January 2000
>
>               2    February 2000
>
>               3    March 2000
>
>               4    April 2000
>
>               5    May 2000
>
>               6    June 2000
>
>               7    July 2000
>
>               8    August 2000
>
>               9    September 2000
>
>              10    October 2000
>
>              11    November 2000
>
>              12    December 2000
>
>
>
>LANINT    Language of
>interview                                               4
>
>           Print Format: F1
>
>           Write Format: F1
>
>
>
>           Value    Label
>
>
>
>               1    English
>
>               2    French
>
>
>
>I've tried some of the syntax that was posted on
>the listserv and none of them gave me the type
>of dictionary that I want.  Is there a specific
>syntax command that should be used to obtain
>this type of dictionary?  If not, can we request
>that this feature be brought back since it was available in SPSS 11.0?
>
>
>
>Thanks,
>
>Joel
>
>
>
>Joël Rivard
>
>Data Technician
>
>Maps, Data & Government Information Centre
>
>Carleton University Library
>
>(613) 520-2600 ext.1685
>
>[hidden email]
>
>
>--
>BEGIN-ANTISPAM-VOTING-LINKS
>------------------------------------------------------
>
>Teach CanIt if this mail (ID 221152242) is spam:
>Spam:        https://antispam.osu.edu/b.php?c=s&i=221152242&m=52ceb7c22297
>Not spam:    https://antispam.osu.edu/b.php?c=n&i=221152242&m=52ceb7c22297
>Forget vote: https://antispam.osu.edu/b.php?c=f&i=221152242&m=52ceb7c22297
>------------------------------------------------------
>END-ANTISPAM-VOTING-LINKS
Reply | Threaded
Open this post in threaded view
|

Re: SPSS File Info Dictionary

Peck, Jon
You need several supplementary modules from SPSS Developer Central.  Go to www.spss.com/devcentral.  In the upper right corner, click on the Downloads link.  You will see the first of ten pages of downloadable items.  Get the DisplayDictionary module, which is on page 2, the spssaux module, which is on page 9, and the spssdata module, which is on page 10.

If you installed Python 2.4 in the default place, put these modules in
c:\python24\lib\site-packages and you are ready to go.

HTH,
Jon Peck

-----Original Message-----
From: SPSSX(r) Discussion [mailto:[hidden email]] On Behalf Of Cathie Atkinson
Sent: Tuesday, February 20, 2007 12:50 PM
To: [hidden email]
Subject: Re: [SPSSX-L] SPSS File Info Dictionary

Hi List

I finally got a some time to investigate Python
and have downloaded the programs and spssaux.  I
can't find DisplayDict though.  I did a search on
the SPSS website to no avail so I'm clearly
misunderstanding something.  Is it a module?  The
program below won't run without it.  Any help will be greatly appreciated.

Thanks!
Cathie

At 02:55 PM 2/15/2007, Cleland, Patricia (EDU) wrote:

>Joel,
>
>I had this same problem last fall when I
>upgraded to v14 and discovered that I couldn't
>produce the data dictionary in the format I wanted.
>
>After discussions with a number of SPSS staff, I
>learned that you can't do it in v14 with either
>FILE INFO or DISPLAY DICTIONARY because SPSS
>'improved' the output of those commands as of
>v14. My workaround has been to keep my copy of
>v13 available and use it to produce data dictionaries.
>
>If you have installed the Python programmability
>module, you can use the syntax below that I
>modified (with a LOT of help from Jon Peck of SPSS!):
>
>-----------------------------------------------------
>*print file name, number of vars in file and var information  in file order.
>BEGIN PROGRAM.
>import spss, spssaux, DisplayDict
>print "Data Dictionary for:", spssaux.GetDatasetInfo()
>print "Number of Variables:", spss.GetVariableCount()
>DisplayDict.dictionary(alphaorder=False)
>END PROGRAM.
>----------------------------------------
>
>
>As Richard Ristow once said,"Ah, SPSS, the
>simple things that you make hard, sometimes".
>
>HTH
>
>Patricia Cleland
>
>
>-----Original Message-----
>From: SPSSX(r) Discussion
>[mailto:[hidden email]] On Behalf Of Joel_Rivard
>Sent: February 15, 2007 9:56 AM
>To: [hidden email]
>Subject: SPSS File Info Dictionary
>
>Hi folks,
>
>
>
>I've been reading through the archive listserv
>about the "Display File Information" command.
>I've been using SPSS 11.0 for the past few years
>and have used the "File Info" command numerous
>times to create a dictionary. I've recently
>installed SPSS 14 and can't seem to create the
>same type of dictionary as in SPSS 11.0.  The
>following type of dictionary is what I would like to obtain.
>
>
>
>SURVMNTH  Survey month of data
>collection                                     3
>
>           Print Format: F2
>
>           Write Format: F2
>
>
>
>           Value    Label
>
>
>
>               1    January 2000
>
>               2    February 2000
>
>               3    March 2000
>
>               4    April 2000
>
>               5    May 2000
>
>               6    June 2000
>
>               7    July 2000
>
>               8    August 2000
>
>               9    September 2000
>
>              10    October 2000
>
>              11    November 2000
>
>              12    December 2000
>
>
>
>LANINT    Language of
>interview                                               4
>
>           Print Format: F1
>
>           Write Format: F1
>
>
>
>           Value    Label
>
>
>
>               1    English
>
>               2    French
>
>
>
>I've tried some of the syntax that was posted on
>the listserv and none of them gave me the type
>of dictionary that I want.  Is there a specific
>syntax command that should be used to obtain
>this type of dictionary?  If not, can we request
>that this feature be brought back since it was available in SPSS 11.0?
>
>
>
>Thanks,
>
>Joel
>
>
>
>Joël Rivard
>
>Data Technician
>
>Maps, Data & Government Information Centre
>
>Carleton University Library
>
>(613) 520-2600 ext.1685
>
>[hidden email]
>
>
>--
>BEGIN-ANTISPAM-VOTING-LINKS
>------------------------------------------------------
>
>Teach CanIt if this mail (ID 221152242) is spam:
>Spam:        https://antispam.osu.edu/b.php?c=s&i=221152242&m=52ceb7c22297
>Not spam:    https://antispam.osu.edu/b.php?c=n&i=221152242&m=52ceb7c22297
>Forget vote: https://antispam.osu.edu/b.php?c=f&i=221152242&m=52ceb7c22297
>------------------------------------------------------
>END-ANTISPAM-VOTING-LINKS
Reply | Threaded
Open this post in threaded view
|

Re: SPSS File Info Dictionary

Beauregard Elise
In reply to this post by Cathie Atkinson
Hi Cathie,
I had the same problem and finally fount the module at:
http://www.spss.com/devcentral/index.cfm?pg=downloadDet&dId=19
Good luck,
Elise

Elise Beauregard
Analyste de recherche et planification
Bureau de recherche institutionnelle
Université de Montreal
tel:  514-343-6111, poste 1-8927
fax:  514-343-5770
www.bri.umontreal.ca

-----Message d'origine-----
De : SPSSX(r) Discussion [mailto:[hidden email]] De la part de Cathie Atkinson
Envoyé : 20 février 2007 13:50
À : [hidden email]
Objet : Re: SPSS File Info Dictionary

Hi List

I finally got a some time to investigate Python and have downloaded the programs and spssaux.  I can't find DisplayDict though.  I did a search on the SPSS website to no avail so I'm clearly misunderstanding something.  Is it a module?  The program below won't run without it.  Any help will be greatly appreciated.

Thanks!
Cathie

At 02:55 PM 2/15/2007, Cleland, Patricia (EDU) wrote:

>Joel,
>
>I had this same problem last fall when I upgraded to v14 and discovered
>that I couldn't produce the data dictionary in the format I wanted.
>
>After discussions with a number of SPSS staff, I learned that you can't
>do it in v14 with either FILE INFO or DISPLAY DICTIONARY because SPSS
>'improved' the output of those commands as of v14. My workaround has
>been to keep my copy of
>v13 available and use it to produce data dictionaries.
>
>If you have installed the Python programmability module, you can use
>the syntax below that I modified (with a LOT of help from Jon Peck of
>SPSS!):
>
>-----------------------------------------------------
>*print file name, number of vars in file and var information  in file order.
>BEGIN PROGRAM.
>import spss, spssaux, DisplayDict
>print "Data Dictionary for:", spssaux.GetDatasetInfo() print "Number of
>Variables:", spss.GetVariableCount()
>DisplayDict.dictionary(alphaorder=False)
>END PROGRAM.
>----------------------------------------
>
>
>As Richard Ristow once said,"Ah, SPSS, the simple things that you make
>hard, sometimes".
>
>HTH
>
>Patricia Cleland
>
>
>-----Original Message-----
>From: SPSSX(r) Discussion
>[mailto:[hidden email]] On Behalf Of Joel_Rivard
>Sent: February 15, 2007 9:56 AM
>To: [hidden email]
>Subject: SPSS File Info Dictionary
>
>Hi folks,
>
>
>
>I've been reading through the archive listserv about the "Display File
>Information" command.
>I've been using SPSS 11.0 for the past few years and have used the
>"File Info" command numerous times to create a dictionary. I've
>recently installed SPSS 14 and can't seem to create the same type of
>dictionary as in SPSS 11.0.  The following type of dictionary is what I
>would like to obtain.
>
>
>
>SURVMNTH  Survey month of data
>collection                                     3
>
>           Print Format: F2
>
>           Write Format: F2
>
>
>
>           Value    Label
>
>
>
>               1    January 2000
>
>               2    February 2000
>
>               3    March 2000
>
>               4    April 2000
>
>               5    May 2000
>
>               6    June 2000
>
>               7    July 2000
>
>               8    August 2000
>
>               9    September 2000
>
>              10    October 2000
>
>              11    November 2000
>
>              12    December 2000
>
>
>
>LANINT    Language of
>interview                                               4
>
>           Print Format: F1
>
>           Write Format: F1
>
>
>
>           Value    Label
>
>
>
>               1    English
>
>               2    French
>
>
>
>I've tried some of the syntax that was posted on the listserv and none
>of them gave me the type of dictionary that I want.  Is there a
>specific syntax command that should be used to obtain this type of
>dictionary?  If not, can we request that this feature be brought back
>since it was available in SPSS 11.0?
>
>
>
>Thanks,
>
>Joel
>
>
>
>Joël Rivard
>
>Data Technician
>
>Maps, Data & Government Information Centre
>
>Carleton University Library
>
>(613) 520-2600 ext.1685
>
>[hidden email]
>
>
>--
>BEGIN-ANTISPAM-VOTING-LINKS
>------------------------------------------------------
>
>Teach CanIt if this mail (ID 221152242) is spam:
>Spam:        https://antispam.osu.edu/b.php?c=s&i=221152242&m=52ceb7c22297
>Not spam:    https://antispam.osu.edu/b.php?c=n&i=221152242&m=52ceb7c22297
>Forget vote: https://antispam.osu.edu/b.php?c=f&i=221152242&m=52ceb7c22297
>------------------------------------------------------
>END-ANTISPAM-VOTING-LINKS