|
Dear List,
I want to change the number of decimals in the SPSS output file. Now I get 3 decimals and when I write about my results I often use 2 decimals. If the 3rd decimal is a 5, I have problems to get my 2 decimals right. Instead of double clicking on the number, I want to specify the number of decimals in the output in advance. I've Googled some about this but can't find any answer. Can anyone here help me with this option/syntax? Best Henrik ===================== To manage your subscription to SPSSX-L, send a message to [hidden email] (not to SPSSX-L), with no body text except the command. To leave the list, send the command SIGNOFF SPSSX-L For a list of commands to manage subscriptions, send the command INFO REFCARD |
|
Dear Henrik
To create large tables you might want to use the Output Management System (OMS) to select the coefficients you need and get them into a new .sav-file. This new .sav-file can then be exported or saved as an .xls-file. In Excel it is then easy to adjust the number of decimals (excel rounds the figures correctly). Alternatively you can also copy the SPSS-Table and paste it to the Excel window. Best regards Sakari Am 15.12.2008 18:55 Uhr schrieb "Henrik Danielsson" unter <[hidden email]>: > Dear List, > > I want to change the number of decimals in the SPSS output file. Now I > get 3 decimals and when I write about my results I often use 2 decimals. > If the 3rd decimal is a 5, I have problems to get my 2 decimals right. > Instead of double clicking on the number, I want to specify the number > of decimals in the output in advance. I've Googled some about this but > can't find any answer. Can anyone here help me with this option/syntax? > > Best > Henrik > > ===================== > To manage your subscription to SPSSX-L, send a message to > [hidden email] (not to SPSSX-L), with no body text except the > command. To leave the list, send the command > SIGNOFF SPSSX-L > For a list of commands to manage subscriptions, send the command > INFO REFCARD ===================== To manage your subscription to SPSSX-L, send a message to [hidden email] (not to SPSSX-L), with no body text except the command. To leave the list, send the command SIGNOFF SPSSX-L For a list of commands to manage subscriptions, send the command INFO REFCARD |
|
The number of decimals used by default in a pivot table depends on the type of value in the cell. Where, for example, it is a variable mean, it will be based on the variable's format, so changing that format will affect the result.
For statistics such as regression coefficients, correlations, etc, the format is not based on the variable, but you can change this format automatically by using scripting. You could create an autoscript for a particular table type. Easier, if you have version 17, you could use the SPSSINC MODIFY TABLES extension command, downloadable from SPSS Developer Central (www.spss.com/devcentral) and one of the customization functions in the customstyles.py module installed with that command. There is a function called SetTwoDecimalPlaces that will do this for you. I can provide more details on the latter if you send more specifics. HTH, Jon Peck -----Original Message----- From: SPSSX(r) Discussion [mailto:[hidden email]] On Behalf Of Sakari Lemola Sent: Tuesday, December 16, 2008 7:01 AM To: [hidden email] Subject: Re: [SPSSX-L] Decimals in output Dear Henrik To create large tables you might want to use the Output Management System (OMS) to select the coefficients you need and get them into a new .sav-file. This new .sav-file can then be exported or saved as an .xls-file. In Excel it is then easy to adjust the number of decimals (excel rounds the figures correctly). Alternatively you can also copy the SPSS-Table and paste it to the Excel window. Best regards Sakari Am 15.12.2008 18:55 Uhr schrieb "Henrik Danielsson" unter <[hidden email]>: > Dear List, > > I want to change the number of decimals in the SPSS output file. Now I > get 3 decimals and when I write about my results I often use 2 decimals. > If the 3rd decimal is a 5, I have problems to get my 2 decimals right. > Instead of double clicking on the number, I want to specify the number > of decimals in the output in advance. I've Googled some about this but > can't find any answer. Can anyone here help me with this option/syntax? > > Best > Henrik > > ===================== > To manage your subscription to SPSSX-L, send a message to > [hidden email] (not to SPSSX-L), with no body text except the > command. To leave the list, send the command > SIGNOFF SPSSX-L > For a list of commands to manage subscriptions, send the command > INFO REFCARD ===================== To manage your subscription to SPSSX-L, send a message to [hidden email] (not to SPSSX-L), with no body text except the command. To leave the list, send the command SIGNOFF SPSSX-L For a list of commands to manage subscriptions, send the command INFO REFCARD ===================== To manage your subscription to SPSSX-L, send a message to [hidden email] (not to SPSSX-L), with no body text except the command. To leave the list, send the command SIGNOFF SPSSX-L For a list of commands to manage subscriptions, send the command INFO REFCARD |
|
Thanks for the comments Jon and Sakari!
I'm using version 16 now, but I'll be upgrading to 17 in January. Until then I'll use Sakari's solution. Best Henrik Peck, Jon skrev: > The number of decimals used by default in a pivot table depends on the type of value in the cell. Where, for example, it is a variable mean, it will be based on the variable's format, so changing that format will affect the result. > > For statistics such as regression coefficients, correlations, etc, the format is not based on the variable, but you can change this format automatically by using scripting. You could create an autoscript for a particular table type. Easier, if you have version 17, you could use the > SPSSINC MODIFY TABLES extension command, downloadable from SPSS Developer Central (www.spss.com/devcentral) and one of the customization functions in the customstyles.py module installed with that command. There is a function called SetTwoDecimalPlaces that will do this for you. > > I can provide more details on the latter if you send more specifics. > > HTH, > Jon Peck > > -----Original Message----- > From: SPSSX(r) Discussion [mailto:[hidden email]] On Behalf Of Sakari Lemola > Sent: Tuesday, December 16, 2008 7:01 AM > To: [hidden email] > Subject: Re: [SPSSX-L] Decimals in output > > Dear Henrik > > To create large tables you might want to use the Output Management System > (OMS) to select the coefficients you need and get them into a new .sav-file. > This new .sav-file can then be exported or saved as an .xls-file. In Excel > it is then easy to adjust the number of decimals (excel rounds the figures > correctly). Alternatively you can also copy the SPSS-Table and paste it to > the Excel window. > > Best regards > > Sakari > > > Am 15.12.2008 18:55 Uhr schrieb "Henrik Danielsson" unter > <[hidden email]>: > > >> Dear List, >> >> I want to change the number of decimals in the SPSS output file. Now I >> get 3 decimals and when I write about my results I often use 2 decimals. >> If the 3rd decimal is a 5, I have problems to get my 2 decimals right. >> Instead of double clicking on the number, I want to specify the number >> of decimals in the output in advance. I've Googled some about this but >> can't find any answer. Can anyone here help me with this option/syntax? >> >> Best >> Henrik >> >> ===================== >> To manage your subscription to SPSSX-L, send a message to >> [hidden email] (not to SPSSX-L), with no body text except the >> command. To leave the list, send the command >> SIGNOFF SPSSX-L >> For a list of commands to manage subscriptions, send the command >> INFO REFCARD >> > > ===================== > To manage your subscription to SPSSX-L, send a message to > [hidden email] (not to SPSSX-L), with no body text except the > command. To leave the list, send the command > SIGNOFF SPSSX-L > For a list of commands to manage subscriptions, send the command > INFO REFCARD > > ===================== > To manage your subscription to SPSSX-L, send a message to > [hidden email] (not to SPSSX-L), with no body text except the > command. To leave the list, send the command > SIGNOFF SPSSX-L > For a list of commands to manage subscriptions, send the command > INFO REFCARD > > ===================== To manage your subscription to SPSSX-L, send a message to [hidden email] (not to SPSSX-L), with no body text except the command. To leave the list, send the command SIGNOFF SPSSX-L For a list of commands to manage subscriptions, send the command INFO REFCARD |
| Free forum by Nabble | Edit this page |
