Hi everyone

I have resolved the downer problem, but now I have a new problem.

There is a need to read a spss base with slavic characters (ČŠŽ)
everything works fine. In R everything works fine.
Now R code is moved into Python and everything should be fine again,
but now slavic characters are not anymore recognised when reading spss
base.
Instead strange characters like those in the attachment pop up.

I must emphasize that there is an appropriate encoding for slavic
characters included in the beginning of the file so slavic characters
work fine. Slavic characters are in Python code and everything is
fine.
The problem is reading them I guess from the base with function
"read.spss". But if it works in R it should work in Python as well.
Now what is there to do?



CODE SNAPSHOT

# -*- coding: utf-8 -*-
# coding=<utf-8>
#!/E:/Python
import rpy, csv, xlwt, datetime
from rpy import r
from lxml import etree

r("""
library(foreign)
library(descr)
library(gmodels)
baza <- read.spss("E:/Valicon/crosstabs/Tabela/ADS101_splosna_final.sav")



Thanks a lot for any suggestions.
This problem must be resolved somehow.

Marko




On Thu, Feb 9, 2012 at 11:42 AM, Marko Limbek <marko.lim...@valicon.net> wrote:
> In cmd line I get nothing. But R works. I am sending the cmd printscreen.
>
> I had R installed before and I think that Python 27 was installed
> automatically during the instalation.
>
>
> On Tue, Feb 7, 2012 at 5:48 PM, Peter Cock <p.j.a.c...@googlemail.com> wrote:
>> On Tue, Feb 7, 2012 at 4:18 PM, Marko Limbek <marko.lim...@valicon.net> 
>> wrote:
>>> I get this
>>>
>>>> R --version
>>> Error: object 'R' not found
>>
>> I meant at the (Windows) terminal try that command, not inside Python.
>>
>>> RPy version is rpy-1.0.3.win32-py2.7-R.2.12.1 and now I have both
>>> R-2.9.0 and R-2.12.1 and both Python 26 and Python 27.
>>>
>>> Is there a problem with rpy version?
>>>
>>> Marko
>>
>> I see now you're on Windows - did you have Python 2.7 and
>> R 2.12.1 installed BEFORE using the rpy-1.0.3.win32-py2.7-R.2.12.1
>> installed?
>>
>> Peter
>>
>> ------------------------------------------------------------------------------
>> Keep Your Developer Skills Current with LearnDevNow!
>> The most comprehensive online learning library for Microsoft developers
>> is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
>> Metro Style Apps, more. Free future releases when you subscribe now!
>> http://p.sf.net/sfu/learndevnow-d2d
>> _______________________________________________
>> rpy-list mailing list
>> rpy-list@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/rpy-list

<<attachment: strange chars.png>>

------------------------------------------------------------------------------
Virtualization & Cloud Management Using Capacity Planning
Cloud computing makes use of virtualization - but cloud computing 
also focuses on allowing computing to be delivered as a service.
http://www.accelacomm.com/jaw/sfnl/114/51521223/
_______________________________________________
rpy-list mailing list
rpy-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rpy-list

Reply via email to