|
View:
New views
6 Messages
—
Rating Filter:
Alert me
|
|
|
Running SPSS application from IronPythonHi All,
I was using python and SPSS Python integration plug-in to access SPSS application and execute spss syntax commands. I was wondering if that can be achieved using IronPython as well. I try to import the spss module and added the python25/lib/site-packages to the IronPython path. But I got an exception that the module is not found. I would appreciate any advice. -- Sarah Abdelrazak _______________________________________________ Users mailing list Users@... http://lists.ironpython.com/listinfo.cgi/users-ironpython.com |
|
|
Re: Running SPSS application from IronPythonWell - prima-facie an ImportError saying the module can't be found
means that the path containing the package/module isn't in sys.path when you do the import (although it's *possible*) there is another problem. Try adding the path from the interactive interpreter and trying the import. Michael -- http://www.ironpythoninaction.com On 29 Jun 2009, at 17:05, Sarah Abdel Razak <sabdelrazak@...> wrote: > Hi All, > > I was using python and SPSS Python integration plug-in to > access SPSS application and execute spss syntax commands. > I was wondering if that can be achieved using IronPython as well. > I try to import the spss module and added the python25/lib/site- > packages to the IronPython path. But I got an exception that the > module is not found. > I would appreciate any advice. > -- > Sarah Abdelrazak > > _______________________________________________ > Users mailing list > Users@... > http://lists.ironpython.com/listinfo.cgi/users-ironpython.com Users mailing list Users@... http://lists.ironpython.com/listinfo.cgi/users-ironpython.com |
|
|
Re: Running SPSS application from IronPythonThanks for your reply I just knew that spss Python plugin has to be built for specific Python implementations.
Unfortunately it does not support IronPython. Regards -- Sarah Abdelrazak On Mon, Jun 29, 2009 at 10:11 AM, Michael Foord <fuzzyman@...> wrote: Well - prima-facie an ImportError saying the module can't be found means that the path containing the package/module isn't in sys.path when you do the import (although it's *possible*) there is another problem. _______________________________________________ Users mailing list Users@... http://lists.ironpython.com/listinfo.cgi/users-ironpython.com |
|
|
Re: Running SPSS application from IronPythonOn Mon, Jun 29, 2009 at 12:22, Sarah Abdel Razak <sabdelrazak@...> wrote:
Even though they don't support it, it will probably still work. Is this SPSS module a C-extension or does it involve C-extensions? Have you tried what Michael suggested? _______________________________________________ Users mailing list Users@... http://lists.ironpython.com/listinfo.cgi/users-ironpython.com |
|
|
Re: Running SPSS application from IronPythonNo spss module is not a C-extension , I believe that part of it is implemented using java.
At the begining of my module I add the following lines : import sys sys.path.extend([ r'c:\Python25\Lib', r'c:\Python25\Lib\site-packages', ]) sys.path.append(r'c:\Python25\Lib') sys.path.append(r'C:\Python25\Lib\site-packages') import spss ----> this line that throws the exception. I'm running the module from IronPython Studio. Regards -- Sarah Abdelrazak On Mon, Jun 29, 2009 at 10:40 AM, Brian Curtin <brian.curtin@...> wrote:
_______________________________________________ Users mailing list Users@... http://lists.ironpython.com/listinfo.cgi/users-ironpython.com |
|
|
Re: Running SPSS application from IronPythonIt depends how the spss module itself is implemented, e.g. if it's a Python module it can be imported easily, but if it's a C module you can write a wrapper around it using ctypes. http://spellcoder.com/blogs/tayseer From: Sarah Abdel Razak <sabdelrazak@...> To: Discussion of IronPython <users@...> Sent: Monday, June 29, 2009 9:00:06 PM Subject: Re: [IronPython] Running SPSS application from IronPython No spss module is not a C-extension , I believe that part of it is implemented using java.
At the begining of my module I add the following lines : import sys sys.path.extend([ r'c:\Python25\Lib', r'c:\Python25\Lib\site-packages', ]) sys.path.append(r'c:\Python25\Lib') sys.path.append(r'C:\Python25\Lib\site-packages') import spss ----> this line that throws the exception. I'm running the module from IronPython Studio. Regards -- Sarah Abdelrazak On Mon, Jun 29, 2009 at 10:40 AM, Brian Curtin <brian.curtin@...> wrote:
_______________________________________________ Users mailing list Users@... http://lists.ironpython.com/listinfo.cgi/users-ironpython.com |
| Free embeddable forum powered by Nabble | Forum Help |