[Qgis-user] Problem with SDA4PP/Linked Statistical Display

Anne Ghisla a.ghisla at gmail.com
Wed Dec 9 06:14:31 PST 2009


Apologises for long email..

On up-to-date Debian Squeeze:

>>> import rpy2
>>> import rpy2.robjects as robjects
>>> print(rpy2.__version__)
2.0.8
>>> print(robjects.r)
<rpy2.robjects.R object at 0xb7dec20c>
platform: i486-pc-linux-gnu
arch: i486
os: linux-gnu
system: i486, linux-gnu
status: 
major: 2
minor: 10.0
year: 2009
month: 10
day: 26
svn rev: 50208
language: R
version.string: R version 2.10.0 (2009-10-26)
>>> r = robjects.r
>>> r.require("iplots")[0] 
[I installed openjdk-6-jdk, as I've already installed other openjdk
packages. Loads fine in R, not in rpy2:]
Loading required package: iplots
Loading required package: rJava
Error in dyn.load(file, DLLpath = DLLpath, ...) : 
  unable to load shared library
'/usr/local/lib/R/site-library/rJava/libs/rJava.so':
  libjvm.so: cannot open shared object file: No such file or directory
Error : .onLoad failed in 'loadNamespace' for 'rJava'
Error: package 'rJava' could not be loaded
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/lib/python2.5/site-packages/rpy2/robjects/__init__.py",
line 423, in __call__
    res = super(RFunction, self).__call__(*new_args, **new_kwargs)
rinterface.RRuntimeError: Error: package 'rJava' could not be loaded

>>> r.require("ade4")
Loading required package: ade4

Attaching package: 'ade4'


	The following object(s) are masked from package:base :

	 within 

<RVector - Python:0xb7dec70c / R:0x9c43fc0>
>>> r.require("ade4")[0]
True
>>> 


On Windows XP Home sp3:

>>> import rpy2
>>> import rpy2.robjects as robjects
>>> print(rpy2.__version__)
2.0.3
>>> print(robjects.r)
<rpy2.robjects.R object at 0x011DDD50>
platform: i486-pc-mingw32
arch: i386
os: mingw32
system: i386, mingw32
status: 
major: 2
minor: 8.0
year: 2008
month: 10
day: 20
svn rev: 46754
language: R
version.string: R version 2.10.0 (2009-10-26)
>>> r = robjects.r
>>> r.require("iplots")[0]
True
>>> r.require("ade4")[0]
True

HTH,
Anne

On Wed, 2009-12-09 at 15:10 +0200, Volkan Kepoglu wrote:
> my rpy version is 2.0.6, maybe we can test our code results at the
> same time.
> 
> 
> >>> import rpy2
> >>> import rpy2.robjects as robjects
> >>> print(rpy2.__version__)
> 2.0.6
> >>> print(robjects.r)
> <rpy2.robjects.R object at 0x02A8FFB0>
> platform: i386-pc-mingw32
> arch: i386
> os: mingw32
> system: i386, mingw32
> status: 
> major: 2
> minor: 9.0
> year: 2009
> month: 04
> day: 17
> svn rev: 48333
> language: R
> version.string: R version 2.9.0 (2009-04-17)
> >>> r = robjects.r
> >>> r.require("iplots")[0]
> True
> >>> r.require("iplots")
> <RVector - Python:0x02A8A3C8 / R:0x02950AB8>
> >>> r.require("iplots").r_repr()
> 'TRUE'
> >>> r.require("ade4")[0] # not installed yet
> False
> >>> # so, now, the system is working pefect
> 
> 
> python 2.5.2
> winXP sp3 64bit
> 
> On Wed, Dec 9, 2009 at 3:02 PM, Anne Ghisla <a.ghisla at gmail.com>
> wrote:
>         On Wed, 2009-12-09 at 14:51 +0200, Volkan Kepoglu wrote:
>         > On Wed, Dec 9, 2009 at 2:24 PM, Anne Ghisla
>         <a.ghisla at gmail.com>
>         > wrote:
>         > On Wed, 2009-12-09 at 04:17 -0800, Volkan Kepoglu wrote:
>         > > updated with ver. 0.142, could you try that if it is
>         fixed?
>         > >
>         > >
>         > > 1. added loading of rJava package function
>         > > 2. changed the style of loading of iplot package: first
>         checks the
>         > > package installed or not
>         > > and then loads the package but skips to control the
>         package whether
>         > it
>         > > is loaded or not,
>         > > because, most probably, i think that there is a bug for
>         iplots
>         > > package. even it is loaded, sometimes do not return true.
>         > > for this reason, i prefered not to control the library
>         whether
>         > loaded
>         > > or not.
>         >
>         >
>         > Hi Volkan, list,
>         >
>         > sounds like the ade4 load failure for HomeRange_plugin
>         >
>         http://sourceforge.net/tracker/?func=detail&aid=2830501&group_id=48422&atid=453021
>         >
>         > does the require(iplots) work on R?
>         >
>         >
>         > the real problem is that i could not produce the same error
>         in every
>         > time.
>         > sometimes it works and sometimes not.
>         
>         
>         Same for me and users that report the problem. Only thing for
>         ade4, I
>         encountered it mainly on Windows, and R alone showed no
>         problems. It can
>         be a rpy2 version issue. Unfortunately, extensive testing has
>         not been
>         done. Let me know how I can help.
>         
>         my 2 cents..
>         Anne
>         
> 
> 
> 
> -- 
> Regards,
> Volkan Osman Kepoglu
> PhD Candidate
> GGIT Department in METU,
> http:/ggit.metu.edu.tr
> 

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: This is a digitally signed message part
URL: <http://lists.osgeo.org/pipermail/qgis-user/attachments/20091209/ff096f43/attachment.sig>


More information about the Qgis-user mailing list