Hello, running windows vista, R2.9. Installed the following libraries: (*latticist*, *playwith* and *Cairo*) Wanted then to run, to evaluate the visualization features:>data(iris)>library(latticist)>latticist(iris)However, i tested my desktop and laptop and get the following error after typing latticist(iris): latticist(iris) Loading required package: playwith Loading required package: cairoDevice Error in inDL(x, as.logical(local), as.logical(now), ...) : unable to load shared library 'C:/Users/luna/Documents/R/win-library/2.9/cairoDevice/libs/cairoDevice.dll': LoadLibrary failure: The specified module could not be found. Error: package 'cairoDevice' could not be loaded However, i navigate to the location in the path above and i do see the cairoDevice.dll file, so i can't figure out what's going on. Again, i tested 2 machines, with R2.9 and Vista, same error on both. -zubin [[alternative HTML version deleted]]
Most likely you did not install the dependent DLLs: you need Gtk2 (aka GTk+) installed *and in your path*. That message does not say that 'cairoDevice.dll' cannot be loaded, but a DLL it specified: in interactive use on recent versions of Windows you normally get a pop-up with more information. The CRAN windows/contrib/2.9 ReadMe says Package RGtk2 requires an installed version of Gtk2 with version number >= 2.10.11. and I believe something similar is true of cairoDevice by the same author. A good source of a pre-compiled Gtk2 is http://downloads.sourceforge.net/gladewin32/ , and I guess you need gtk-2.12.9-win32-2.exe from gtk+-win32-runtime. If you insist on using a toolkit designed for Unix on Windows you can expect a rough ride: even when all the Gtk2 components are installed there are lots of issues with fonts. On Mon, 25 May 2009, zubin wrote:> Hello, running windows vista, R2.9. Installed the following libraries: > (*latticist*, *playwith* and *Cairo*) > > Wanted then to run, to evaluate the visualization features: > >> data(iris) > >> library(latticist) > >> latticist(iris) > > > However, i tested my desktop and laptop and get the following error > after typing latticist(iris): > > latticist(iris) > Loading required package: playwith > Loading required package: cairoDevice > Error in inDL(x, as.logical(local), as.logical(now), ...) : > unable to load shared library > 'C:/Users/luna/Documents/R/win-library/2.9/cairoDevice/libs/cairoDevice.dll': > LoadLibrary failure: The specified module could not be found. > > Error: package 'cairoDevice' could not be loaded > > > > However, i navigate to the location in the path above and i do see the > cairoDevice.dll file, so i can't figure out what's going on. Again, i > tested 2 machines, with R2.9 and Vista, same error on both. > > -zubin > >-- Brian D. Ripley, ripley at stats.ox.ac.uk Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/ University of Oxford, Tel: +44 1865 272861 (self) 1 South Parks Road, +44 1865 272866 (PA) Oxford OX1 3TG, UK Fax: +44 1865 272595
On 5/25/2009 9:43 AM, zubin wrote:> Hello, running windows vista, R2.9. Installed the following libraries: > (*latticist*, *playwith* and *Cairo*) > > Wanted then to run, to evaluate the visualization features: > >>data(iris) > >>library(latticist) > >>latticist(iris) > > > However, i tested my desktop and laptop and get the following error > after typing latticist(iris): > > latticist(iris) > Loading required package: playwith > Loading required package: cairoDevice > Error in inDL(x, as.logical(local), as.logical(now), ...) : > unable to load shared library > 'C:/Users/luna/Documents/R/win-library/2.9/cairoDevice/libs/cairoDevice.dll': > LoadLibrary failure: The specified module could not be found. > > Error: package 'cairoDevice' could not be loaded > > > > However, i navigate to the location in the path above and i do see the > cairoDevice.dll file, so i can't figure out what's going on. Again, i > tested 2 machines, with R2.9 and Vista, same error on both.Don't you get a popup error dialog? I do, and it says that libgdk-win32-2.0-0.dll was not found. Only when I click on okay does it return to the console to tell me about the cairoDevice failure. So I think the real problem is with the libgdk not being present, and that causes the cairoDevice dll to fail to load. Windows doesn't tell R about the reason, it just says it failed. The reason that library was not installed is that I didn't have RGtk2 installed properly. Try library(RGtk2), and make sure it works (and let it install GTK if it wants), and things should be fine. Duncan Murdoch