views:

86

answers:

2

Hi guys,

I would like to create an R package which would include classes, methods and functions.

The thing is, I managed to create it on Linux (and it is working on Linux), but I can't make the same package work on Windows (which is my main OS).

What I tried to do (maybe it was a bit foolish) was to convert the tar.gz into a Zip file and to install it from the R GUI.

However, when I load the package library("myPackage") then I get the following message:

  Error in library("myPackage") :
     there is no package called 'myPackage'

I just don't understand why...

Should I try to build the package directly from Windows with the R tools?

Thanks for your help,

Jeremie

+1  A: 

Yes, you should make it directly on Windows. See the R Extensions manual and a number of tutorials on the web.

Dirk Eddelbuettel
+4  A: 

To build an R package on Windows, download the tools at
     http://www.murdoch-sutherland.com/Rtools/
and follow the instructions at
     http://robjhyndman.com/researchtips/building-r-packages-for-windows/

Rob Hyndman
Thanks, you article is just GREAT. It explains everything very smoothly. Thanks for the link!
JSmaga