decimal point problem with compute / python

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

decimal point problem with compute / python

drfg2008
when I use python to read in coefficients from output tables I get numbers with decimal comma instead of decimal point.

So when I use "compute2 ... the syntax needs decimal points instead of comma. How can I change the value into decimal point

for example 1,123 to 1.123.

Thanks
Dr. Frank Gaeth

Reply | Threaded
Open this post in threaded view
|

Re: decimal point problem with compute / python

David Marso
Administrator
Locale?
Why don't you post what you are attempting?
How did the "," dec separators get here in the first place?
Are you still trying to deal with the R regression coefficients from last week?
Maybe MATRIX rather than python.  
Frankly, Sometimes Python is your hammer and everything is a freaking nail!

drfg2008 wrote
when I use python to read in coefficients from output tables I get numbers with decimal comma instead of decimal point.

So when I use "compute2 ... the syntax needs decimal points instead of comma. How can I change the value into decimal point

for example 1,123 to 1.123.

Thanks
Please reply to the list and not to my personal email.
Those desiring my consulting or training services please feel free to email me.
---
"Nolite dare sanctum canibus neque mittatis margaritas vestras ante porcos ne forte conculcent eas pedibus suis."
Cum es damnatorum possederunt porcos iens ut salire off sanguinum cliff in abyssum?"
Reply | Threaded
Open this post in threaded view
|

Re: decimal point problem with compute / python

drfg2008
Thanks Jon,

I used a python script from SPSS to read outputs.

To chage cellAttrib="text" into cellAttrib="number" works perfectly. I just forgot to change the list attribute: no "[0]", of course.


Frank


--------------------------------

Dr. Frank Gaeth