Re: [Rd] R 2.1.1 slated for June 20

2005-06-12 Thread Uwe Ligges
M. Edward (Ed) Borasky wrote:
> Question: I just downloaded the daily Windows build of "R-devel" and it
> claims to be a pre-release of R 2.2.0. So ... is the next release 2.1.1
> or 2.2.0? Or is there just not a readily-available Windows build of 2.1.1?

R-devel is the development version for R-2.2.0.
You want to download R-patched (to be R-2.1.1) instead.

Uwe Ligges



> Peter Dalgaard wrote:
> 
> 
>>The next version of R will be released (barring force majeure) on June
>>20th, with beta versions available starting Monday. 
>>
>>Please do check them on your system *before* the release this time...
>>
>>Apologies for the late announcement, but my department moved this week
>>and I needed to be sure that my set-up survived the move.
>>
>>   -pd
>>
>> 
>>
> 
> 
> __
> R-devel@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] Citation for R

2005-06-13 Thread Uwe Ligges
Gordon Smyth wrote:

>>Note also that R does have a User Guide, i.e., while there is plenty of 
>>excellent documentation,
>>there is no single document which is a guide to the whole project.
> 
> 
> Oops, I meant to write "R does not have a User Guide".
> 
> Just to explain this further, the citation() function asks me to cite a 
> "Manual" with the title "R: A language and environment for statistical 
> computing". Although R comes with excellent documentation, including at 
> least 6 manuals on different aspects of the software, no manual or document 
> with that title actually exists, as far as I know.

It does: Some poeople might refer to the same manual with "R Reference 
index", but this is actually the one you cited above.

BTW: In both of my last two reviews for medical journals I criticized 
(not only) the missing citation of software ... (obviously political 
incorrectly, but I'll do so further on ;-))

Uwe Ligges


> Gordon
> 
> __
> R-devel@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] motivation for setRepositories and chooseCRANmirror

2005-06-18 Thread Uwe Ligges
Jeffrey Horner wrote:

> I have some questions and observations about these:
> 
> Will these replace manually setting options(CRAN), which doesn't work in 
> R-2.1.0?
> 
> In R-2.1.0, setRepositories() looks to see if options("repos") contains 
> a CRAN entry and will not override that CRAN entry even if the 
> $R_HOME/etc/repositories file (which setRepositories reads from) 
> contains a  CRAN entry.  Why is this? The user could easily set 
> options("repos") without the help of this function anyway? And 
> chooseCRANmirror() obviously sets the CRAN entry correctly.
> 
> I've checked the latest nightly tarball, R-devel_2005-06-15.tar.gz, and 
> this observations persists.
> 
> I also observe that the R-2.1.0 Rprofile in the base package sets 
> options(repos=c(CRAN="@CRAN@")), so it seems that the only way to set 
> the CRAN repository entry is either with chooseCRANmirror() or manually 
> setting options("repos") or options("CRAN"). If this was not the case, 
> then setRepositories() would choose the CRAN entry from 
> $R_HOME/etc/repositories.
> 
> In R-2.1.0 and in R-devel_2005-06-15.tar.gz, the R-admin manual suggests 
> that for packages to be downloaded and installed within R should set 
> options(CRAN = "http://cran.us.r-project.org/";). Will this be changed to 
> calling chooseCRANmirror()?
> 
>  From an administrator's point of view, I would like to have the CRAN 
> option set automatically on R startup for ALL users. That way I don't 
> have to set this option before calling update.packages().
> 
> 


Hence, I have in our department's R installation's 
.../R/etc/Rprofile.site file (which is intended for configurations that 
apply to all users):

options(repos = c(
   CRAN = "http://umfragen.sowi.uni-mainz.de/CRAN";,
   CRANextra = "http://www.stats.ox.ac.uk/pub/RWin";))


Uwe Ligges

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] axTicks on a reverse ylog plot (PR#7973)

2005-07-05 Thread Uwe Ligges
[EMAIL PROTECTED] wrote:
> There is still issues with the reversed y-log scale plot:
> 
> # Test case A: works as expected
> plot(10:100,log="y",ylim=c(100,11))
> grid()
> par("yaxp")
> 
> # Test case B: grid does not have horizontal lines; par("yaxp") is  
> different
> plot(1:100,log="y",ylim=c(100,10))
> grid()
> par("yaxp")
> 
> In the second test case, axTicks for the horizontal lines (in grid())  
> returns numeric(0) for spacing ... how do the tick marks get drawn in  
> the first place??

We had a problem with reversed log axis in R-2.1.0. There might be 
similar underlying code for grid() I was not aware of when suggesting a 
fix to make reversed log axis work for R-2.1.1 ...
I'll take a closer look later this week.

Uwe Ligges



> -mt
> 
> --please do not edit the information below--
> 
> Version:
> platform = powerpc-apple-darwin8.1.0
> arch = powerpc
> os = darwin8.1.0
> system = powerpc, darwin8.1.0
> status = Patched
> major = 2
> minor = 1.1
> year = 2005
> month = 06
> day = 26
> language = R
> 
> Locale:
> en_CA.UTF-8/en_CA.UTF-8/en_CA.UTF-8/C/en_CA.UTF-8/en_CA.UTF-8
> 
> Search Path:
> .GlobalEnv, package:methods, package:stats, package:graphics,  
> package:grDevices, package:utils, package:datasets, Autoloads,  
> package:base
> 
> __
> R-devel@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] .Rbuildignore {was: ... upgrading an R (WINDOWS) installation ..}

2005-07-06 Thread Uwe Ligges
Gabor Grothendieck wrote:

> On 7/6/05, Martin Maechler <[EMAIL PROTECTED]> wrote:
> 
>>>"Gabor" == Gabor Grothendieck <[EMAIL PROTECTED]>
>>>on Wed, 6 Jul 2005 08:24:49 -0400 writes:
>>
>> ...
>> ...
>>
>>   Gabor> I have cleaned up my batch files (somewhat) and posted them to
>>   Gabor> CRAN. See my recent post:
>>   Gabor> https://www.stat.math.ethz.ch/pipermail/r-help/2005-July/073400.html
>>
>>   Gabor> If any of this functionality could migrate to R
>>   Gabor> itself that would be great.
>>
>>   
>>
>>
>>   Gabor> 2. Also if Rcmd CHECK and Rcmd INSTALL were to
>>   Gabor> process .Rbuildignore like Rcmd BUILD does then
>>   Gabor> makepkg.bat would not have to do a build first.
>>
>>No!  {We have been here before, and I had explained before that}
>>this is really undesired:  ".Rbuildignore" should contain what is
>>ignored by build, but not by "check".
>>It does make sense to have extra code and / or checks for 'R CMD check'
>>that I as package developer want to run, but that are
>> -- too time consuming
>> -- too platform specific
>> -- ..
>>to be run during the daily checks on CRAN (e.g.) /
>>to be run by others at all.
>>
>>{And BTW, AFAIK,  'Rcmd' is now `somewhat deprecated' in favor
>> of "R CMD" since the latter is portable }
>>
>>--
>>Martin
>>
> 
> 
> I think its too heavy handed an approach.  This should be up to the package
> developer via a switch.  I like to put partially written code and other things
> not intended for distribution in .Rbuildignore and don't want them checked or
> installed until I move them out of .Rbuildignore.  That makes it
> possible to keep
> everything together.  Without this one must 1. keep them elsewhere
> (which I am considering as an alternate approach to what I do now although 
> it would be a shame) or else 2. write batch files (which I have
> written for XP) to do
> a prebuild every time one does a check or install.  
> 
> One annoying aspect of R CMD is the requirement for capitalization.  Maybe
> that's ok on UNIX but on Windows one is used to using upper and lower
> case interchangeably.  Its also annoying to have to write two words instead of
> one for a frequently issued command.   At any rate I always call it through

Gabor, honestly, this is nonsense.

1. Do you expect that R also changes under Windows because you are used 
to mix upper and lower case and want to say SUMMARY() or rowsums()?
2. Do you really thing it is annoying to type "R CMD" rather than 
"Rcmd"? Hmm, anybody else has a space bar left for Gabor?

Best,
Uwe

> my Rcmd.bat batch file so its not really an issue for me.
> __
> R-devel@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] dyn.load in linux: missing libraries?

2005-07-06 Thread Uwe Ligges
Tyler Smith wrote:

> ah, that's better. For an immediate fix I just changed .dll to .so, and 

No, change it to
   .Platform$dynlib.ext
or do as already recommended: use library.dynam()

Uwe Ligges



> it appears to work perfectly. I will read through Writing R Extensions 
> to make sure I understand what I'm doing!
> 
> Thanks!
> 
> Tyler
> 
> Peter Dalgaard wrote:
> 
> 
>>Tyler Smith <[EMAIL PROTECTED]> writes:
>>
>> 
>>
>>
>>>Hi,
>>>
>>>I've just about got myself transferred from windowsXP to Linux (Mepis 
>>>3.3.1-1). I've got R 2.1.1, emacs, and ess running from the debian 
>>>repositories. Of course, there is a hitch. I have a bit of C code in one 
>>>of my personal functions. I have, apparently without problem, been able 
>>>to compile it using R CMD SHLIB, but when I try to dyn.load it I get the 
>>>following error:
>>>
>>>
>>>>dyn.load("Cfiles/Neutral/Bell2000.dll")
>>>
>>>Error in dyn.load(x, as.logical(local), as.logical(now)) :
>>>   unable to load shared library 
>>>'/home/tyler/RWorkingDirectory/Cfiles/Neutral/Bell2000.dll':
>>> /home/tyler/RWorkingDirectory/Cfiles/Neutral/Bell2000.dll: invalid ELF 
>>>header
>>>
>>>I take this to mean one of the required libraries is either not loaded 
>>>or not updated. Or, I've overlooked something. Can anyone point me to a 
>>>solution? I tried updating my perl files, and I haven't found anything 
>>>using the R Site Search...
>>>   
>>>
>>
>>Nope, the missing library is the one that you're trying to load.
>>Dynamic libraries are not called .dll on Linux, but rather .so...
>>
>>You should probably read up on "Writing R Extensions", including the
>>hints on how to write portable code (use library.dynam).
>>
>> 
>>
> 
> 
> __
> R-devel@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] R_alloc problems in R v1.11

2005-07-06 Thread Uwe Ligges
Marie-Hélène Ouellette wrote:

> Dear Dr. Ripley,

This is R-devel, among hundreds of other readers, Prof. Ripley is 
perhaps listening as well.

There is no reason to send dozens of messages. Please read the posting 
guide.


> I'm using the R v1.11 on Macintoch and I seem to have a problem with the

There is no version 1.11, and there never was. Current is 2.1.1 anything 
older than 2.x.y is unsupported these days.


> function R_alloc. It crashes when using the following .C function (only an
> example):
> 
> ///
> # include 
> void Hello(int *n)
> {
> int i,x;
> for(i=1;1< *n ; i++)

Do you mean
   i < *n
???

> {
>   Rprintf('salut!!!\n');

What about using double quotes?

> }
> x = (int *) R_alloc(5,sizeof(int));

What is this intended to do???

Uwe Ligges



> }
> 
> ///
> 
> I call it in R with this line:
> 
> .C('Hello',as.integer(5))
> 
> Any idea why and how I can resolve this problem?
> 
> Thank you for your time,
> Marie-Hélène
> 
> __
> R-devel@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] upgrading an R installation to next versoin

2005-07-06 Thread Uwe Ligges
Gabor Grothendieck wrote:

> On 6/30/05, Gabor Grothendieck <[EMAIL PROTECTED]> wrote:
> 
>>On 6/30/05, J. Hosking <[EMAIL PROTECTED]> wrote:
>>
>>>Gabor Grothendieck wrote:
>>>
On 6/30/05, J. Hosking <[EMAIL PROTECTED]> wrote:

>>>
>>>...
>>>
>>>
>I keep a separate directory ...\R\library for nonstandard packages,
>with environment variable R_LIBS set to the directory name.


Do you mean your R_LIBS has two components: one to look in
..\R\rcurrent\library and a second to look in ..\R\library? What does
it look like exactly?

When you do install.packages(whatever) does it install to the
..\R\library rather than ..\R\rcurrent\library ?   Also, does
updates.packages() work as expected for you?

>>>
>>>My R_LIBS environment variable is just
>>>
>>>  R_LIBS=C:\progs\r\library
>>>
>>>and within R I see
>>>
>>>  > .libPaths()
>>>  [1] "C:/progs/r/library"  "C:/progs/r/rcurrent/library"
>>>
>>>i.e., the default library is automatically appended.  The help for
>>>.libPaths explains this.  And yes, install.packages() installs to
>>>C:\progs\R\library and update.packages() works as expected.
>>>
>>>
>My miktex.ini file specifies ...\R\rcurrent\share\texmf as a place
>to look for input files.


I think its necessary to rebuild the name data base in miktex too
initexmf -u
although ignoring that step may work as long as the filenames
have not changed.
>>>
>>>You are probably correct, though I have not yet encountered any problems
>>>that I could attribute to not running initexmf -- no doubt the filenames
>>>have not changed recently.
>>>
>>>
I was hoping to continue using a vanilla
miktex installation as I do now rather than having a custom miktex.ini
file.  At any rate my batch file would continue to work even with your setup
so I think I should be ok here.



>That should take care of your points 3, 4, and 2, respectively.
>Duncan's suggestion of an R_ENVIRON environment variable (which
>I didn't know about; thanks, Duncan) should take care of point 1.
>
>Jon Hosking


It occurs to me in reading this that I could keep the *.site files in
..\R and then have my miktex update batch file also copy them
to the appropriate etc folder.  Thus keeping an R\library folder
and running the batch file after each new installation would
address 1, 2 and 4 even without using the same name for the
rw... folder.  This still does not handle the shortcut key which
I would have to handle manually or determine if there is a way
I could also add that to my batch file.

>>
>>Thanks. I think I have it now.  I have:
>>
>>- placed my *.site files and library folder in C:\Program Files\R
>> and have set the R_LIBS variable in Renviron.site to point to
>> C:\Program Files\R\library .
>>
>>- I have a batch file which I placed on my desktop which runs rgui.exe
>> from the bin subfolder of the current version of R (using the registry
>> entry to find it).  That desktop shortcut has the Alt+Ctrl+R shortcut
>> key associated with it since the batch file itself does not change even
>> when I install new versions of R.
>>
>>- each time I install a new version of R I run a batch file which
>> -- copies the R miktex files to the appropriate miktex folder
>> -- refreshes the miktex file name data base
>> -- copies the *.site files in \Program Files\R to the etc subfolder
>>of the current version of R (using the registry entry to find it)
>>
>>Getting this right is something I have been putting off for some time
>>now since I was very concerned that I screw up my entire R installation
>>but with the advice of the two of you I think I have it now.
>>If any of this functionality could be taken over by the standard
>>R installation procedure that would be great but in any case I think
>>I have a solution that works for me now.  Thanks.
>>
> 
> 
> I have cleaned up my batch files (somewhat) and posted them to 
> CRAN. See my recent post:
>https://www.stat.math.ethz.ch/pipermail/r-help/2005-July/073400.html
> 
> If any of this functionality could migrate to R itself that would be great.
> 
> 1. In particular, if R could automatically look in ../R for *.site files if it
> can't find them in .../R/rw/etc and if it could look for a library

This is already implemented, just specify the environment variable 
R_PROFILE which points to your global site file. See ?Startup


> in .../R/library then Rrefresh.bat could be simplified to just refreshing
> MiKTeX and makepkg.bat would not have to set the R_LIBS variable.

Well, same as above, just set R_LIBS. You can do this for all sessions 
by using the windows control panel, you don't need to do it in each session.

Why do you expect others are using a setup like yours?
I do not. And I do not want R to look


> 2. Also if Rcmd CHECK and Rcmd INSTALL were to process .Rbuildignore
> like Rcmd BUILD does then makepkg.bat wo

Re: [Rd] .Rbuildignore {was: ... upgrading an R (WINDOWS) installation ..}

2005-07-06 Thread Uwe Ligges
Gabor Grothendieck wrote:

> On 7/6/05, Uwe Ligges <[EMAIL PROTECTED]> wrote:
> 
>>Gabor Grothendieck wrote:
>>
>>
>>>On 7/6/05, Martin Maechler <[EMAIL PROTECTED]> wrote:
>>>
>>>
>>>>>>>>>"Gabor" == Gabor Grothendieck <[EMAIL PROTECTED]>
>>>>>>>>>   on Wed, 6 Jul 2005 08:24:49 -0400 writes:
>>>>
>>>>...
>>>>...
>>>>
>>>>  Gabor> I have cleaned up my batch files (somewhat) and posted them to
>>>>  Gabor> CRAN. See my recent post:
>>>>  Gabor> 
>>>> https://www.stat.math.ethz.ch/pipermail/r-help/2005-July/073400.html
>>>>
>>>>  Gabor> If any of this functionality could migrate to R
>>>>  Gabor> itself that would be great.
>>>>
>>>>  
>>>>
>>>>
>>>>  Gabor> 2. Also if Rcmd CHECK and Rcmd INSTALL were to
>>>>  Gabor> process .Rbuildignore like Rcmd BUILD does then
>>>>  Gabor> makepkg.bat would not have to do a build first.
>>>>
>>>>No!  {We have been here before, and I had explained before that}
>>>>this is really undesired:  ".Rbuildignore" should contain what is
>>>>ignored by build, but not by "check".
>>>>It does make sense to have extra code and / or checks for 'R CMD check'
>>>>that I as package developer want to run, but that are
>>>>-- too time consuming
>>>>-- too platform specific
>>>>-- ..
>>>>to be run during the daily checks on CRAN (e.g.) /
>>>>to be run by others at all.
>>>>
>>>>{And BTW, AFAIK,  'Rcmd' is now `somewhat deprecated' in favor
>>>>of "R CMD" since the latter is portable }
>>>>
>>>>--
>>>>Martin
>>>>
>>>
>>>
>>>I think its too heavy handed an approach.  This should be up to the package
>>>developer via a switch.  I like to put partially written code and other 
>>>things
>>>not intended for distribution in .Rbuildignore and don't want them checked or
>>>installed until I move them out of .Rbuildignore.  That makes it
>>>possible to keep
>>>everything together.  Without this one must 1. keep them elsewhere
>>>(which I am considering as an alternate approach to what I do now although
>>>it would be a shame) or else 2. write batch files (which I have
>>>written for XP) to do
>>>a prebuild every time one does a check or install.
>>>
>>>One annoying aspect of R CMD is the requirement for capitalization.  Maybe
>>>that's ok on UNIX but on Windows one is used to using upper and lower
>>>case interchangeably.  Its also annoying to have to write two words instead 
>>>of
>>>one for a frequently issued command.   At any rate I always call it through
>>
>>Gabor, honestly, this is nonsense.
>>
>>1. Do you expect that R also changes under Windows because you are used
>>to mix upper and lower case and want to say SUMMARY() or rowsums()?
>>2. Do you really thing it is annoying to type "R CMD" rather than
>>"Rcmd"? Hmm, anybody else has a space bar left for Gabor?
>>
>>Best,
>>Uwe
>>
>>
>>>my Rcmd.bat batch file so its not really an issue for me.
> 
> 
> It was claimed its portable and that is true in the strictest sense that it
> works on both UNIX and Windows but it would be even more
> desirable if it were not just portable but also worked the way the target
> system worked rather than just acting like a UNIX utility does
> on Windows.  Ideally it would work as other Windows utilities work,
> e.g. note that we run the following using upper and lower case and
> get the same result:
> 
> C:> net use ?
> The syntax of this command is:
> NET USE
> [devicename | *] [\\computername\sharename[\volume] [password | *]]
> ...
> 
> C:> NET USE ?
> The syntax of this command is:
> NET USE
> [devicename | *] [\\computername\sharename[\volume] [password | *]]
> ...

No! That something completely different: If Windows allows to use "net 
use" and "NET USE" even if only the latter is the documeted way, OK. 
These are, as you mentioned yourself, *Windows utilities* and you don't 
want to port this syntax.

But if you type "R cmd", it is no longer portable, and "Rcmd" for sure 
is not. "R CMD" is an R utility --- and R behaves case senstive.

Uwe Ligges



> A Windows user does not expect the case sensitive behaviour
> since just about all the software one uses does not work that way.
> I got tripped up by it myself and obviously others do too.  e.g. see
> this recent post:
> https://www.stat.math.ethz.ch/pipermail/r-help/2005-June/073154.html
> 
> I was just pointing out this undesirable aspect.  It may be a small point
> but the sum of small inconsistencies can collectively amount to substantial
> difficulty and contribute to the feeling that software is hard to use.
> 
> On the other point, I may be spacebar-challenged but Rcmd does address 
> these points.

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] R_alloc problems in R v1.11

2005-07-07 Thread Uwe Ligges
Kjell Konis wrote:

> On 6 Jul 2005, at 22:06, Uwe Ligges wrote:
> 
> 
>>Marie-Hélène Ouellette wrote:
>>
>>
>>>I'm using the R v1.11 on Macintoch and I seem to have a problem  
>>>with the
>>>
>>
>>There is no version 1.11, and there never was. Current is 2.1.1  
>>anything
>>older than 2.x.y is unsupported these days.
> 
> 
> The latest version of R for OSX available on CRAN (R-2.1.0a.dmg)  
> reports itself as "Version 1.11 (1.11)".  This is actually the  
> version of the Macintosh GUI and not the underlying R framework  
> (which is 2.1.0) but it is found where traditional mac users are  
> going to look to find the version information: R -> About R.
> 
> I think I may have also stumbled across a tiny little bug in .C.  I  
> forgot to capitalize Hello:
> 
>  > .C("hello", as.integer(5))
> Error in .C("hello", as.integer(5)) : "C" function name not in load  
> table

No, it is intended to say "C" or "Fortran", AFAICS.

Uwe Ligges

> I think it should say '"hello" function name not in load table'.
> 
> Kjell
> 
> __
> R-devel@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] Hmisc_3.0-1.zip (PR#8005)

2005-07-12 Thread Uwe Ligges
[EMAIL PROTECTED] wrote:

> Full_Name: Guy Horev
> Version: 2.0.1
> OS: WinXP
> Submission from: (NULL) (192.114.161.178)
> 
> 
> It seems that the file Hmisc_3.0-1.zip in CRAN is corrupted, it should be 1.8M

And it is, at least on the CRAN master in Vienna.

Uwe Ligges


> but only 1.47M are saved, when trying to install localy or from the net the
> following message apears:
> Error in file(file, "r") : unable to open connection
> In addition: Warning messages: 
> 1: error 1 in extracting from zip file 
> 2: cannot open file `Hmisc/DESCRIPTION' 
> 
> other packages works fine
> 
> __
> R-devel@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] a possible bug in svmlight (PR#8012)

2005-07-18 Thread Uwe Ligges
Luke wrote:

> Well, it is explicite only for the guru. :)

Let me add a few of points:

1. We already thought about including svmlight, but get stuck there due 
to some licensing issues, AFAIR. We might want to force getting there, 
though.

2. library(help=klaR) says:
   SystemRequirements:   SVMlight
?klaR says:
In title: "Interface to SVMlight"
^^^ ^^ ^^
In the arguments section (including a typo that should not matter):
"pathsvm  Path to SVMlight binaries (required, if path os unknown by the 
OS)."
Gabor already told about the note in the examples.

I will add an explicit section telling people something like "Can only 
interface to SVMlight if SVMlight is available". Unfortunately, Rd files 
do not have the markup that allows to make it red and blinking. ;-)

3. Please NEVER send bug reports of contributed packages to the bug 
tracking system of R. R Core cannot do anything re. contributed 
packages, and maintainers of contributed packages cannot mark the bug as 
"fixed" in the bug tracking system ...
Instead, please notify the maintainer.


Uwe Ligges





> On 7/18/05, Gabor Grothendieck <[EMAIL PROTECTED]> wrote:
> 
>>Actually it does.  Look in the examples section of ?svmlight
>>
>>On 7/18/05, Luke <[EMAIL PROTECTED]> wrote:
>>
>>>If it is true, I wonder why the help page of svmlight doesn't mention
>>>this requirement explicitly.
>>>
>>>-Luke
>>>
>>>On 7/18/05, Gabor Grothendieck <[EMAIL PROTECTED]> wrote:
>>>
>>>>The CRAN package does not include the svmlight binaries.
>>>>Perhaps you installed klaR but not svmlight binaries?
>>>>You need to place them somewhere on your path.
>>>>
>>>>On 7/18/05, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
>>>>
>>>>>When I used svmlight, I got below error:
>>>>>
>>>>>my command is:
>>>>>foo <- svmlight(y~., data= myData)
>>>>>
>>>>>the results:
>>>>>Error in file(con, "r") : unable to open connection
>>>>>In addition: Warning messages:
>>>>>1: svm_learn not found
>>>>>2: cannot open file '_model_1.txt'
>>>>>
>>>>>
>>>>>>myData[1:2,]
>>>>>
>>>>> y X1 X2 X3 X4  X5  X6 X7 X8 X9 X10 X11 X12 X13 X14 X15 X16 X17
>>>>>1 1 63  1  0  0 145 233  1  1  0 150   0 2.3   1   0   0   1   0
>>>>>2 0 67  0  1  0 160 286  0  1  0 108   1 1.5   0   1   3   0   1
>>>>>
>>>>>The klaR version is 0.4-1
>>>>>OS: trying on windows and Linux gives me the same error
>>>>>
>>>>>-Luke
>>>>>
>>>>>__
>>>>>R-devel@r-project.org mailing list
>>>>>https://stat.ethz.ch/mailman/listinfo/r-devel
>>>>>
>>>>
> 
> __
> R-devel@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] tree/graph data structure APIs?

2005-08-03 Thread Uwe Ligges
Andrew Piskorski wrote:

> What is the best code available for simple general purpose
> manipulation of tree (and/or directed graph) data structures in R?
> 
> Looking through CRAN, I see a bunch of packages for stastical
> regression trees, but nothing that seems to provide an API for
> manipulating tree data structures.  What I'm looking for is something
> along the lines of an R version of the Tcllib ::struct::tree API
> available for Tcl:
> 
>   http://wiki.tcl.tk/210
>   http://tcllib.sourceforge.net/doc/struct_tree.html
>   http://tcllib.sourceforge.net/doc/graph.html
> 
> Thanks!
> 

Maybe the people working on graphical models have something you are 
looking for, see http://www.r-project.org/gR/.
Have you looked at the "dynamicGraph" package?

Uwe Ligges

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] Memory leakage/violation?

2005-08-27 Thread Uwe Ligges
Thomas Lumley wrote:
> I can't reproduce this on R2.2.0dev on Windows XP (in a few hundred 
> tries), or running under Valgrind on AMD64 Linux (in four or five tries).

Cannot reproduce either (using R-2.1.1 and an older version of R-devel, 
though). Maybe a compiler issue?
Henrik, do you use exactly the compiler set up mentioned in the manuals? 
Which version of gcc? Did your emember to replace the f771.exe?

Uwe



>   -thomas
> 
> 
> On Fri, 26 Aug 2005, Henrik Bengtsson wrote:
> 
> 
>>Hi,
>>
>>I've spotted a possible memory leakage/violation in the latest R v2.1.1
>>patched and R v2.2.0dev on Windows XP Pro SP2 Eng.
>>
>>I first caught it deep down in a nested svd algorithm when subtracting a
>>double 'c' from a integer vector 'a' where both had finite values but
>>when assigning 'a <- a - c' would report NaNs whereas (a-c) alone would
>>not.  Different runs with the identical data would introduce NaNs at
>>random positions, but not all the time.
>>
>>Troubleshooting is after a couple of hours still at v0.5, but here is a
>>script that generates the strange behavior on the above R setups.  I let
>>the script speak for itself.  Note that both the script 'strange.R' and
>>the data 'strange.RData' is online too, see code below.
>>
>>People on other systems (but also on Windows), could you please try it
>>and see if you can reproduce what I get.
>>
>>Cheers
>>
>>Henrik
>>
>>
>># The following was tested on: Windows XP Pro SP2 Eng with
>>#   i) R Version 2.1.1 Patched (2005-08-25)
>>#  ii) R 2.2.0 Under development (unstable) (2005-08-25 r35394M)
>>
>># Start 'R --vanilla' and source() this script, i.e.
>>#  source("http://www.maths.lth.se/help/R/strange.R";)
>># If you do not get any errors, retry a few times.
>>
>>foo <- function(x) {
>>  print(list(
>>name=as.character(substitute(x)),
>>storage.mode=storage.mode(x),
>>na=any(is.na(x)),
>>nan=any(is.nan(x)),
>>inf=any(is.infinite(x)),
>>ok=all(is.finite(a))
>>  ))
>>  print(length(x))
>>  print(summary(x))
>>}
>>
>># Load data from a complicated "non-reproducible" algorithm.
>># The below errors occur also when data is not
>># saved and then reloaded from file.  Data was generated in
>># R v2.1.1 patched (see above).
>>if (file.exists("strange.RData")) {
>>  load("strange.RData")
>>} else {
>>  load(url("http://www.maths.lth.se/help/R/strange.RData";))
>>}
>>
>># First glance at data...
>>foo(a)
>>foo(c)
>>
>>## $name
>>## [1] "a"
>>##
>>## $storage.mode
>>## [1] "integer"
>>##
>>## $na
>>## [1] FALSE
>>##
>>## $nan
>>## [1] FALSE
>>##
>>## $inf
>>## [1] FALSE
>>##
>>## $ok
>>## [1] TRUE
>>##
>>## [1] 15000
>>##Min. 1st Qu.  MedianMean 3rd Qu.Max.
>>##41.051.063.0   292.2   111.0 65170.0
>>## $name
>>## [1] "c"
>>##
>>## $storage.mode
>>## [1] "double"
>>##
>>## $na
>>## [1] FALSE
>>##
>>## $nan
>>## [1] FALSE
>>##
>>## $inf
>>## [1] FALSE
>>##
>>## $ok
>>## [1] TRUE
>>##
>>## [1] 1
>>##Min. 1st Qu.  MedianMean 3rd Qu.Max.
>>##   53.43   53.43   53.43   53.43   53.43   53.43
>>##
>>
>># But, trying the following, will result in
>># no-reproducible error messages. Sometimes
>># it errors at kk==1, sometimes at kk >> 1.
>># Also, look at the different output for
>># different kk:s.
>>for (kk in 1:100) {
>>  cat("kk=",kk, "\n")
>>  print(summary(a-c))
>>}
>>
>>## kk= 1
>>##  Min. 1st Qu.  MedianMean 3rd Qu.Max.
>>## -7.741e+307  -2.431e+00   9.569e+00   5.757e+01
>>## kk= 2
>>##Min.   1st Qu.Median  Mean   3rd Qu.  Max.
>>##   -12.430-2.431 9.569   238.70057.570 65120.000
>>## kk= 3
>>##Min.   1st Qu.Median  Mean   3rd Qu.  Max.
>>##   -12.430-2.431 9.569  57.570 65120.000
>>## kk= 4
>>##Min.   1st Qu.Median  Mean   3rd Qu.  Max.
>>##   -12.430-2.431 9.569   238.70057.570 65120.000
>>## kk= 5
>>##Min.   1st Qu.Median  Mean   3rd Qu.  Max.
>>##   -12.430-2.431 9.569   238.70057.570 65120.000
>>## kk= 6
>>## Error in quantile.default(object) : missing values and NaN's
>>## not allowed if 'na.rm' is FALSE
>>
>>
>>## Comments: If you shorten down 'a', the bug occurs less frequently.
>>
>>__
>>R-devel@r-project.org mailing list
>>https://stat.ethz.ch/mailman/listinfo/r-devel
>>
> 
> 
> Thomas Lumley Assoc. Professor, Biostatistics
> [EMAIL PROTECTED] University of Washington, Seattle
> 
> __
> R-devel@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] error in apply help file? (PR#8118)

2005-09-01 Thread Uwe Ligges
[EMAIL PROTECTED] wrote:

> Gents: (alas, I think no ladies need to be included in the salutation)


May I ask why you think R-devel (to which R-bugs stuff is forwarded) is 
only read by males?

Sounds a little bit discriminating ("Only males produce bugs, females 
simply produce perfect code and do not need to read R-devel mails."??!). 
Hence, I'd like to complain in this case.

Uwe Ligges



> The apply()  Help file says
> "...
> If the calls to FUN return vectors of different lengths, apply returns a
> list of length dim(X)[MARGIN]. "
> 
> Shouldn't that be:
> 
> "If the calls to FUN return vectors of different lengths, apply returns a
> list of length prod(dim(X)[MARGIN]). "
> 
> Also, might you wish to add:
> 
> "This list has a dim attribute of MARGIN. That is, if VALUE is the returned
> list, dim(VALUE) = MARGIN and the values in VALUE can be accessed by the
> usual array subscripting operations."
> 
> Further, it might also be useful to add the following to your Examples code:
> 
> ## Example with different lengths for each call
> z <- array(1:24,dim=2:4)
> zseq <- apply(z,1:2,function(x)seq(length=max(x)))
> zseq  ## displayed as a 2 x 3 matrix
> typeof(zseq) ## list
> dim(zseq) ## 2 3
> zseq[1,]
> 
> 
> Feel free to ignore these suggestions, of course. 
> 
> Cheers,
> 
> -- Bert Gunter
> Genentech Non-Clinical Statistics
> South San Francisco, CA
> 
> __
> R-devel@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] R CMD check and interfacing packages

2005-09-03 Thread Uwe Ligges
Gabor Grothendieck wrote:

> For an R package whose purpose is to interface to other software,
> since such other software is not necessarily being on CRAN how does one 
> proceed so that the R package can pass 'R CMD check'?  None 
> of the examples or demos in the package can run without the software 
> being interfaced to.

Yes, this is a problem.
For this reason, we have some exceptions on CRAN for packages that 
interface to other software products, e.g. for some we are doing only 
fake installations and for others, I am skipping automatical checks for 
Windows, if GUI interaction is required.


> Is there an example of such a package that could be used as a 
> prototype?

I don't think there is a globally perfect example.
It depends on the software you are going to interface to, on the 
Operating Systems this software is available on, and on the license and 
the requirements for linking against it etc

Uwe Ligges


> Thanks.
> 
> __
> R-devel@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] Install packages to non-default lib on Windows

2005-09-08 Thread Uwe Ligges
Duncan Murdoch wrote:

> Seth Falcon wrote:
> 
>>We are trying to setup a Windows server that will allow any of our
>>users to build a binary R package given a source package.
>>
>>The idea is to have a central R installation and allow users to
>>install packages to their own package library for the purposes of
>>binary package building.
>>
>>It seems, however, that write access to $R_HOME is required as part of
>>the install step even when -l is used to specify an alternate package
>>library.
>>
>>here's an example of what we're seeing:
>>
>>C:\rlibdir\hpages>set R_LIBS=c:\rlibdir\hpages
>>
>>C:\rlibdir\hpages>d:\biocbld\R-devel\bin\R CMD INSTALL -l=%R_LIBS% --build 
>>Biobase_1.6.7.tar.gz
>>
>>Using auto-selected zip options 'Biobase-ZIPDATA=zip Biobase-HELP=ziponly'
>>
>>-- Making package Biobase 
>>  adding build stamp to DESCRIPTION
>>  installing NAMESPACE file and metadata
>>  making DLL ...
>>  ... DLL made
>>  installing DLL
>>  installing R files
>>  save image
>>Loading required package: tools
>>Creating a new generic function for 'ncol' in 'Biobase'
>>
>>  installing inst files
>>  installing data files
>>  installing man source files
>>  installing indices
>>cannot create d:/biocbld/R-devel/doc/html/search/index.txt: permission denied

I was also annoyed about this point a couple of times. But what are 
possible solutions?

- not updating indices at all?
- provide a switch such as --no-indices for the R CMD tools?
- ...?

short time workaround: simply give users write access to the few files 
that have to write to.


Uwe Ligges



>>make[2]: *** [indices] Error 2
>>make[1]: *** [all] Error 2
>>make: *** [pkg-Biobase] Error 2
>>*** Installation of Biobase failed ***
>>
>>Removing 'c:/rlibdir/hpages/Biobase'
>>
>>
>>Questions:
>>
>>- Is it possible to build a binary package on Windows without write
>>  access to the $R_HOME tree?
>>
>>- Is it still the case that a side-effect of building a binary package
>>  is having that package be installed?  My understanding is that R CMD
>>  INSTALL --build is the way to get zips on Windows, but maybe this
>>  changed?
> 
> 
> There are two ways:  R CMD INSTALL --build, and R CMD build --binary. 
> The latter doesn't do an install, so the links in help pages don't get 
> generated properly, but it may do a good enough job for what you need.
> 
> Duncan Murdoch
> 
> __
> R-devel@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] \dontshow

2005-09-10 Thread Uwe Ligges
Gabor Grothendieck wrote:

> On 9/9/05, Gabor Grothendieck <[EMAIL PROTECTED]> wrote:
> 
>>In R 2.2.0 I find that even if I use \dontshow in the examples section
>>of an .Rd file that the code still shows.
>>
>>Has anyone else seen this?
>>
>>Are there any packages that use this facility that I could
>>try in order to check this?
>>
>>I am using
>>
>>
>>>R.version.string # XP
>>
>>"R version 2.2.0, 2005-09-03"
>>
> 
> 
> I realize that this description was not clear enough.  It does not
> show in the help file but when you run the example it shows
> and it was that part I was concerned about.  Is that the way its
> supposed to work?

Yes:

Examples displayed and executed during checks/example runs:
   as is
Examples displayed but NOT executed during checks/example runs:
   \dontrun{}
Examples NOT displayed but executed during checks/example runs:
  \dontshow{}
Examples NOT displayed and NOT executed during checks/example runs:
  simply don't type them anywhere ;-)


Best,
Uwe Ligges



> 
> __
> R-devel@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] R.version.string (Re: MikTeX will be assumed in R 2.2.0 in Windows)

2005-09-10 Thread Uwe Ligges
Gabor Grothendieck wrote:
> On 9/10/05, Duncan Murdoch <[EMAIL PROTECTED]> wrote:
> 
>>Gabor Grothendieck wrote:
>>
>>>On 9/9/05, Duncan Murdoch <[EMAIL PROTECTED]> wrote:
>>>
>>>
>>>>I've just committed some changes to allow R to be built and to use
>>>>MikTeX without needing the Rd.sty files to be installed to localtexmf.
>>>>Unfortunately, the changes are not compatible with other TeX packages,
>>>>so if you're not using MikTeX you'll need to edit a couple of the config
>>>>files (or set an environment variable).
>>>>
>>>>I'd appreciate hearing of any problems during the alpha or beta test period.
>>>>
>>>>A binary build containing the changes should be on CRAN tomorrow or the
>>>>next day.  Look for revision 35546 or higher.
>>>
>>>
>>>Note that R.version.string in R 2.2.0 2005-09-03 does not give
>>>this sort of version information.  If we are going to use this style
>>>I suggest we modify R.version.string accordingly.
>>
>>You can get the revision number from the startup banner if you download
>>a binary build.
>>
>>Duncan Murdoch
>>
>>
> 
> 
> I normally document what version I am using by displaying R.version.string.
> If R.version.string is no longer definitive
  ^
It never was for non-released versions checked out from svn (or cvs in 
the older days) ...

Uwe Ligges


 > under 2.2.0 then it either needs to
> be modified so that it is or we need some other way of getting that
> capability.
> 
> __
> R-devel@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] Issue tracking in packages [was: Re: [R] change in, read.spss, package foreign?]

2005-09-10 Thread Uwe Ligges
Frank E Harrell Jr wrote:

> I would vote for allowing a URL or external file name in in DESCRIPTION, 
> whose contents could be automatically displayed for the user when 
> needed.  Our changelogs are automatically generated by CVS and are on 
> the web.

 From a repositoriy maintainer's point of view:
Yes, if people really want it, then please something in a DESCRIPTION 
file. Lookup whether a file exists takes a lot of time, in particular if 
you do not have the source package in an extracted form.

Note that CRAN does not have to handle one or two packages, but 
processes 600 for each repository...

Uwe Ligges

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


[Rd] contributed Windows binary packages for R-2.2.0 alpha

2005-09-12 Thread Uwe Ligges
Dear package developers,

contributed Windows binary packages for R-devel are available for some 
time now and should have propagated through CRAN.

I have re-compiled and re-checked all packages under R-2.2.0 alpha again 
today. Results will propagate through CRAN within a couple of days (on 
CRAN master in a few hours).
Maintainers of packages that produce an ERROR now and have not produced 
an ERROR before have just been notified by automatical generated 
messages. All others might want to check whether there is a WARNING for 
their packages.

Best,
Uwe Ligges

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] as.Date() , feature or bug?

2005-09-14 Thread Uwe Ligges
Bo Peng wrote:

> Under linux and windows,
> 
> 
>>as.Date("-06-06")
> 
> [1] "-06-06"
> 
>>as.Date("-07-07")
> 
> [1] "1970-01-01"
> 
> 
> Feature? Bug? help(as.Date) does not mention this case.

Well, bug, if you really want to call it a bug that you cannot represent 
the year . ;-)

I guess this is some overflow in do_POSIXlt2D that is not protected 
against misuse. Don't see the point right now, I have to admit.


 > as.Date("6970-12-31")
[1] "6970-12-31"
 > as.Date("6971-01-01")
[1] "1970-01-01"


So we cannot represent more than 5000 years into the future, roughly 
speaking. *Guess* the problem is that we need more than 4 digits for +/- 
5000 years (sum=1).

Uwe Ligges


> Bo.
> 
> __
> R-devel@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] as.Date() , feature or bug?

2005-09-14 Thread Uwe Ligges
Bo Peng wrote:

>>Well, bug, if you really want to call it a bug that you cannot represent
>>the year . ;-)
> 
> 
> So I guess we need a warning message and a line in help(as.Date)?

Even better a fix (than an *error* message), since the POSIX classes can 
handle the date and I do not (yet) see the reason why Date cannot. But I 
have no time to dig deeper (at least not this week).


Uwe Ligges


> Bo
> 
> __
> R-devel@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] List of languages supported

2005-09-18 Thread Uwe Ligges
Gabor Grothendieck wrote:
> Is there a list of languges supported by R:
> 
> - languages for which one can get various screen text in that language

Simply look into file .../po/Linguas
For R-2.2.0 alpha it has:

en
en_GB
fr
de
it
ja
ko
pt_BR
ru
zh_CN
[EMAIL PROTECTED]




> - languages into which the manuals have been translated

The corresponding web page is CRAN/other-docs.html
It contains links to the Japanese translations. I do not know of other 
translations.



> I assume that locale support is OS-specific but that the above
> are not.

Yes.

Uwe Ligges

> Thanks.
> 
> __
> R-devel@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] Lists and data frames (PR#8143)

2005-09-19 Thread Uwe Ligges
Gavin Simpson wrote:

> On Mon, 2005-09-19 at 15:34 +0200, [EMAIL PROTECTED] wrote:
> 
>>Full_Name: Frank Wagner
>>Version: R 2.1.1
>>OS: Windows
>>Submission from: (NULL) (193.174.73.34)
>>
>>
>>Hi,
>>The pdf file R-intro descripe on page 27 that lists can be extended by adding
>>numbers.
>>Unfortunately, it's not working 
>>## example :
>>
>># if i did not declare the variable an error occurs : object not found
>>mylist <- list() 
>>mylist[1] <- list(value1=3, value2=5)
>>## Error
> 
> 
> You need to use [[x]] to subset a list:
> 
> 
>>mylist <- list()
>>mylist[[1]] <- list(value1=3, value2=5)
>>mylist
> 
> [[1]]
> [[1]]$value1
> [1] 3
> 
> [[1]]$value2
> [1] 5


This is a list of a list, but that is not the same as the stuff we are 
discussing here. See below.


> 
>>str(mylist)
> 
> List of 1
>  $ :List of 2
>   ..$ value1: num 3
>   ..$ value2: num 5
> 
> I don't know whether there is a typo on page 27 or not: [x] is valid, it
> just means something different to [[x]] - as explained on page 26 of
> said manual. If it was intentional, then IMHO it is not the most clear
> example of extending a list - the [[x]] notation is what I would expect
> to have to use - after reading page 26 of course...

Folks, please specify which version of the manual you are speaking 
about, e.g. by giving a chapter's/section's name.

The statement on what is referred to page 27 in this thread is completly 
correct.

Note that a list is nothing else than a vector of mode list which 
contains in each element a list of length one.

Hence you *can* say
mylist[1:2] <- list(value1=3, value2=5)
or
c(mylist, list(value1=3, value2=5))
or whatever.


Uwe Ligges



> HTH
> 
> G

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] undocumented objects in a package

2005-09-23 Thread Uwe Ligges
Liaw, Andy wrote:

> Dear R-devel,
> 
> I recall that there used to be a mechanism to get around the requirement
> that all objects in a package have associated documentation; i.e., a way to
> specify a list of objects (mostly functions) that are not considered as part
> of the package API.  Is this still available?  I cannot find any mention in
> R-exts.
> 
> I realize that the way to go is to have a name space, and eventually that's
> what I will do, but for now I rather spend the time doing other necessary
> clean-ups first.  
> 
> Any pointer much appreciated!


E.g. just make one simple help page with keyword "internal" with aliases 
for all the functions. You do not need to write exact documentation in 
this case.

Uwe Ligges

> Best,
> Andy
> 
> Andy Liaw, PhD
> Biometrics Research  PO Box 2000, RY33-300 
> Merck Research Labs   Rahway, NJ 07065
> mailto:[EMAIL PROTECTED]732-594-0820
> 
> __
> R-devel@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] bug in gsub with perl=TRUE (PR#8164)

2005-09-30 Thread Uwe Ligges
[EMAIL PROTECTED] wrote:

> Full_Name: Richard Mott
> Version: 2.0.1

This version is completely outdated.
Please try with a *recent* version of R when reporting bugs, in this 
case R-2.2.0 beta (or in worst case R-2.1.1, the current release).

The bug reported below has been fixed some months ago ...

Uwe Ligges

> OS: Linux toad 2.6.9 #4 SMP Mon Feb 21 16:20:16 GMT 2005 x86_64 AMD 
> Opteron(tm) Processor 848 AuthenticAMD GNU/Linux
> Submission from: (NULL) (129.67.46.247)
> 
> 
> gsub with perl=TRUE does not work properly. It pads/truncates the resulting
> string to
> the length of the input string: 
> 
> my.formula <- "log10(Biochem.ALP)^2+1 ~ Family + GENDER"
> 
> 
>>gsub("^.+~", "transformed.y ~", my.formula )
> 
> [1] "transformed.y ~ Family + GENDER"
> 
> 
>>gsub("^.+~", "transformed.y ~", my.formula, perl=TRUE )
> 
> [1] "transformed.y ~ Family + GENDER\0\006\0\0\r\377\0\0\0"  # padded
> 
>  my.formula <- "Biochem.ALP ~ Family + GENDER"
> 
>>gsub("^.+~", "transformed.y ~", my.formula, perl=TRUE )
> 
> [1] "transformed.y ~ Family + GEND"  # truncated
> 
>>gsub("^.+~", "transformed.y ~", my.formula )
> 
> [1] "transformed.y ~ Family + GENDER"
> 
> __
> R-devel@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] MiKTeX/yap/Ghostcript issues with R-generated postscript

2005-10-11 Thread Uwe Ligges
Dominick Samperi wrote:

> Hello,
> 
> I wonder if anybody has encountered this problem?
> 
> While MiKTeX/yap/Ghostscript seems to work fine on most TeX files that I 
> have
> tested (including a great deal of postscript graphics), there is one 
> file where the
> graphics works ok for all postscript files except one, the only one that 
> is generated
> by R. I get an error "Some postscript specials could not be rendered", 
> and the
> details of the error message are in the attached file.
> 
> This same dvi file displays fine under Linux.
> 
> I'm using yap from MiKTeX 2.4 with the "most popular" installation option.
>


Hmmm, has not happened for me within the last couple of years I was 
using R + MikTeX 2.4 ...

Can you specify a reproducible example for the R code that produces that 
PostScript file, please?
[Wild guess: Maybe you forgot to close the device by dev.off()?]

Uwe Ligges



> Any tips would be appreciated,
> Dominick
> 
> 
> 
> 
> Error: /undefined in [EMAIL PROTECTED]
> Operand stack:
>--nostringval--   PermitFileReading   --nostringval--   PermitFileWriting  
>  --nostringval--
> Execution stack:
>%interp_exit   .runexec2   --nostringval--   --nostringval--   
> --nostringval--   2   %stopped_push   --nostringval--   --nostringval--   
> --nostringval--   false   1   %stopped_push   1   3   %oparray_pop   1   3   
> %oparray_pop   1   3   %oparray_pop   1   3   %oparray_pop   .runexec2   
> --nostringval--   --nostringval--   --nostringval--   2   %stopped_push   
> --nostringval--
> Dictionary stack:
>--dict:1125/1686(ro)(G)--   --dict:0/20(G)--   --dict:71/200(L)--   
> --dict:95/300(L)--   --dict:63/200(L)--
> Current allocation mode is local
> MiKTeX GPL Ghostscript 8.15: Unrecoverable error, exit code 1
> 
> 
> 
> 
> __
> R-devel@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] rgl package demo causes R memory corruption under Windows

2005-10-13 Thread Uwe Ligges
Dominick Samperi wrote:

> Hello,
> 
> Running the rgl demo package (demo(rgl)) causes memory corruption when 
> used with
> R 2.2.0 under Windows. I tested on two Windows systems: Windows 2000 and 
> Windows XP.
> 
> When you terminate R after running the demo you get a message about the 
> application
> trying to reference invalid memory. If you try to run another 
> application in R after running
> the rgl demo it typically fails.
> 
> Dominick
> 
> __
> R-devel@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel


Dominick,

this report is package related. Please contact the package maintainer 
who might be willing to help to debug on your machine.
I cannot reproduce this neither on Windows NT4 SP6 nor on Windows Server 
2003 SP1.

Uwe

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] Installing R-2.2.0 package

2005-10-13 Thread Uwe Ligges
Dean, David P wrote:

> Dear list,
> 
> I've just installed R-2.2.0 under Solaris and have a question about
> installing packages. If a package fails to install for any reason and I go
> to install another package, I get this message:
> 
> $ R-2.2.0-64bit --vanilla CMD INSTALL ~/srca/cran/RSQLite_0.4-0.tar.gz 
> ERROR: failed to lock directory
> '/app/openpkg/lib/R-2.2.0-64bit/lib/R/library' for modifying
> Try removing '/app/openpkg/lib/R-2.2.0-64bit/lib/R/library/00LOCK'
> 
> I can remove the lock directory by hand, and then the next package installs,
> but this makes it quite difficult to download and install a batch of
> packages from CRAN or Biocondctor! Is this lock directory a new feature with
> R-2.2.0? Is there a work around in the R build itself or the installation
> scripts?

No, not a new feature in R-2.2.0, it has been there for some time now.
After a *successful* installation, the 00LOCK directory should be 
deleted by the installation tools themselves.
After an unsuccessful installation, the installation tools should 
restore the stuff in the 00LOCK directory.
Do you abort the installtion manually (this is the only way I figured 
out how not to remove 00LOCK automatically)?

Uwe Ligges



> 
> Much thanks!!!
> - 
> David P Dean
> Research Informatics
> PGRD Groton Labs
> (860)-441-5053
> [EMAIL PROTECTED]
> --
> LEGAL NOTICE\ Unless expressly stated otherwise, this messag...{{dropped}}
> 
> __
> R-devel@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] Installing R-2.2.0 package

2005-10-13 Thread Uwe Ligges
Paul Gilbert wrote:

> 
> 
> Uwe Ligges wrote:
> 
>> Dean, David P wrote:
>>
>>  
>>
>>> Dear list,
>>>
>>> I've just installed R-2.2.0 under Solaris and have a question about
>>> installing packages. If a package fails to install for any reason and 
>>> I go
>>> to install another package, I get this message:
>>>
>>> $ R-2.2.0-64bit --vanilla CMD INSTALL 
>>> ~/srca/cran/RSQLite_0.4-0.tar.gz ERROR: failed to lock directory
>>> '/app/openpkg/lib/R-2.2.0-64bit/lib/R/library' for modifying
>>> Try removing '/app/openpkg/lib/R-2.2.0-64bit/lib/R/library/00LOCK'
>>>
>>> I can remove the lock directory by hand, and then the next package 
>>> installs,
>>> but this makes it quite difficult to download and install a batch of
>>> packages from CRAN or Biocondctor! Is this lock directory a new 
>>> feature with
>>> R-2.2.0? Is there a work around in the R build itself or the 
>>> installation
>>> scripts?
>>>   
>>
>>
>> No, not a new feature in R-2.2.0, it has been there for some time now.
>>  
>>
> I have the impression the feature behaves slightly differently as of 
> R-2.2.0. Now the 00LOCK file is not removed in Solaris when there is an 
> unsuccessful install. (In Linux I think it does get removed.)

Yes, under both Linux and Windows it is removed.

Can anybody else check on Solaris, please? Or can David Dean debug on 
his machine?

In particular, we need exact system information, because it seems to be 
an OS/platform specific problem.

Uwe Ligges




> Paul Gilbert
> 
>> After a *successful* installation, the 00LOCK directory should be 
>> deleted by the installation tools themselves.
>> After an unsuccessful installation, the installation tools should 
>> restore the stuff in the 00LOCK directory.
>> Do you abort the installtion manually (this is the only way I figured 
>> out how not to remove 00LOCK automatically)?
>>
>> Uwe Ligges
>>
>>
>>
>>  
>>
>>> Much thanks!!!
>>> - David P Dean
>>> Research Informatics
>>> PGRD Groton Labs
>>> (860)-441-5053
>>> [EMAIL PROTECTED]
>>> --
>>> LEGAL NOTICE\ Unless expressly stated otherwise, this 
>>> messag...{{dropped}}
>>>
>>> __
>>> R-devel@r-project.org mailing list
>>> https://stat.ethz.ch/mailman/listinfo/r-devel
>>>   
>>
>>
>> __
>> R-devel@r-project.org mailing list
>> https://stat.ethz.ch/mailman/listinfo/r-devel
>>  
>>

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] expm1, R-2.2.0 and Windows

2005-10-14 Thread Uwe Ligges
Prof Brian Ripley wrote:

> On Fri, 14 Oct 2005, [UTF-8] Göran Broström wrote:
> 
>> A user of 'eha' told me that it failed to load in R-2.2.0 on 
>> Windows,and ideed, I checked and it fails with the error message 
>> "Theprocedure entry point expm1 could not be located in the dynamic 
>> linklibary R.dll". I'm using expm1 (from the C math library on Linux, 
>> Iwould guess) in a couple of C functions.
> 
> 
>> This didn't happen with R-2.1.1 (and it doesn't happen with R-2.2.0 
>> ondebian), so I need advise about what to do. File a bug report?
> 
> 
> Please do re-read the rw-FAQ Q4.1 for advice!
> 
> The eha binary on CRAN was built on Sept 12, before the release of 2.2.0
> (and before the beta period).  It needs to be built under 2.2.0, when it 
> will work.  (Uwe, could you please trigger rebuilds as some things were 
> changed in the alpha period, including the version of the mingw-runtime 
> that is required.)

Thanks for the pointer!
Hmmm, thought I did so after the release, but apparently not (most 
outdated builds are from 2005-09-11, hence a version of R-2.2.0 alpha).

eha has been rebuild now and will appear on CRAN master within 24 hours.

I will trigger rebuilds for the other packages as well, but it will take 
its time (don't expect any change on CRAN within 24 hours).

Nice occasion: Package mainatiner of failing packages will receive (yet 
another) message that some action is required ...

Uwe



> 
> 
> 
> __
> R-devel@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] Matrix (PR#8321)

2005-11-18 Thread Uwe Ligges
P Ehlers wrote:

> Actually, my guess about PACKAGES was wrong. I just removed Matrix
> and re-installed Matrix_0.99-2 (Rgui: Packages menu) from CRAN and
> had no problems.


The outdated Matrix version will disappear from CRAN master within 24 
hours. Two versions in the repository do not cause any problems.

I think Cougar Lawrence has to tell us what "do not load" means, i.e. 
his setup of packages and libraries, his call to load Matrix as well as 
the error message.

Uwe Ligges




> You'll have to be more explicit about "will not load".
> 
> Peter
> 
> 
> Cougar Lawrence wrote:
> 
> 
>>Thanks for the reply.  I am using windows.  I tried both packages.  The
>>directions under Matrix indicate that package 99.2 is current.  It is the
>>one that will not load.
>>
>>Respectfully,
>> 
>>Frank Lawrence
>>
>>
>>-Original Message-
>>From: P Ehlers [mailto:[EMAIL PROTECTED] 
>>Sent: Thursday, November 17, 2005 16:53
>>To: [EMAIL PROTECTED]
>>Cc: r-devel@stat.math.ethz.ch; [EMAIL PROTECTED]
>>Subject: Re: [Rd] Matrix (PR#8321)
>>
>>
>>Assuming you're on Windows (you didn't say), it looks
>>like the PACKAGES file in /.../contrib/2.2/ has two
>>entries for Matrix. Perhaps that's the problem.
>>
>>Peter
>>
>>
>>[EMAIL PROTECTED] wrote:
>>
>>
>>
>>>It appears to me that the new version of the package Matrix will not 
>>>load to R-2.2.0.
>>>
>>>Respectfully,
>>>
>>>Frank Lawrence
>>>
>>>__
>>>R-devel@r-project.org mailing list 
>>>https://stat.ethz.ch/mailman/listinfo/r-devel
>>
>>
>

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] problem with \eqn (PR#8322)

2005-11-18 Thread Uwe Ligges
Hin-Tak Leung wrote:

> Martin Maechler wrote:
> 
>>>>>>>"Hin-Tak" == Hin-Tak Leung <[EMAIL PROTECTED]>
>>>>>>>   on Fri, 18 Nov 2005 16:38:28 + writes:
>>
>>
>>Hin-Tak> Your own fault. See below. It is basic LaTeX and any LaTeX person
>>Hin-Tak> can tell you the answer...(most probably haven't bothered...)
>>
>>No.  Whereas I partly agree that it's Ross ``fault'' trying to
>>use too smart LaTex (and using outdated \bf instead of \mathbf), 
>>;-)
>>
>>The bug is really there, since we are talking about the Rd "language",
>>not LaTeX, an in Rd,  \eqn and \deqn are defined to have either
>>one or two arguments -- where Ross used the 2-argument version
>>correctly (in principle at least) --> See the manual "Writing R
>>Extensions".
> 
> 
> Forgive me for not reading R-ext carefully, but Ross's Rd code is
> still "obviously" wrong in the lights of the two-argument \eqn:
> (really doesn't differ from the 1-arg interpretaion of \eqn)
> 
> \eqn{{\bf\beta}_j}{\bf\beta}_jnormal-bracket5bracket-normal{b(j)}


No, that is the output after conversion, please read the original 
poster's mail more carefully.

Uwe Ligges


> In other words,
> \eqn{...}{...}_...
> 
> and the "_" is still outside of any maths environment, which is most
> probably not Ross's intention.
> 
> 
>>
>>>> Full_Name: Ross Boylan
>>>> Version: 2.2.0
>>>> OS: Linux
>>>> Submission from: (NULL) (65.175.48.58)
>>>> 
>>>> 
>>>> \eqn{{\bf\beta}_j}{b(j)} in my .Rd file produces this error
>>
>>>> 
>>>> ! Missing $ inserted.
>>>>  
>>>> $
>>>> l.7 \eqn{{\bf\beta}_j}{\bf\beta}_jnormal-bracket5bracket-normal{b(j)}
>>
>>Hin-Tak> \eqn{{\bf\beta}_j} is already syntactically complete, so latex
>>Hin-Tak> complains the next "_" is not in maths mode, and automatically
>>Hin-Tak> switch into maths mode for you (the $ inserted message) You have
>>Hin-Tak> to match all the braces - you need 3 right-braces after \eqn,
>>Hin-Tak> like this, at least:
>>
>>Hin-Tak> \eqn{  {  {\bf\beta
>>Hin-Tak> }_j
>>Hin-Tak> }
>>Hin-Tak> {\bf\beta
>>Hin-Tak> }_ 
>>Hin-Tak> {b(j)
>>Hin-Tak> }
>>Hin-Tak> }
> 
> 
> __
> R-devel@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] winMenuAdd

2005-11-23 Thread Uwe Ligges
Martin Morgan wrote:

> The following
> 
> winMenuAdd("X")
> for (i in 1:20) winMenuAdd(paste("X",i, sep="/"))
> 
> generates an (incorrect) error after adding 12 menu items:
> 
> Error in winMenuAdd(menuname, NULL, NULL) : 
> unable to add menu (base menu does not exist)
> 
> More elaborate examples (e.g., adding menu items to each menu) create
> other errors (e.g., "Only 16 menus are allowed"), and the original
> example (at
> https://stat.ethz.ch/pipermail/bioconductor/2005-November/011010.html)
> crashes with SIGSEGV in rui.c:1389. I think the basic problem is that
> there is a hard-coded limit of 16 menus. The limit is reached in
> Bioconductor, as packages add vignettes.
> 
> R version 2.2.0, 2005-11-21, i386-pc-mingw32 
> 
> attached base packages:
> [1] "methods"   "stats" "graphics"  "grDevices" "utils" "datasets" 
> [7] "base" 

This seems to be a bug introduced in R-patched (and R-devel).

R-2.2.0 release correctly reports:

Error in winMenuAdd(menuname, NULL, NULL) :
 unable to add menu (Only 16 menus are allowed)


Uwe Ligges

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] png support for R 2.2.1 (PR#8425)

2005-12-22 Thread Uwe Ligges
[EMAIL PROTECTED] wrote:

> Full_Name: Sylvain Brohée
> Version: 2.2.1
> OS: Suse Linux 9.2
> Submission from: (NULL) (164.15.109.58)
> 
> 
> I recently went to a new version of R  (2.2.1) but now,  when trying to save a
> plot in the png format, I got this error message :
> 
> 
>>png("my_plot.png")
> 
> Error in X11(paste("png::", filename, sep = ""), width, height, pointsize,  :
> unable to start device PNG
> In addition: Warning message:
> no png support in this version of R
> 
> What can I do?


1. Do not send a bug report if there is no bug! Please read the FAQs and 
learn what a bug is.
2. Do not send identical messages a couple of times to many mailing lists.
3. Do read the installation manuals.
4. Install both "libpng" and "libpng-devel" in a way that it will be 
found by R's configure scripts (e.g. into standard locations).
5. Run R's ./configure and check the last lines of the output, png 
support should be mentioned, if not, check what ./configure told you at 
the point where it looked for libpng.

Uwe Ligges



> Sylvain
> 
> __
> R-devel@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] cygwin and tar -- still?

2005-12-25 Thread Uwe Ligges
Jeff D. Hamann wrote:
> I've upgraded laptops and have put a new version of R on the new machine as 
> well as the tools for building packages. I know R has required a 
> "non-broken" version of tar for some time now and was hoping to not have to 
> install any cygwin tools. Since building packages requires the use of MinGW 
> and MSYS, why can't we simply use the tar that's part of msys?

No, "MSYS" is not required nor supported.


> After looking at the following results:
> 
> E:\conifers>rcmd build --binary rconifers
> * checking for file 'rconifers/DESCRIPTION' ... OK
> * preparing 'rconifers':
> * checking DESCRIPTION meta-information ... OK
> * cleaning src
> * checking whether 'INDEX' is up-to-date ... NO
> * use '--force' to overwrite the existing 'INDEX'
> * removing junk files
> tar: /cygdrive/E/conifers/rconifers_0.0-5.tar: Cannot open: No such file or 
> directory
> tar: Error is not recoverable: exiting now
> tar: /cygdrive/E/conifers/rconifers_0.0-5.tar: Cannot open: No such file or 
> directory
> tar: Error is not recoverable: exiting now
> Error: cannot open file 'rconifers/DESCRIPTION' for reading
> 
> E:\conifers>
> 
> I still don't understand why the cygwin tool is required. I'm just a mere 
> simpleton and haven't spent the time required to become king-fu master with 
> this particular minutiae. Could the script that builds the package be fixed? 
> Is it broken? If it's not broken, what's with the cygdrive stuff? why does 
> the entire path need to be there?
> 
> Is the tar that's in the tools.zip from 
> http://www.murdoch-sutherland.com/Rtools/ any different than the one with 
> MSYS?

Yes, it is different and it works.

Simply don't use MSYS, but use the recommended tools.


Uwe Ligges



> 
> Jeff.
> 
> __
> R-devel@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] Acknowledgments in package documentation

2005-12-30 Thread Uwe Ligges
Jeff Enos wrote:

> R-devel,
> 
> I've received permission from a third party to incorporate some of
> their data in a data set in my 'portfolio' package.  I'd like to
> include an acknowledgment of the third party, and perhaps a "used with
> permission" somewhere in the package documentation.
> 
> Where's the best spot in the package docs for such an acknowledgment?
> Is there a place preferable to the \description or \source sections of
> the data set's .Rd file?

No, that's perfect.

If for the data a special license applies different from the rest of the 
package, document it in thge License field of DESCRIPTION. You may also 
mention the other "author" in the DESCRIPTION file. All details on the 
author should go into the corresponding Rd file.

Uwe Ligges

> Thanks in advance,
> 
> Jeff
> 
> __
> R-devel@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] Minumum memory requirements to run R.

2006-01-21 Thread Uwe Ligges
Liaw, Andy wrote:

> From: Kjetil Brinchmann Halvorsen
> 
>>Prof Brian Ripley wrote:
>>
>>>Quite a while back we set the goal of running R in 16Mb 
>>
>>RAM, as people (I 
>>
>>>think Kjetil) had teaching labs that small.
>>
>>It's a while since I actually har R used on such small 
>>machines, I think
>>64 MB is quite acceptable now.
>>
>>Kjetil
>>
>>
>>>Since then R has grown, and we has recently started to 
>>
>>optimize R for 
>>
>>>speed rather than size.  I recently tested R-devel on my 
>>
>>ancient Win98 
>>
>>>notebook with 64Mb RAM -- it ran but startup was rather 
>>
>>slow on what I 
>>
>>>think is a 233MHz processor and very slow disc.
>>>
>>>R still runs in 16Mb, but that is getting tight.  Does 
>>
>>anyone have any 
>>
>>>need to run on a smaller machine than my 64Mb notebook?
> 
> 
> I sure don't, but I wouldn't be surprised if one of these days someone
> figures out how to get R to run on a video card...  (I recall that there was
> a tutorial session at some datamining conference last year that showed
> people how to use the GPU for numerical computation, so this may not be too
> far fetched.)

If you want to run R on a videocard because of its enormous floating 
point speed, you have access to quite a lot of RAM (fast cards already 
have huge amounts of RAM). Well, my 20 EUR card has 32Mb only, but you 
certainly don't want to perform calculations on it... ;-)

Are there already PCIe cards that support fast writing to the main 
memory (not only fast reading)?

Uwe

> 
> Andy
> 
> __
> R-devel@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] an unpleasant interaction of environments and generic functions

2006-01-31 Thread Uwe Ligges
Ross Boylan wrote:

> I've run into an unpleasant oddity involving the interaction of
> environments and generic functions.  I want to check my diagnosis, and
> see if there is a good way to avoid the problem.
> 
> Problem:
> A library defines
> "foo" <- function(object) 1
> setMethod("foo", c("matrix"), function(object) 30)
> 
> After loading the library
> foo(0) is 1
> foo(matrix()) is 30
> foo is a generic
> 
> The source the file with the code given above.
> Now 
> foo(matrix()) is 1
> foo is a function
> (Also, there is no "creating generic function" message).
> 
> Diagnosis:
> The library creates foo and related generics in package:libname.
> The source for the initial definition puts the name and function
> definition in .GlobalEnv.
> The source'd setMethod finds the existing generic in package:libname and
> updates it (I'm not sure about this last step).
> foo then discovers the foo in .GlobalEnv, not the generic, so the
> generic and the alternate methods are hidden.
> 
> In case you're wondering, I found this out because I was experimenting
> with a library, changing the R and not the C code.  I get sick of doing
> R CMD INSTALL with each iteration, but needed to load the library to get
> the .so file.
> 
> So, is my diagnosis correct?
> 
> Any suggestions about how to avoid this problem?
> Maybe sys.source("file", 2)... Seems to work!


I'd suggest to dyn.load() the .so and source() the code during early 
development. So you do not need to R CMD INSTALL the _*package*_ into a 
library.

Uwe Ligges

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] Typos in ?regex

2017-12-29 Thread Uwe Ligges

Thanks, fixed in R-devel and R-patched.

Best,
Uwe Ligges


On 22.12.2017 15:28, Korpela Mikko (MML) wrote:

I found three little typos in the ?regex manual. Apologies for the lack of a 
diff, as the utility is not (yet) installed on this machine.

1. "There is a also" should probably be "There is also".
2. In the list of functions following "This section covers the regular expressions"..., 
"grep" appears twice. The other one should probably be "grepl".
3. In the "See Also" entry for TRE documentation, there is a spurious closing 
parenthesis.

- Mikko



__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] R CMD check warning about compiler warning flags

2018-01-03 Thread Uwe Ligges



On 26.12.2017 00:45, Juan Telleria wrote:

However, and hope not to be off-topic, a git repository (github, gitlab,
codeplex, etc., not just solely github) could constitute a tidy approach,
and make things easier to R Core :)

By putting the focus on version control, the line of changes made with each
commit (With the possibility to reverse changes), and not verbose e-mails.


That works well with svn, and we have the sequential labels which are 
e.g. important for bisecting changes.

I do not see how I can find this out with git easily.

Best,
Uwe Ligges




Juan

I strongly disagree. Are you aware that github is a commercial

company, github inc. [1] ?
What about gitlab? or Microsoft's codeplex? There are other services
similar to github, why github?
What happens if github goes out of business?

R-project should be maintained in the academic network and under
auspices of universities.


  [*]  GitHub, Inc.
https://en.wikipedia.org/wiki/GitHub






[[alternative HTML version deleted]]

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel



__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] bugzilla issues

2018-01-26 Thread Uwe Ligges

Simon,

can you take a look, please?

Best,
Uwe



On 26.01.2018 01:41, Ben Bolker wrote:


  tl;dr is the R bug tracker down or am I being an idiot? Help please ...


  I decided I would follow up on

https://stat.ethz.ch/pipermail/r-devel/2018-January/075410.html

(reporting/suggesting a patch for an issue in stats::mantelhaen.test()
with large data sets)

   Reading the instructions at https://www.r-project.org/bugs.html
suggests that if I'm sure I have found something worthy of posting to
the R bug tracker, I should go to https://bugs.r-project.org/bugzilla3

This results in


Software error:

Can't locate Email/Sender/Simple.pm in @INC (you may need to install the
Email::Sender::Simple module) (@INC contains: .
lib/x86_64-linux-gnu-thread-multi lib /etc/perl
/usr/local/lib/x86_64-linux-gnu/perl/5.24.1 /usr/local/share/perl/5.24.1
/usr/lib/x86_64-linux-gnu/perl5/5.24 /usr/share/perl5
/usr/lib/x86_64-linux-gnu/perl/5.24 /usr/share/perl/5.24
/usr/local/lib/site_perl /usr/lib/x86_64-linux-gnu/perl-base) at
Bugzilla/Mailer.pm line 26.
BEGIN failed--compilation aborted at Bugzilla/Mailer.pm line 26.
Compilation failed in require at Bugzilla/Auth.pm line 22.
BEGIN failed--compilation aborted at Bugzilla/Auth.pm line 22.
Compilation failed in require at Bugzilla.pm line 23.
BEGIN failed--compilation aborted at Bugzilla.pm line 23.
Compilation failed in require at /var/lib/bugzilla4/index.cgi line 15.
BEGIN failed--compilation aborted at /var/lib/bugzilla4/index.cgi line 15.

For help, please send mail to the webmaster (ad...@rforge.net), giving
this error message and the time and date of the error.
===

e-mailing ad...@rforge.net bounces with

This is the mail system at host hagal.urbanek.info.

I'm sorry to have to inform you that your message could not
be delivered to one or more recipients. It's attached below.

For further assistance, please send mail to postmaster.

If you do so, please include this problem report. You can
delete your own text from the attached returned message.

The mail system

: User unknown in virtual alias table
=

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel



__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] CRAN indices out of whack (for at least macOS)

2018-01-31 Thread Uwe Ligges

Thanks,
Uwe


On 31.01.2018 20:08, Simon Urbanek wrote:

Dirk,

yes, thanks, the edge server that serves the Mac binaries to CRAN has run out 
of disk space (due to size of CRAN itself) so the sync was incomplete.
It is fixed now -- you can try by using the macos master server as mirror: 
https://r.research.att.com/ and it will propagate through other mirrors as 
usual.

Thanks,
Simon





On Jan 31, 2018, at 1:34 PM, Dirk Eddelbuettel  wrote:


Bumping this as we now have two more issue tickets filed and a fresh SO
question.

Is anybody looking at this? Simon?

Dirk

On 30 January 2018 at 15:19, Dirk Eddelbuettel wrote:
|
| I have received three distinct (non-)bug reports where someone claimed a
| recent package of mine was broken ... simply because the macOS binary was not
| there.
|
| Is there something wrong with the cronjob providing the indices? Why is it
| pointing people to binaries that do not exist?
|
| Concretely, file
|
|   https://cloud.r-project.org/bin/macosx/el-capitan/contrib/3.4/PACKAGES
|
| contains
|
|   Package: digest
|   Version: 0.6.15
|   Title: Create Compact Hash Digests of R Objects
|   Depends: R (>= 2.4.1)
|   Suggests: knitr, rmarkdown
|   Built: R 3.4.3; x86_64-apple-darwin15.6.0; 2018-01-29 05:21:06 UTC; unix
|   Archs: digest.so.dSYM
|
| yet the _same directory_ only has:
|
|   digest_0.6.14.tgz   15-Jan-2018 21:36   157K
|
| I presume this is a temporary accident.
|
| We are all spoiled by you all providing such a wonderfully robust and
| well-oiled service---so again big THANKS for that--but today something is out
| of order.
|
| Dirk
|
| --
| http://dirk.eddelbuettel.com | @eddelbuettel | e...@debian.org
|
| __
| R-devel@r-project.org mailing list
| https://stat.ethz.ch/mailman/listinfo/r-devel

--
http://dirk.eddelbuettel.com | @eddelbuettel | e...@debian.org



__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel



__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


[Rd] CRAN incoming services and winbuilder down Mar 9-10

2018-03-08 Thread Uwe Ligges

Dear list,

due to a full power shutdown in the relevant building at TU Dortmund 
University we have to shut down winbuilder and the CRAN incoming check 
service from

Mar 9, 5pm CET
to
Mar 10, 5pm CET

Best,
Uwe Ligges
(CRAN team)

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] Base R examples that write to current working directory

2018-03-30 Thread Uwe Ligges



On 30.03.2018 00:08, Duncan Murdoch wrote:

On 29/03/2018 5:23 PM, Hadley Wickham wrote:

Hi all,

Given the recent CRAN push to prevent examples writing to the working
directory, is there any interest in fixing base R examples that write
to the working directory? A few candidates are the graphics devices,
file.create(), writeBin(), writeChar(), write(), and saveRDS(). I'm
sure there are many more.

One way to catch these naughty examples would be to search for
unlink() in examples: e.g.,
https://github.com/wch/r-source/search?utf8=✓&q=unlink+extension%3ARd&type=. 


Of course, simply cleaning up after yourself is not sufficient because
if those files existed before the examples were run, the examples will
destroy them.



Why not put together a patch that fixes these?  This doesn't seem to be 
something that needs discussion, fixing the bad examples would be a good 
idea.


Seconded. CRAN would not accept these base packages, hence we should 
urgently give better examples.


Best,
Uwe



Duncan Murdoch

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] Library lib.loc Option Ignored for Dependencies

2018-07-25 Thread Uwe Ligges




On 24.07.2018 23:37, Benjamin Tyner wrote:



On 07/24/2018 07:50 AM, Martin Maechler wrote:

Benjamin Tyner
 on Sat, 21 Jul 2018 13:42:43 -0400 writes:

 > Not sure whether it is the same issue as was raised here:
 > https://stat.ethz.ch/pipermail/r-devel/2010-October/058729.html

 > but in any case perhaps the problem could partially be remedied 
on line

 > 245 of src/library/base/R/library.R by passing the lib.loc to
 > .getRequiredPackages2() ...here is a patch (untested)

 > Index: src/library/base/R/library.R
 > 
===

 > --- src/library/base/R/library.R    (revision 74997)
 > +++ src/library/base/R/library.R    (working copy)
 > @@ -242,7 +242,7 @@
 >  pos <- 2
 >  } else pos <- npos
 >  }
 > -    .getRequiredPackages2(pkgInfo, quietly = quietly)
 > +    .getRequiredPackages2(pkgInfo, lib.loc = lib.loc, 
quietly = quietly)

 >  deps <- unique(names(pkgInfo$Depends))

 >  ## If the namespace mechanism is available and the 
package


This - directly - fails even more miserably e.g. in my own setup
when I have dependency to my package.

But it seems a good idea to use 'lib.loc', and safer and
probably better than the current code maybe to use

   .getRequiredPackages2(pkgInfo,
    lib.loc = c(lib.loc, .libPaths()),
    quietly = quietly)

instead of the current code which uses lib.loc = NULL
equivalently to   lib.loc = .libPaths()

Seems reasonable to me.


Others / ideas?
Reproducible examples with small fake packages?
Or how about an example with a "real" CRAN package with just one 
dependency:


     > dir.create("~/lib")
     > list.files("~/lib")
     character(0)
     > install.packages("spam", lib = "~/lib", dependencies = TRUE)
     > list.files("~/lib")
     [1] "dotCall64" "spam"
     > library(spam, lib.loc = "~/lib")
     Error: package ‘dotCall64’ required by ‘spam’ could not be found



Not sure if this is a bug: where is it documented that this works not as 
above (which is what I would expect)?


For development puposes, you may want to try some devekopment version of 
one package agaiunst release versions of the others.
This is the purpose of the above: take spam from ~lib and the other from 
.libPath().


Best,
Uwe Ligges




Martin

 > On 07/21/2018 12:34 PM, Martin Maechler wrote:
 >>>>>>> Benjamin Tyner
 >>>>>>> on Fri, 20 Jul 2018 19:42:09 -0400 writes:
 >> > Here's a trick/workaround; if lib.loc is the path to your
 >> > library, then prior to calling library(),
 >>
 >> >> environment(.libPaths)$.lib.loc <- lib.loc
 >>
 >> Well, that is quite a "trick"  -- and potentially a pretty
 >> dangerous one, not intended when making .libPaths a closure 
 >>
 >>
 >> I do think that there is a problem with R's dealing of R_LIBS
 >> and other libPaths settings, notably when checking packages and
 >> within that recompiling vignettes etc, where the R process
 >> starts new versions of R via system() / system2() and then gets
 >> to wrong .libPaths() settings,
 >> and I personally would be very happy if we got reprex'es with
 >> small fake packages -- possibly only easily reproducible on
 >> unix-alikes ... so we could address this as a bug (or more than
 >> one) to be fixed.
 >>
 >> Notably with the 3.4.x --> 3.5.0 transition and my/our tendency
 >> of having quite a few paths in R_LIBS / lib.loc / ... I've been
 >> bitten by problems when the wrong version of package was taken
 >> from the wrong library path 
 >>
 >> Martin
 >>
 >>
 >> >> 


 >> >> Good day,
 >> >>
 >> >> If there's a library folder of the latest R packages and
 >> >> a particular package from it is loaded using the lib.loc
 >> >> option, the dependencies of that package are still
 >> >> attempted to be loaded from another folder of older
 >> >> packages specified by R_LIBS, which may cause errors
 >> >> about version requirements not being met. The
 >> >> documentation of the library function doesn't explain
 >> >> what the intended result is in such a case, but it could
 >> >> reasonably be expected that R would also load the
 >> >> dependencies from the user-specified lib.loc folder.
 >> >>
 >> >> --
 >> >> Dario Strbenac University of Sydney Camperdown NSW 2050
 >> >> Australia


__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] Library lib.loc Option Ignored for Dependencies

2018-07-25 Thread Uwe Ligges




On 25.07.2018 04:00, Dario Strbenac wrote:

Good day,

A self-contained example which reproduces the problem is

packagesFolder <- tempdir()
latestFolder <- file.path(packagesFolder, "latest")
dir.create(latestFolder)

devtools::create(file.path(latestFolder, "statistics"), description = list(Version = 
"1.1.0", Depends = "extras (>= 1.0.5)"))
devtools::create(file.path(packagesFolder, "extras"), description = list(Version = 
"1.0.0"))
devtools::create(file.path(latestFolder, "extras"), description = list(Version = 
"1.1.0"))

latestInstall <- file.path(.libPaths()[1], "latest")
dir.create(latestInstall)
install.packages(file.path(packagesFolder, "extras"), type = "source", repos = 
NULL)
install.packages(file.path(latestFolder, "extras"), type = "source", repos = 
NULL, lib = latestInstall)
install.packages(file.path(latestFolder, "statistics"), type = "source", repos 
= NULL, lib = latestInstall)


library(statistics, lib.loc = latestInstall)

   Error: package ‘extras’ 1.0.0 was found, but >= 1.0.5 is required by 
‘statistics’

The latest version of the statistics package is loaded, but the directory of 
latest packages is ignored by R when it considers the package dependency.


See my other mail, I think this is epctected, why don't youi set the 
.libPaths() correctly?


Nor is this self contained as we need some extra package  to try your 
example...


Best,
Uwe Ligges



--
Dario Strbenac
University of Sydney
Camperdown NSW 2050
Australia
__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel



__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


[Rd] CRAN incoming queue closed from Sep 1 to Sep 9

2018-08-14 Thread Uwe Ligges

Dear developers,

the CRAN incoming queue will be closed from Sep 1 to Sep 9. Hence 
package submissions are only possible before and after that period.


Best,
Uwe Ligges
(for the CRAN team)

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


[Rd] CRAN incoming queue closed from Dec 21 to Jan 02

2018-12-17 Thread Uwe Ligges

Dear package developers,

the CRAN incoming queue will be closed from Dec 21, 2018 to Jan 02, 
2019. Hence package submissions are only possible before and after that 
period.


Best,
Uwe Ligges
(for the CRAN team)

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


[Rd] CRAN incoming queue closed from Aug 09 to Aug 18

2019-08-05 Thread Uwe Ligges

Dear package developers,

the CRAN incoming queue will be closed from Aug 09, 2019 to Aug 18, 
2019. Hence package submissions are only possible before and after that

period.

CRAN maintainance work and some work on a possibly forthcoming Windows 
toolchain will be pushed forward.


Best,
Uwe Ligges
(for the CRAN team)

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] CHM help does not find help docs in package stats

2010-06-18 Thread Uwe Ligges



On 17.06.2010 09:19, Thaler,Thorn,LAUSANNE,Applied Mathematics wrote:

Indeed, the R version is 2.9.2. But the package was built on the very
same system. Besides, another package built with the same version of R
but on another machine does not show this nasty behavior. Upgrading,
however, could pose more problems as it solves, since even if I could
upgrade locally, it would be a mess to assure that all colleagues
upgrade as well.

Anyways, even if the chm format is not supported any more by current
versions of R, it should work with older ones, right? So, what can I do
additionally to get to the bottom of this problem?




During the last years, Mircosoft "patched" parts of the chm system by 
disallowing different features by default. It may see some result of 
these patches. Anyway, hard to say what is going on without seeing your 
binary package, your system setup, the libraries where you have 
installed you package and the otehrs, knowing if these are network paths 
or local storage, .....


Uwe Ligges



Thanks + BR,

Thorn

-Original Message-----
From: Uwe Ligges [mailto:lig...@statistik.tu-dortmund.de]
Sent: samedi 12 juin 2010 18:21
To: Thaler,Thorn,LAUSANNE,Applied Mathematics
Cc: r-devel@r-project.org
Subject: Re: [Rd] CHM help does not find help docs in package stats

Which version of R is this?
CHM help is R<  2.10.0. All versions thereafter do not support compiled
html help anymore.

Please upgrade your version of R and try one of the currently supported
help formats.

Best wishes,
Uwe Ligges



On 11.06.2010 12:06, Thaler, Thorn, LAUSANNE, Applied Mathematics wrote:

Hi all,

currently I'm working on an R package bundling some frequently used
functions. When I load my package and type

?one_of_my_functions

I get the particular help file. If I try to get help on another
function, which is part of package stats (prcomp say), I get "This
program cannot display the webpage". A help on ?mean does, however,

work

as it opens a new window showing the help on mean.

There is another peculiarity, if it happens that I requested a help

file

for a function in the package stats before I used the help on one of

my

functions, everything works out fine.

Does anybody know how I can get rid of this annoying behavior? It has

to

have something to do with my particular package, since everything

works

as expected with another package of mine.

I override one of the functions of stats (biplot.default), which is,
however, not exported and resides within my namespace. Could that be

the

reason?

Any help highly appreciated. Thanks + BR,

Thorn

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] format: different S4 behavior in a package

2010-06-23 Thread Uwe Ligges

There is not a single definition of
formatMe()
in your message, therefore nothing works for me, not even the very first 
version...


Best,
Uwe Ligges


On 23.06.2010 09:16, Daniel Murphy wrote:

R-Devel-ers:

I have an S4 method that simply formats an object:

setGeneric("formatMe", function(x) standardGeneric("formatMe"))
setMethod("formatMe", "ANY", function(x) format(x))

If I issue the above in an R session, then define an S4 class with its own
format method, I get the desired result:


setClass("A",contains="numeric")

[1] "A"

setMethod("format","A", function(x, ...) "Hey Jude")

Creating a new generic function for "format" in ".GlobalEnv"
[1] "format"

a<-new("A",1968)
formatMe(a)

[1] "Hey Jude"


However, if I put the two "formatMe" definitions into a package ("Test"), I
do not get the desired result.



library(Test)
setClass("A",contains="numeric")

[1] "A"

setMethod("format","A", function(x, ...) "Hey Jude")

Creating a new generic function for "format" in ".GlobalEnv"
[1] "format"

a<-new("A",1968)
formatMe(a)

[1] "1968"


The "disconnect" does not occur, however, if the S4 format method is an S3
incarnation:


setClass("B",contains="numeric",S3methods=TRUE)

[1] "B"

format.B<- function(x, ...) "Don't make it bad"
b<-new("B",1968)
formatMe(b)

[1] "Don't make it bad"

Could the problem be in Test's NAMESPACE file? There is only one line:
exportMethods(formatMe)

Here is Test's DESCRIPTION file:
Package: Test
Type: Package
Title: Testing format
Version: 1.0
Date: 2010-06-22
Author: Dan Murphy
Maintainer: Dan Murphy
Depends: methods
Description: Does format in a package work with S4 format method?
License: GPL (>= 2)
LazyLoad: yes

(I would send the Help file, but I don't think that is the problem.)

I am using version 2.11.1 on a Windows Vista machine.

Any guidance would be appreciated. Thank you

Dan Murphy

[[alternative HTML version deleted]]

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] Problem with dyn.load() under Windows 64bit at CRAN

2010-06-30 Thread Uwe Ligges

Dominick,

your messages are all in my Inbox, I just have not yet found the time to 
look in more detail.


On 30.06.2010 15:44, Dominick Samperi wrote:

The package cxxPack builds without problems at CRAN under all OS's except
Windows 64bit, and in the case of Windows 64bit there is a problem in a
call to dyn.load(). This call happens while processing the package vignette,
and the odd thing about this is that there are several calls to dyn.load()
that
work fine before the one that fails.



That highly improbable.


This seems to suggest that Windows 64bit is imposing some kind of
resource constraint that limits the number of shared libs that can be
loaded at one time.

Another odd thing about this is that everything worked under Windows 64bit
before the changes were made to serialize the build of packages that
depend on each other.


That's untrue. I try to serialize some things on winbuilder.


Any ideas?


No yet.

It is not very helpful to speculate and post a modification of some of 
your and my modified guesses.


Best,
Uwe





Thanks,
Dominick

[[alternative HTML version deleted]]

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] Problem with dyn.load() under Windows 64bit at CRAN

2010-07-02 Thread Uwe Ligges

On 02.07.2010 16:10, Dominick Samperi wrote:

2010/6/30 Uwe Ligges


On 30.06.2010 15:44, Dominick Samperi wrote:

Another odd thing about this is that everything worked under Windows 64bit

before the changes were made to serialize the build of packages that
depend on each other.


  That's untrue. I try to serialize some things on winbuilder.



There was a problem building packages that depended on Rcpp due to the
parallel build process used at CRAN (and a bug in GNU make).



Well, sometimes, *not* always.
And *only* for Windows, it was fine on other platforms.



The CRAN
build process was changed (by serializing dependent packages) to fix this
problem.


*No*! It was *not* changed, as I already told you in my last reply on 
the list. I aimed at and still have not found the time. And again, only 
Windows.


I fear you do not understand what I meant: I am just stopping to build 
some packages in parallel. Other stuff is not affected, hence nothing 
you or this list need to worry about.
I should not have told you, as I understand now. I just tried to give 
you an explanation why your packages failed twice in the past due to bad 
luck.
I just should keep quite in future and answer with a simple "no idea" 
given all the information and even internal guesses are reported in a 
different context and used for list-wide speculation in the end.





The package cxxPack built fine under Windows 64bit before this
change was implemented. Now it fails.


No, that's not the reason: the change has not yet been implemented.



Today the build of cxxPack fails under most of the OS's, and it appears that
the problem is due to a new release of Rcpp.

Perhaps the idea of wrapping libs inside packages simply does not work,
at least not without extra support and attention from the CRAN team.



Why should the CRAN team care about it?

Really, given my lack of time and your annoying posts to the lists 
containing misleading information, I probably should stop to care about 
your package at all. There are > 2000 other packages and some more 
important tasks to tackle. Consider the CRAN team would take so much 
time for each single package ...


Uwe



One possible resolution would be to incorporate whatever I need from Rcpp
into cxxPack to eliminate the package dependency.

>

Thanks,
Dominick



__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] CRAN updates?

2010-07-29 Thread Uwe Ligges



On 27.07.2010 22:15, Simon Urbanek wrote:


On Jul 27, 2010, at 9:56 AM, Dominick Samperi wrote:


It appears that after a package is updated the CRAN binaries for some OS's
are built
automatically and shortly after the update, while other OS's are not updated
for
some time (weeks in some cases).

Is the process automated or is it partially manual for some OS's (like
Windows/w64
and Mac OS X)?



It is automated on Mac OS X (currently R builds start at midnight and package 
builds at 2am ET).



... as well as automated under all flavours for/of Windows.

Uwe




Cheers,
Simon

PS: If you see delays (i.e. the check result is not available more than two 
days after the package is available on CRAN) it's a good idea to contact the 
corresponding binary maintainer (for OS X it's me) since things can break 
(packages can run mad and external servers can die).

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] R CMD check - "there is no package called"

2010-07-29 Thread Uwe Ligges



On 26.07.2010 02:00, Simon Urbanek wrote:


On Jul 24, 2010, at 9:02 AM, John Hendrickx wrote:


I'm trying to update my "perturb" package to get rid of some small warning
messages. The examples in "perturb" use the "Duncan" dataset from the "car"
package and I have "car" installed in R. But when I run "R CMD check", I get an
error message



require("car")

Loading required package: car
Warning in library(package, lib.loc = lib.loc, character.only = TRUE,
logical.return = TRUE,  :
  there is no package called 'car'

data(Duncan)

Warning in data(Duncan) : data set 'Duncan' not found

This is very strange, the example works fine if I just run it in R. This is the
example from the perturb.rd file:

  \examples{
require("car")
data(Duncan)
attach(Duncan)
m1<-lm(prestige~income+education)
...

I'm using R 2.11.1 under Ubuntu 10.04. Perhaps the problem is related to the
packages being installed in my home directory. I've create an ~/.Renviron file
with

R_LIBS_USER="/home/john/lib/R/library"

I've also tried creating an environment variable "export
R_LIBRARY_DIR=/home/john/lib/R/library/" before running R CMD check.


The correct name is R_LIBS



... and from "Writing R Extensions":

Note: R CMD check and R CMD build run R with '--vanilla', so none of the 
user's startup files are read. If you need R_LIBS set (to find packages 
in a non-standard library) you will need to set it in the environment.


Uwe





Cheers,
Simon



That made
no difference. Can anyone point me in the right direction? Do I have to install
packages in R_HOME?




[[alternative HTML version deleted]]

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel




__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] Telling R CMD check where to find libraries

2010-07-29 Thread Uwe Ligges



On 20.07.2010 17:18, Thaler, Thorn, LAUSANNE, Applied Mathematics wrote:

Hello everybody,

Currently I'm developing a library, which uses some functions from
another package (namely plotrix). Consequently, I listed this dependency
in the DESCRIPTION file. When I try to run "R CMD check mypackage", the
check fails, for the library plotrix cannot be found on the system. As
far as I understood "R CMD check" uses --vanilla implicitly, thus, no
startup files are read. Hence, plotrix cannot be found by "R CMD check",
since it is only installed locally (I've no admin privileges on this
machine) and the path to the library is given in .Rprofile, which in
turn is not read by "R CMD check".

If I provide the flag "-l /path/to/site/libs", it works as expected but
with the side effect that the test installation is carried out in this
directory as well, which I do not like either (this directory should
contain only stable packages and not packages which are still under
construction). So which possibilities do I have?



Set the environment variable  R_LIBS  to point to that library.

Uwe Ligges



BR

Thorn

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] [R] Problems building own package (Error: "package has been build before R-2.10.0")

2010-08-17 Thread Uwe Ligges



On 17.08.2010 20:36, Janko Thyson wrote:

Dear List,



I’m doing my first baby steps towards developing own R Packages and ran into
the following problem:


First baby step: Do not cross-post on several lists.




R CMD check mypackage works fine (no errors, no warnings)

R CMD build mypackage works fine (no errors, no warnings)

R CMD INSTALL –library=”C:\R\R-2.11.1\library”
“something\mypackage\mypackage_1.0.tar.gz” works fine (no errors, no
warnings)



However, when I try loading the package in an R-Session (version 2.11.1) via
“library(mypackage)”, R complains about the package being build before
version R-2.10.0 and tells me to rebuild it.



So the R that is in your PATH is  < 2.10.x
Change your PATH and add the R version your are actually working with....

Uwe Ligges






Could this possibly be due to the fact that I have multiple R versions
installed (this also includes the most recent one, though)?



To provide you with some details:

-  Running Windows XP

-  All of my R versions are under “C:\R” (versions 2.9.2, 2.10.1,
2.11.1).

-  I installed Rtools (version 2.1.2) to “C:\Rtools” and pointed it
to “C:\R” (as this was the default) to interact with R (should this maybe
have been “C:\R\R-2.11.1”?). I also installed everything else necessary to
build packages (Inno Setup etc.).

-  My PATH is set up as explained in R-Admin manual. Also, the only
R version stated there is “C:\R\R-2.11.1\bin;”.

-  I updated the DESCRIPTION file and specified all .Rd files
correctly.



Any idea what I’m doing wrong?



Thanks a ton,

Janko



   _



Janko Thyson
  <mailto:holger.ko...@ku-eichstaett.de>  janko.thy...@ku-eichstaett.de

Catholic University of Eichstätt-Ingolstadt
Ingolstadt School of Management
Statistics and Quantitative Methods
Auf der Schanz 49
D-85049 Ingolstadt

  <http://www.wfi.edu/lsqm>  www.wfi.edu/lsqm

Fon:  +49 841 937-1923
Fax:  +49 841 937-1965

This e-mail and any attachment is for authorized use by the intended
recipient(s) only. It may contain proprietary material, confidential
information and/or be subject to legal privilege. It should not be
copied, disclosed to, retained or used by any other party.
If you are not an intended recipient then please promptly delete this
e-mail and any attachment and all copies and inform the sender.



   _




[[alternative HTML version deleted]]




__
r-h...@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.


__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] [R] Problems building own package (Error: "package has been build before R-2.10.0")

2010-08-17 Thread Uwe Ligges
Then, you have the package installed under another libarry that is first 
on your search path.


Uwe Ligges

On 17.08.2010 22:07, Janko Thyson wrote:

-Ursprüngliche Nachricht-
Von: Uwe Ligges [mailto:lig...@statistik.tu-dortmund.de]
Gesendet: Dienstag, 17. August 2010 22:00
An: Janko Thyson
Cc: r-de...@r-project. org
Betreff: Re: [R] Problems building own package (Error: "package has
been build before R-2.10.0")



On 17.08.2010 20:36, Janko Thyson wrote:

Dear List,



I’m doing my first baby steps towards developing own R Packages and

ran into

the following problem:


First baby step: Do not cross-post on several lists.


Sorry.


R CMD check mypackage works fine (no errors, no warnings)

R CMD build mypackage works fine (no errors, no warnings)

R CMD INSTALL –library=”C:\R\R-2.11.1\library”
“something\mypackage\mypackage_1.0.tar.gz” works fine (no errors, no
warnings)



However, when I try loading the package in an R-Session (version

2.11.1) via

“library(mypackage)”, R complains about the package being build

before

version R-2.10.0 and tells me to rebuild it.



So the R that is in your PATH is<  2.10.x
Change your PATH and add the R version your are actually working
with


As I wrote: "My PATH is set up as explained in the R-Admin manual. Also, the
only R version stated there is “C:\R\R-2.11.1\bin;”.


Uwe Ligges





Could this possibly be due to the fact that I have multiple R

versions

installed (this also includes the most recent one, though)?



To provide you with some details:

-  Running Windows XP

-  All of my R versions are under “C:\R” (versions 2.9.2,

2.10.1,

2.11.1).

-  I installed Rtools (version 2.1.2) to “C:\Rtools” and

pointed it

to “C:\R” (as this was the default) to interact with R (should this

maybe

have been “C:\R\R-2.11.1”?). I also installed everything else

necessary to

build packages (Inno Setup etc.).

-  My PATH is set up as explained in R-Admin manual. Also,

the only

R version stated there is “C:\R\R-2.11.1\bin;”.

-  I updated the DESCRIPTION file and specified all .Rd files
correctly.



Any idea what I’m doing wrong?



Thanks a ton,

Janko



_



Janko Thyson
   <mailto:holger.ko...@ku-eichstaett.de>   janko.thy...@ku-

eichstaett.de


Catholic University of Eichstätt-Ingolstadt
Ingolstadt School of Management
Statistics and Quantitative Methods
Auf der Schanz 49
D-85049 Ingolstadt

   <http://www.wfi.edu/lsqm>   www.wfi.edu/lsqm

Fon:  +49 841 937-1923
Fax:  +49 841 937-1965

This e-mail and any attachment is for authorized use by the intended
recipient(s) only. It may contain proprietary material, confidential
information and/or be subject to legal privilege. It should not be
copied, disclosed to, retained or used by any other party.
If you are not an intended recipient then please promptly delete this
e-mail and any attachment and all copies and inform the sender.



_




[[alternative HTML version deleted]]




__
r-h...@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-

guide.html

and provide commented, minimal, self-contained, reproducible code.




__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


[Rd] winbuilder offline / CRAN windows binaries

2010-09-06 Thread Uwe Ligges

Dear all,

the winbuilder service as well as the build system for new / updated 
CRAN windows binaries will be offline for a day or two. I hope to get it 
online as soon as possible.


Best wishes,
Uwe Ligges

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] winbuilder offline / CRAN windows binaries

2010-09-06 Thread Uwe Ligges



On 06.09.2010 20:04, Uwe Ligges wrote:

Dear all,

the winbuilder service as well as the build system for new / updated
CRAN windows binaries will be offline for a day or two. I hope to get it
online as soon as possible.


 which could be reduced to 30 minutes. :-)

Uwe




Best wishes,
Uwe Ligges

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] R forge : svn + ssh without key

2010-09-13 Thread Uwe Ligges
Works for me, I guess you do not have an appropriate ssh connected to 
your svn client.

Perhaps better ask such questions on the R-forge platform?

Best,
Uwe Ligges


On 24.08.2010 15:56, christophe.genolini wrote:


Hi the list,

I am trying to use R forge. I created an account. I put my project on R
forge. I installed TortoiseSVN on my computer (windows).

Then I did not manage to go through all the key process but I see in the
R-Forge Manual that there is another option:
"2. it is sufficient to use password authentication to write to the
project repository (if you decided to do so please go to step 5)."
So I try this new (for me) way. I create a folder on my computer. I
successfully manage to update my local repository. But I do not manage
to do a commit. Each time, I get the message

Commit fail (details follow):
authorization failed

Any idea of what goes wrong?

Christophe

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] value returned by by()

2010-09-14 Thread Uwe Ligges

It returns a list with athe class attribut set to "by", just use:

x <- by(.)
unclass(x)


Uwe Ligges


On 14.09.2010 00:11, Seb wrote:

Hi,

I noticed that by() returns an object of class 'by', regardless of what
its argument 'simplify' is.  ?by says that it always returns a list if
simplify=FALSE, yet by.data.frame shows:

---<cut here---start--->---
function (data, INDICES, FUN, ..., simplify = TRUE)
{
 if (!is.list(INDICES)) {
 IND<- vector("list", 1L)
 IND[[1L]]<- INDICES
 names(IND)<- deparse(substitute(INDICES))[1L]
 }
 else IND<- INDICES
 FUNx<- function(x) FUN(data[x, , drop = FALSE], ...)
 nd<- nrow(data)
 ans<- eval(substitute(tapply(1L:nd, IND, FUNx, simplify = simplify)),
 data)
 attr(ans, "call")<- match.call()
 class(ans)<- "by"
 ans
}

---<cut here---end->---

One could force a list by wrapping it around an lapply(by.object, "["),
but this is not possible if the object contains S4 objects.  How does
one force a list in those cases?


Cheers,



__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] More strange R CMD build/check errors on Windows

2010-09-14 Thread Uwe Ligges



On 12.09.2010 12:10, Hervé Pagès wrote:

Hi Peter,

On 09/12/2010 01:51 AM, Peter Dalgaard wrote:

On 09/12/2010 08:10 AM, Hervé Pagès wrote:
...


AFAICT those problems were never seen before (i.e. with R< 2.12).
They show up randomly everyday for a small number of packages
(between 10 and 20 out of 400). The set of victims changes everyday
and any package seems to be a potential victim (I've not been able
to observe any obvious pattern so far).
Does anyone have any idea what could make 'R CMD build' and
'R CMD check' so confused/unreliable on Windows?



Brian had some ideas that the problems are related to the shell that is 
used. Is the problem still apparent in a very recent R-devel from few 
days ago? I am just back from vacations and have not updated yet.
I experienced the same problems and I am just iterating automatically if 
typical problems are apparent from the log files. I hope some if not all 
parts are solved now and will do some new test runs shortly.


Best,
Uwe







Thanks,
H.



Antivirus software? I suspect you already ruled that out, but it has
been the culprit for problems with mysteriously disappearing
intermediate files in several cases, so I thought I'd mention it.



Actually I didn't try that yet because we still build BioC release
(using R-2.11.1) on these 2 Windows boxes and we don't see any of
those problems for the release builds. But I will. Could it be that
the fact that 'R CMD build' and 'R CMD check' are R-based in R-2.12
(and not Perl-based anymore) make them more fragile when something
like an antivirus is messing around with the filesystem?

Thanks for the suggestion,
H.



__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] value returned by by()

2010-09-15 Thread Uwe Ligges



On 14.09.2010 20:50, Seb wrote:

On Tue, 14 Sep 2010 12:02:04 +0200,
Uwe Ligges  wrote:


It returns a list with athe class attribut set to "by", just use: x<-
by(.)  unclass(x)


Thanks Uwe, however, that still returns an array when using the
data.frame method for by():

R>  class(unclass(with(warpbreaks, by(warpbreaks[, 1:2], tension, summary
[1] "array"

It seems as if the only way to really ensure a list:

R>  class(lapply(unclass(with(warpbreaks, by(warpbreaks[, 1:2], tension, 
summary))), function(x) x))
[1] "list"

but it seems like a waste to call another function just to do this.




Then you could still do

x <- by(.)
attributes(x) <- NULL

Uwe

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] S3 method for package listed in suggest/enhance

2010-09-15 Thread Uwe Ligges



On 01.09.2010 17:38, Hadley Wickham wrote:

Hi all,

The profr package provides a method for displaying its output with
ggplot: ggplot.print.  You don't need this ggplot2 to use profr, so
ggplot2 is listed under enhances in the DESCRIPTION file.

If I have just S3method(ggplot, profr) in my NAMESPACE, then I get:

** testing if installed package can be loaded
Error : object 'ggplot' not found whilst loading namespace 'profr'
ERROR: loading failed

If I have both S3method(ggplot, profr) and importFrom(ggplot2,
ggplot), then I get:

* checking package dependencies ... ERROR
Namespace dependency not required: ggplot2

What's the correct way of exporting an S3 method for a generic in a
suggested package?



I think you need to declare it as a Depends, since it has to be 
available for getting the Namespace directives right.


Uwe



Thanks,

Hadley





__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] value returned by by()

2010-09-15 Thread Uwe Ligges



On 15.09.2010 15:00, Seb wrote:

On Wed, 15 Sep 2010 11:29:23 +0200,
peter dalgaard  wrote:


On Sep 15, 2010, at 10:55 , Uwe Ligges wrote:





On 14.09.2010 20:50, Seb wrote:

On Tue, 14 Sep 2010 12:02:04 +0200,
Uwe Ligges   wrote:


It returns a list with athe class attribut set to "by", just use: x<-
by(.)  unclass(x)


Thanks Uwe, however, that still returns an array when using the
data.frame method for by():

R>   class(unclass(with(warpbreaks, by(warpbreaks[, 1:2], tension, summary
[1] "array"

It seems as if the only way to really ensure a list:

R>   class(lapply(unclass(with(warpbreaks, by(warpbreaks[, 1:2], tension, 
summary))), function(x) x))
[1] "list"

but it seems like a waste to call another function just to do this.




Then you could still do

x<- by(.)
attributes(x)<- NULL




Or just use c() instead of unclass(). (The root cause is that even with 
simplify=FALSE, tapply() will always create an array, in this case a 1d array 
with dim=3. The _contents_ of the array will be a list, though.)



Notice that in the relevant cases, what you get really _is_ a list, and both 
walks and quacks like one.  E.g.



L<- with(warpbreaks, by(warpbreaks[, 1], tension, mean, simplify=FALSE))
is.list(L)

[1] TRUE

L$M

[1] 26.38889


But if one tries to include this list dressed in 'by' clothes into an S4
class slot declared as a list, then we have problems.  In that case, I
propose this simple patch to by.Rd, which simply removes the statement
about the result being *always* a list.


Index: by.Rd
===
--- by.Rd   (revision 52375)
+++ by.Rd   (working copy)
@@ -36,8 +36,6 @@
  }
  \value{
An object of class \code{"by"}, giving the results for each subset.
-  This is always a list if \code{simplify} is false, otherwise a list or
-  array (see \code{\link{tapply}}).
  }
  \seealso{\code{\link{tapply}}}


Thanks!



Why? It is still accessible as a list, even with S4 object, at least for 
the cases I tried.


Uwe Ligges

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] a small suggestion for improving the building of packages

2010-09-15 Thread Uwe Ligges



On 29.08.2010 22:34, Kyle Matoba wrote:

All,

I just finished the process of build a package for the first time and found
it characteristically (for R) very straightforward and well documented.

Whenever I deal with open source software I always endeavor to finish the
task I have in mind, and upon completing this, I then revisit all of the
configurations, customizing as necessary to achieve my goals more fully.
  The ability to achieve some minimal level of functionality without the need
for much filling in of configuration files, etc., is, I feel, important to
not scaring off the less technically inclined such as myself.

Based on this heuristic, it is my understanding that a few small suggestions
could make building a warning-free package as easy as running
package.skeleton(), then R CMD check, R CMD build:

- Fill in default titles for each of the '*.Rd' files in /man
- Take out the tildes in the 'examples' section of the '*-package.Rd' main
documentation file for the package (it seems to confuse the latex compiler)
- Put the lines '~~ Optionally other standard keywords, one per line, from
file KEYWORDS in ~~
~~ the R documentation directory ~~' into the \references{} section, there
is presently a warning about all text needing to be in a section.



Dear Kyle,

thanks for the suggestions. Actually, it is intended to generate 
warnings / Errors in R CMD check: We want to force package developers to 
document their packages probably. This way, package maintainers / 
developers have to touch each Rd file and cannot use them as is in order 
to pass the checks.


Best wishes,
uwe





Thanks, as always, to everyone for their hard work to keep my statistical
computing free and easy.

Best,

Kyle

[[alternative HTML version deleted]]

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] a small suggestion for improving the building of packages

2010-09-16 Thread Uwe Ligges



On 16.09.2010 20:18, Janko Thyson wrote:

From: Uwe Ligges
Date: Wed, 15 Sep 2010 15:23:01 +0200
On 29.08.2010 22:34, Kyle Matoba wrote:

All,

I just finished the process of build a package for the first time and

found

it characteristically (for R) very straightforward and well

documented.


Whenever I deal with open source software I always endeavor to finish

the

task I have in mind, and upon completing this, I then revisit all of

the

configurations, customizing as necessary to achieve my goals more

fully.

The ability to achieve some minimal level of functionality without

the
need

for much filling in of configuration files, etc., is, I feel,

important to


not scaring off the less technically inclined such as myself.

Based on this heuristic, it is my understanding that a few small

suggestions

could make building a warning-free package as easy as running
package.skeleton(), then R CMD check, R CMD build:

- Fill in default titles for each of the '*.Rd' files in /man
- Take out the tildes in the 'examples' section of the '*-package.Rd'

main


documentation file for the package (it seems to confuse the latex

compiler)

- Put the lines '~~ Optionally other standard keywords, one per line,

from


file KEYWORDS in ~~
~~ the R documentation directory ~~' into the \references{} section,

there


is presently a warning about all text needing to be in a section.

Dear Kyle,
thanks for the suggestions. Actually, it is intended to generate
warnings /
Errors in R CMD check: We want to force package developers to document
their
packages probably. This way, package maintainers / developers have to
touch
each Rd file and cannot use them as is in order to pass the checks.
Best wishes,
uwe


Dear Uwe,
in principle, I totally agree with your point of politely forcing developers
to write well documented packages. However, when you're trying to put
together a package, you (or at least I) never get it completely right on the
first, say, 20 tries ;-) Yet, by running package.skelleton() over and over
to keep track of changes you made during the process, you overwrite all Rd
files each time - including the ones that you might already have put a lot
of effort into. And delaying documentation to the very end of the process is
probably not the best idea either ;-) IMHO the community should favor the
approaches taken by packages such as roxygen or inlinedocs as at least it
provides some sort of direct synchronization between code and documentation.
Maybe one could agree on rejecting code that is missing roxygen or inlinedoc
code, which would ensure that code is documented properly. In fact, isn't
programming all about automating unnecessary manual procedures? I would
count starting from scratch with all help files time and time again to be
one of those unnecessary procedures. This time could better be invested in
increasing the package's functionality.


- I don't think package.skeleton overwrites files unless you ask for it.

- I think once you got started with your package, it is not required to 
call package skeleton again. I tend to add files manually since I am 
working on the package hierarchy itself using some editor...


- Last time I used package.skeleton is probably more than 2 years ago 
(except for presentations in courses about package creation).


Best,
Uwe







Best regards, my thanks go out to everyone as well,
Janko


Thanks, as always, to everyone for their hard work to keep my

statistical

computing free and easy.

Best,

Kyle

[[alternative HTML version deleted]]

__
R-devel_at_r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] Matrix install fails because of defunct save in require

2010-09-17 Thread Uwe Ligges



On 17.09.2010 16:04, Thomas Petzoldt wrote:

Dear R-Devel,

I've just tried to compile the fresh R-devel and found that the install
of package Matrix failed:

-
** help
*** installing help indices
** building package indices ...
Error in require(Matrix, save = FALSE) :
unused argument(s) (save = FALSE)
ERROR: installing package indices failed
-



Have you got the Matrix package from the appropriate 2.12/recommended 
repository or installed via


make rsync-recommended
make recommended



In that case it works for me.

Uwe



possible reason: Matrix/data/*.R

News.Rd says:

The \code{save} argument of \code{require()} is defunct.


Thomas Petzoldt

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] some problems reported in 00check.log

2010-09-17 Thread Uwe Ligges



On 17.09.2010 14:25, carol white wrote:

  Hi,
1-
  How is it possible to use the name of a generic function as
  the name of a function which is not related to the generic
  function?


This is not possible, choose a different name or make it a predict() 
methods.


>  For example, if I define predict.my.function, R

  will relate it to predict function and I'll get the following
  warning when I run R CMD check

  * checking S3 generic/method consistency ... WARNING
  predict:
function(object, ...)
  predict.my.function ...





2- I get the following warning although I have used "require" of the related 
library in the function and imports in DESCRIPTION file

no visible global function definition for coxph



If you do not import it into your namespace but make it available via 
require() instead, you need to declare it as Depends.




3- Although I use the alias of an Rd file of my package in cross references:

\seealso{
See Also as \code{\link{object.name}}
}
where object.name is the name of an Rd file without Rd


What is "an Rd file without Rd"?



, I get the following warning

Missing link(s) in documentation object './man/object.name.Rd':
object.name


This means you cited the help page itself?

I think you need to tell us the alias(es) you used as well as the 
purpose of this one.





  I don't think that I will have use the name of my package.



Why is this related?

Best wishes,
Uwe Ligges





Look forward to your reply,

  Carol






__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] Matrix install fails because of defunct save in require

2010-09-17 Thread Uwe Ligges



On 17.09.2010 19:54, Berwin A Turlach wrote:

G'day Uwe,

On Fri, 17 Sep 2010 19:22:04 +0200
Uwe Ligges  wrote:




On 17.09.2010 16:04, Thomas Petzoldt wrote:

Dear R-Devel,

I've just tried to compile the fresh R-devel and found that the
install of package Matrix failed:

-
** help
*** installing help indices
** building package indices ...
Error in require(Matrix, save = FALSE) :
unused argument(s) (save = FALSE)
ERROR: installing package indices failed
-



Have you got the Matrix package from the appropriate 2.12/recommended
repository or installed via

make rsync-recommended
make recommended


Are those the commands that should now be used?  My script is
essentially doing:

svn up
tools/rsync-recommended
make
make check FORCE=FORCE

Running the script now, I experience the same problem as Thomas.  But I
note that Thomas did not state exactly what he is compiling.  My 'svn
up' updates the version checked out from:
https://svn.r-project.org/R/trunk
which I think of as R-devel.
Now after the svn up the file VERSION in the source directory says:
2.13.0 Under development (unstable)
The SVN-REVISION file in my build directory says:
Revision: 52938
Last Changed Date: 2010-09-17
And I have Matrix_0.999375-44.tar.gz in src/library/Recommended of my
source directory.

As you refer to 2.12/recommended, you and Thomas might talk about
different versions when talking about R-devel.



Indeed, I referred to R-prerelease (alpha / to be R-2.12.0 in October) 
rather than R-devel (perhaps to be R-2.13.0 next April or so).


Uwe



Cheers,

Berwin


__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] some problems reported in 00check.log

2010-09-18 Thread Uwe Ligges



On 17.09.2010 20:15, carol white wrote:

Thank you for your reply.

--- On Fri, 9/17/10, Uwe Ligges  wrote:


From: Uwe Ligges
Subject: Re: [Rd] some problems reported in 00check.log
To: "carol white"
Cc: r-devel@r-project.org
Date: Friday, September 17, 2010, 10:45 AM






regarding the point 3,
Suppose I have a data set, data.set1 with data.set1.Rd and data.set2 with 
data.set2.Rd that are related to each other. then, I put in \seealso field

in data.set2.Rd
\seealso{
  See Also as \code{\link{data.set1}}

and in data.set1.Rd
\seealso{
  See Also as \code{\link{data.set2}}

But I get the aforementioned warning that I don't understand why.

Missing link(s) in documentation object

'./man/object.name.Rd':

object.name



In that case I guess you forgot to specify the aliases appropriately?



There is another problem. I have installed two packages in another path than 
the library path of R. how could I load them for R CMD check (where to indicate 
the path for lib.loc) as I get error message due to require of these two 
packages in different functions?


For example, specify all relevant libraries in the environment variable 
R_LIBS.


Best,
Uwe Ligges







3- Although I use the alias of an Rd file of my

package in cross references:


\seealso{
See Also as \code{\link{object.name}}
}
where object.name is the name of an Rd file without

Rd

What is "an Rd file without Rd"?



, I get the following warning

Missing link(s) in documentation object

'./man/object.name.Rd':

object.name


This means you cited the help page itself?

I think you need to tell us the alias(es) you used as well
as the
purpose of this one.




I don't think that I will have use

the name of my package.


Why is this related?

Best wishes,
Uwe Ligges





Look forward to your reply,

Carol






__
R-devel@r-project.org

mailing list

https://stat.ethz.ch/mailman/listinfo/r-devel








__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] some problems reported in 00check.log

2010-09-23 Thread Uwe Ligges



On 23.09.2010 09:20, carol white wrote:

True. A markup command won't be enough to do the job. A function is needed to 
count the character number (based on the font and size) and if it is greater 
than the width of the page (based on A4 format or US letter), it will split the 
line.

Now another question regarding the code in the \examples field: how to keep the 
same format as the source code because all lines start vertically at the same 
position? for ex, if I have tab set manually in the source code, it is ignored 
in the pdf manual file. Do I have to use \tab? How about html help page?

>

I have noticed that there is one file 00Index.html in html folder. I didn't 
have any error message when I ran R CMD check and build. But it seems that 
other html files missing. How to repair?


If this is R > 2.10.0, it is expected. Static html files are not 
generated upon installation any more. Contents is generated dynamically 
upon request now.




when I ran R CMD check, the pdf manual file was created in one level up the 
package folder. I moved it to help folder. How to set options so that  it will 
be created in the help folder?


The pdf manual is not part of a binary package. A user can ask R to 
generate the manual or parts of it. The manual will so be generated by 
CRAN, for example.



Uwe Ligges






thanks,

--- On Wed, 9/22/10, Prof Brian Ripley  wrote:


From: Prof Brian Ripley
Subject: Re: [Rd] some problems reported in 00check.log
To: "carol white"
Cc: "Uwe Ligges", r-devel@r-project.org
Date: Wednesday, September 22, 2010, 5:04 AM
On Wed, 22 Sep 2010, carol white
wrote:


So there is no sort of automatic way like using a

markup command for the susceptible fields instead of
splitting manually a line on different lines?

Well, how is the automatic command to know how to do
this?  As you
will see from the autmatic wrapping in e.g. deparse(), we
are not able
to do a very good job.

There has been some talk about doing this automatically as
a backstop,
but I don't know the current state: in any case it does not
happen in
released versions of R.


True that this doesn't happen in Arguments field (I

confused with

Format field).

Also true that the codes used in Usage, Examples etc

are in

courrier. Is there any way to reduce the size and not

to change the

font of character for these fields?


You can change Rd.sty, which already contains options for
using
other fontsets.



Best,

Carol

--- On Wed, 9/22/10, Prof Brian Ripley

wrote:



From: Prof Brian Ripley
Subject: Re: [Rd] some problems reported in

00check.log

To: "carol white"
Cc: "Uwe Ligges",

r-devel@r-project.org

Date: Wednesday, September 22, 2010, 2:15 AM
On Wed, 22 Sep 2010, carol white
wrote:


Thank you very much Uwe. It works now.

I have a question about pdf formating in pdf

manual

file:


How to format the long lines which go to the

margin?

For ex, this happens in Usage field if a function

has many

arguments. Also, it happens in examples or

Arugment sections

when the lines are long.

Correct the sources by re-formatting over-long

lines

yourself.  (This should only happen in

verbatim-like

sections, hence unlikely to happen in

\argument{}.)


One of the things we suggest when checking a

package is to

read through the PDF manual, and this is one of

the problems

to look out for.  (Note that it does depend on

the

fonts used for the PDF, but the default Courier

for

monospaced text is somewhat wide.)

-- Brian D. Ripley,
 rip...@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








--
Brian D. Ripley,
   rip...@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






__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] some problems reported in 00check.log

2010-09-23 Thread Uwe Ligges



On 23.09.2010 18:16, carol white wrote:

I used the 2.10.0 version


My apologies, I actually meant  R >= 2.10.0
and hence it is not a surprise.

Best,
Uwe Ligges



--- On Thu, 9/23/10, Uwe Ligges  wrote:


From: Uwe Ligges
Subject: Re: [Rd] some problems reported in 00check.log
To: "carol white"
Cc: "Prof Brian Ripley", r-devel@r-project.org
Date: Thursday, September 23, 2010, 4:57 AM




If this is R>  2.10.0, it is expected. Static html files
are not
generated upon installation any more. Contents is generated
dynamically
upon request now.







__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] Function works when custom defined but not when part of a package

2010-09-28 Thread Uwe Ligges
I guess you forgot to import the relevant S4 functionality into your 
namespace.


Best,
Uwe



On 28.09.2010 02:33, Mike Lawrence wrote:

Hi folks,

I'm not sure if this is a bug or not so I thought I'd check here
first. I came across it while working on an update to my package where
I try to get AICtab slot from the summary of an lmer object (
summary(my_lmer)@AICtab ). The attached contains a minimal example,
where the code  below will work if you load the f() function by
sourcing the package's R code but will throw an error ("trying to get
slot "AICtab" from an object (class "table") that is not an S4
object") if you load the f() function by installing and loading the
package itself.

library(lme4)
#here is where you would either source('f.R') or library(dummy)

#fit an lmer model (from ?lmer examples)
fm1<- lmer(Reaction ~ Days + (Days|Subject), sleepstudy)

#run f()
f(fm1)



__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] bulding a package for Windows (path problem?)

2010-09-30 Thread Uwe Ligges
You need a recent version of the Rtools from Duncan Murdoch's web page. 
It includes the file.exe required for checking.


Uwe Ligges

On 30.09.2010 18:38, jgar...@ija.csic.es wrote:

Thanks to Duncan Murdoch and Prof. Ripley for the previous answers. I
apologize as I was not updated with the R version. Now with R 2.12.0 alpha
the package builds [Windows XP] but it still fails when checking:

---
C:\home\javier\Documents\hydrology\development>R CMD check hydrosim
* using log directory
'C:/home/javier/Documents/hydrology/development/hydrosim.Rcheck'
* using R version 2.12.0 alpha (2010-09-28 r53056)
* using platform: i386-pc-mingw32 (32-bit)
* using session charset: ISO8859-1
* checking for file 'hydrosim/DESCRIPTION' ... OK
* this is package 'hydrosim' version '1.0-0'
* checking package dependencies ... OK
* checking if this is a source package ... OK
Error in system2("file", "--version", TRUE, TRUE) : '"file"' not found
Execution halted

C:\home\javier\Documents\hydrology\development>file
"file" no se reconoce como un comando interno o externo,
programa o archivo por lotes ejecutable.
---

As you may guess, the above means "'file' is not recognized as an internal
or external command, operable program or batch file".

Could you help with this? Perhaps the string "file" should have been
substituted by a file name elsewhere before? Could the white spaces in
"C:\Archivos de programa\..." be the source of the problem?

Thanks again,

Javier
---


jgar...@ija.csic.es wrote:

Hi,

I am working on a package with several hydrological functions which
builds/checks/INSTALLs gracefully for a Linux box. However, for a
Microsoft Windows XP [Versión 5.1.2600] I have the error:

C:\Archivos de programa\R\R-2.9.2\bin>R CMD build
C:\home\javier\Documents\hydrology\development\hydrosim



Are you really using version 2.9.2?  If so, I think you're on your own.
The current release is 2.11.1, and our efforts are concentrated on
testing the alpha/beta of 2.12.0 now.

Duncan Murdoch


Can't locate R/Dcf.pm in @INC (@INC contains: C
/ARCHIV~1/R/R-29~1.2/share/perl; /usr/lib/perl5/5.10/i686-cygwin
/usr/lib/per
l5/5.10 /usr/lib/perl5/site_perl/5.10/i686-cygwin
/usr/lib/perl5/site_perl/5.10
/usr/lib/perl5/vendor_perl/5.10/i686-cygwin
/
usr/lib/perl5/vendor_perl/5.10 /usr/lib/perl5/vendor_perl/5.10
/usr/lib/perl5/site_perl/5.8 /usr/lib/perl5/vendor_perl/5.8 .)
  at C:\ARCHIV~1\R\R-29~1.2/bin/build line 28.
BEGIN failed--compilation aborted at C:\ARCHIV~1\R\R-29~1.2/bin/build
line
28.

However, the content of the first mentioned folder is:

C:\ARCHIV~1\R\R-29~1.2\share\perl\R>ls
Dcf.pm Logfile.pm Rd.pm Rdconv.pm Rdlist.pm Rdtools.pm Utils.pm Vars.pm

Is there a problem with the way windows abbreviates folder names for
long
names of names withs spaces? Or the problem is elsewhere?

Please, could you help?

Thanks and best regards,
Javier
---

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel






__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] Rcmd build 32bit-only package on win7 64 bit platform?

2010-10-19 Thread Uwe Ligges



On 18.10.2010 22:01, Hans-Peter Suter wrote:

Is it possible to suppress compiling for the x64 arch when doing 'Rcmd
build?



R CMD build  does not compile anything except for creating the 
vignettes. Is this the case?
If so: During the pre-release cycle of R-2.12.0 we have not got any 
report telling us this is a desirable feature.




Such that the pre-compiled package for binary
distribution only contains a 'lib/i386/mypkg.dll'.

For CHECK (and also INSTALL) there is a '--no-multiarch' argument, but
I didn't find something similar for build.



For now, you can use an only 32-bit installation of R in order to build. 
Passing down a flag such as --no-multiarch will be considered.




Otherwise, I suppose, I could
- handle the problem in Makevars or Makefile or
- build the shlib manually and put it at the correct place or
- provide a placeholder library with C (my code is Delphi, 64bit
should/will come next year)
- (build inside a XP32bit VM)

Are there any other packages which are 32bit only (for now)?


Yes, http://cran.r-project.org/bin/windows/contrib/2.12/@ReadMe tells us:

Packages
Cairo, RBrownie, RSvgDevice, RSVGTipsDevice, SNPassoc, coxphf, eco,
gcmrec, magnets, proj4, ripa, sampfling, survrec, yaml
are only available for 32-bit installations.

Best,
Uwe Ligges


Thanks for any advise,
Hans-Peter

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] new.env does not recognize parents from subclassesof "environment"

2010-10-23 Thread Uwe Ligges
Looks like those ETH pages were nnot updated after the R-2.12.0 release 
(they do not show current R-tached / R-devel), hence CCing Martin Maechler.


Best,
Uwe Ligges





On 22.10.2010 21:54, Vitally S. wrote:




John Chambers  writes:


  You need to update your version of R (r-devel or 2.12 patched) to rev
53385 or later, and read NEWS, particularly the line:

- Assignment of an environment to functions or as an attribute to other
objects now works for subclasses of "environment".



I am following the news in daily snapshots from here
ftp://ftp.stat.math.ethz.ch/Software/R
and  the above line is still not in the NEWS of today's version.

Thanks for the patch. Looking forward to the stable release.

Vitally.


On 10/22/10 10:20 AM, Vitally S. wrote:

Yet another inconsistency. environment<- does not work with S4:



setClass("myenv", contains = "environment")

[1] "myenv"

env<- new("myenv")
tf<- function(x){x}
environment(tf)<- env

Error in environment(tf)<- env :
   replacement object is not an environment


Vitally.


John Chambers  writes:

This is a problem related to the introduction of exact= into the [[ and [[<- 
functions. As Bill says, the

current

method misuses eval.parent() when that argument is added.

However, a simpler and more efficient solution is to migrate the checks for subclasses of 
"environment" used in
other base code into the code for [[<- (and for $<-), at which point the 
methods for these functions are no

longer

needed.

A solution on these lines is being tested now and will find its way into 
r-devel and 2.12 patched.

One other point about the original posting:

Please don't use constructions like e...@.xdata. This depends on the current 
implementation and is not part of

the

user-level definition. Use as(env, "environment") or equivalent. (In this case, 
the assignment of the object's

own

environment was irrelevant to the error.)

John Chambers

On 10/21/10 9:21 AM, William Dunlap wrote:

The traceback looks very similar to a problem
in R 2.11.1 reported earlier this month by Troy Robertson.
>   From: r-devel-boun...@r-project.org
>   [mailto:r-devel-boun...@r-project.org] On Behalf Of Troy Robertson
>   Sent: Wednesday, October 06, 2010 6:13 PM
>   To: 'r-devel@R-project.org'
>   Subject: Re: [Rd] Recursion error after upgrade to
>   R_2.11.1[Sec=Unclassified]
It was due to a miscount of how many frames to go
up before evaluating an expression in
getMethod("[[<-",".environment") because setMethod()
introduced a local function in the new method.

Bill Dunlap
Spotfire, TIBCO Software
wdunlap tibco.com


-Original Message-
From: r-devel-boun...@r-project.org
[mailto:r-devel-boun...@r-project.org] On Behalf Of Vitally S.
Sent: Thursday, October 21, 2010 9:00 AM
To: John Chambers
Cc: r-devel@r-project.org
Subject: Re: [Rd] new.env does not recognize parents from
subclassesof "environment"



Here is an infinite recursion error  which occurs only with S4
subclasses assignment.

   setClass("myenv", contains = "environment")
#[1] "myenv"
   env<- new("myenv")
   env[[".me"]]<- ∑
#Error: evaluation nested too deeply: infinite recursion /
options(expressions=)?


With basic types it works as expected:

env1<- new.env()
env1[[".me"]]<- env1

May be this is related to active bindings that you mentioned,
   but I am still
reporting it here.

Vitally.



   Thanks for the report.  Should now be fixed in r-devel and

2.12 patched (rev 53383).

Please do report any cases where a subclass of environment

doesn't work.  There are some known cases in locking and

active binding, that will be fixed in due course.

The workaround for any such problem is usually as.environment().

On 10/20/10 3:17 AM, Vitaly S. wrote:

Dear Developers,

A lot has been changed in the R12.0 with respect to

behavior of "environment"

subclasses.  Many thanks for that.

One small irregularity, though; new.env does not allow the

parent to be from S4

subclass.



setClass("myenv", contains="environment")

[1] "myenv"

new.env(parent=new("myenv"))

Error in new.env(parent = new("myenv")) : 'enclos' must be

an environment

I wonder if this is a "planed" behavior.

The use of .xData  slot obviously works:

new.env(parent=new("myenv")@.xData)


Thanks,
Vitaly.

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel>>>  
__

R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel>>>>  
__

R-devel@r-project.org mailing list
https://

Re: [Rd] new.env does not recognize parents from subclassesof "environment"

2010-10-23 Thread Uwe Ligges



On 23.10.2010 17:08, Uwe Ligges wrote:

Looks like those ETH pages were nnot updated after the R-2.12.0 release
(they do not show current R-tached / R-devel), hence CCing Martin Maechler.



... which I actually do now...

Uwe



Best,
Uwe Ligges





On 22.10.2010 21:54, Vitally S. wrote:




John Chambers writes:


You need to update your version of R (r-devel or 2.12 patched) to rev
53385 or later, and read NEWS, particularly the line:

- Assignment of an environment to functions or as an attribute to other
objects now works for subclasses of "environment".



I am following the news in daily snapshots from here
ftp://ftp.stat.math.ethz.ch/Software/R
and the above line is still not in the NEWS of today's version.

Thanks for the patch. Looking forward to the stable release.

Vitally.


On 10/22/10 10:20 AM, Vitally S. wrote:

Yet another inconsistency. environment<- does not work with S4:



setClass("myenv", contains = "environment")

[1] "myenv"

env<- new("myenv")
tf<- function(x){x}
environment(tf)<- env

Error in environment(tf)<- env :
replacement object is not an environment


Vitally.


John Chambers writes:

This is a problem related to the introduction of exact= into the [[
and [[<- functions. As Bill says, the

current

method misuses eval.parent() when that argument is added.

However, a simpler and more efficient solution is to migrate the
checks for subclasses of "environment" used in
other base code into the code for [[<- (and for $<-), at which
point the methods for these functions are no

longer

needed.

A solution on these lines is being tested now and will find its way
into r-devel and 2.12 patched.

One other point about the original posting:

Please don't use constructions like e...@.xdata. This depends on the
current implementation and is not part of

the

user-level definition. Use as(env, "environment") or equivalent.
(In this case, the assignment of the object's

own

environment was irrelevant to the error.)

John Chambers

On 10/21/10 9:21 AM, William Dunlap wrote:

The traceback looks very similar to a problem
in R 2.11.1 reported earlier this month by Troy Robertson.
> From: r-devel-boun...@r-project.org
> [mailto:r-devel-boun...@r-project.org] On Behalf Of Troy Robertson
> Sent: Wednesday, October 06, 2010 6:13 PM
> To: 'r-devel@R-project.org'
> Subject: Re: [Rd] Recursion error after upgrade to
> R_2.11.1[Sec=Unclassified]
It was due to a miscount of how many frames to go
up before evaluating an expression in
getMethod("[[<-",".environment") because setMethod()
introduced a local function in the new method.

Bill Dunlap
Spotfire, TIBCO Software
wdunlap tibco.com


-Original Message-
From: r-devel-boun...@r-project.org
[mailto:r-devel-boun...@r-project.org] On Behalf Of Vitally S.
Sent: Thursday, October 21, 2010 9:00 AM
To: John Chambers
Cc: r-devel@r-project.org
Subject: Re: [Rd] new.env does not recognize parents from
subclassesof "environment"



Here is an infinite recursion error which occurs only with S4
subclasses assignment.

setClass("myenv", contains = "environment")
#[1] "myenv"
env<- new("myenv")
env[[".me"]]<- ∑
#Error: evaluation nested too deeply: infinite recursion /
options(expressions=)?


With basic types it works as expected:

env1<- new.env()
env1[[".me"]]<- env1

May be this is related to active bindings that you mentioned,
but I am still
reporting it here.

Vitally.



Thanks for the report. Should now be fixed in r-devel and

2.12 patched (rev 53383).

Please do report any cases where a subclass of environment

doesn't work. There are some known cases in locking and

active binding, that will be fixed in due course.

The workaround for any such problem is usually as.environment().

On 10/20/10 3:17 AM, Vitaly S. wrote:

Dear Developers,

A lot has been changed in the R12.0 with respect to

behavior of "environment"

subclasses. Many thanks for that.

One small irregularity, though; new.env does not allow the

parent to be from S4

subclass.



setClass("myenv", contains="environment")

[1] "myenv"

new.env(parent=new("myenv"))

Error in new.env(parent = new("myenv")) : 'enclos' must be

an environment

I wonder if this is a "planed" behavior.

The use of .xData slot obviously works:

new.env(parent=new("myenv")@.xData)


Thanks,
Vitaly.

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel>>>
__

R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel>>>>
__

R-devel@r-project.org mailing list
https:

Re: [Rd] new.env does not recognize parents from subclassesof "environment"

2010-10-23 Thread Uwe Ligges



On 23.10.2010 17:25, Martin Maechler wrote:

2010/10/23 Uwe Ligges:



On 23.10.2010 17:08, Uwe Ligges wrote:


Looks like those ETH pages were nnot updated after the R-2.12.0 release
(they do not show current R-tached / R-devel), hence CCing Martin
Maechler.



... which I actually do now...


Hmm, but why?
The daily snapshot page *does* show the current R-patched and R-devel
tar balls ?

Or what were you talking about ?


We are talking about the

http://stat.ethz.ch/R-manual/

page. R-devel NEWS show R-2.12.0, just as on example.

Uwe





Regards,
Martin



Uwe



Best,
Uwe Ligges





On 22.10.2010 21:54, Vitally S. wrote:




John Chambers  writes:


You need to update your version of R (r-devel or 2.12 patched) to rev
53385 or later, and read NEWS, particularly the line:

- Assignment of an environment to functions or as an attribute to other
objects now works for subclasses of "environment".



I am following the news in daily snapshots from here
ftp://ftp.stat.math.ethz.ch/Software/R
and the above line is still not in the NEWS of today's version.

Thanks for the patch. Looking forward to the stable release.

Vitally.


On 10/22/10 10:20 AM, Vitally S. wrote:


Yet another inconsistency. environment<- does not work with S4:



setClass("myenv", contains = "environment")


[1] "myenv"


env<- new("myenv")
tf<- function(x){x}
environment(tf)<- env


Error in environment(tf)<- env :
replacement object is not an environment


Vitally.


John Chambers  writes:


This is a problem related to the introduction of exact= into the [[
and [[<- functions. As Bill says, the


current


method misuses eval.parent() when that argument is added.

However, a simpler and more efficient solution is to migrate the
checks for subclasses of "environment" used in
other base code into the code for [[<- (and for $<-), at which
point the methods for these functions are no


longer


needed.

A solution on these lines is being tested now and will find its way
into r-devel and 2.12 patched.

One other point about the original posting:

Please don't use constructions like e...@.xdata. This depends on the
current implementation and is not part of


the


user-level definition. Use as(env, "environment") or equivalent.
(In this case, the assignment of the object's


own


environment was irrelevant to the error.)

John Chambers

On 10/21/10 9:21 AM, William Dunlap wrote:


The traceback looks very similar to a problem
in R 2.11.1 reported earlier this month by Troy Robertson.

From: r-devel-boun...@r-project.org
[mailto:r-devel-boun...@r-project.org] On Behalf Of Troy Robertson
Sent: Wednesday, October 06, 2010 6:13 PM
To: 'r-devel@R-project.org'
Subject: Re: [Rd] Recursion error after upgrade to
R_2.11.1[Sec=Unclassified]

It was due to a miscount of how many frames to go
up before evaluating an expression in
getMethod("[[<-",".environment") because setMethod()
introduced a local function in the new method.

Bill Dunlap
Spotfire, TIBCO Software
wdunlap tibco.com


-Original Message-
From: r-devel-boun...@r-project.org
[mailto:r-devel-boun...@r-project.org] On Behalf Of Vitally S.
Sent: Thursday, October 21, 2010 9:00 AM
To: John Chambers
Cc: r-devel@r-project.org
Subject: Re: [Rd] new.env does not recognize parents from
subclassesof "environment"



Here is an infinite recursion error which occurs only with S4
subclasses assignment.

setClass("myenv", contains = "environment")
#[1] "myenv"
env<- new("myenv")
env[[".me"]]<- ∑
#Error: evaluation nested too deeply: infinite recursion /
options(expressions=)?


With basic types it works as expected:

env1<- new.env()
env1[[".me"]]<- env1

May be this is related to active bindings that you mentioned,
but I am still
reporting it here.

Vitally.



Thanks for the report. Should now be fixed in r-devel and


2.12 patched (rev 53383).


Please do report any cases where a subclass of environment


doesn't work. There are some known cases in locking and


active binding, that will be fixed in due course.

The workaround for any such problem is usually as.environment().

On 10/20/10 3:17 AM, Vitaly S. wrote:


Dear Developers,

A lot has been changed in the R12.0 with respect to


behavior of "environment"


subclasses. Many thanks for that.

One small irregularity, though; new.env does not allow the


parent to be from S4


subclass.



setClass("myenv", contains="environment")


[1] "myenv"


new.env(parent=new("myenv"))


Error in new.env(parent = new("myenv")) : 'enclos' must be


an environment


I wonder if this is a "planed" behavior.

The use of .xData slot obviously works:


new.env(parent=new("myenv")@.xData)



Thanks,
Vitaly.


Re: [Rd] inst/ and hidden files/directories, especially inst/.svn/?

2010-11-03 Thread Uwe Ligges

Yes, ".svn" is special cased.

Uwe Ligges


On 02.11.2010 23:53, Henrik Bengtsson wrote:

In Section 'Package subdirectories' of 'Writing R Extensions',  it
says about the inst/ directory that:

"The contents of the inst subdirectory will be copied recursively to
the installation directory (except perhaps hidden files with names
starting with ‘.’)."

Indeed, on Windows with R v2.12.0 patched (2010-11-01 r53513) and R
v2.13.0 devel (2010-11-01 r53513), if you have:

foo/inst/bar/.bar/foo.txt

that subdirectory .bar/ will be included in the *.tar.gz and *.zip
builds.  However, .svn/ is as in:

foo/inst/bar/.svn/foo.txt

is only included in the *.zip file, not the *.tar.gz file.

Is this expected?  The "perhaps" in the documentation indicates that.

/Henrik

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] inst/ and hidden files/directories, especially inst/.svn/?

2010-11-04 Thread Uwe Ligges



On 03.11.2010 19:26, Henrik Bengtsson wrote:

On Wed, Nov 3, 2010 at 9:50 AM, Uwe Ligges
  wrote:

Yes, ".svn" is special cased.


Good.

Note that it does not seem to be the case for the *.zip archive, only
for the *.tar.gz archive, as I showed.



Henrik,

I do not see how it can go at all into a zip archive if the recommended 
way of creating Windows binaries is used: Please create Windows binary 
packages by running  R CMD INSTALL --build  on the tarball.


Best wishes,
Uwe




/H



Uwe Ligges


On 02.11.2010 23:53, Henrik Bengtsson wrote:


In Section 'Package subdirectories' of 'Writing R Extensions',  it
says about the inst/ directory that:

"The contents of the inst subdirectory will be copied recursively to
the installation directory (except perhaps hidden files with names
starting with ‘.’)."

Indeed, on Windows with R v2.12.0 patched (2010-11-01 r53513) and R
v2.13.0 devel (2010-11-01 r53513), if you have:

foo/inst/bar/.bar/foo.txt

that subdirectory .bar/ will be included in the *.tar.gz and *.zip
builds.  However, .svn/ is as in:

foo/inst/bar/.svn/foo.txt

is only included in the *.zip file, not the *.tar.gz file.

Is this expected?  The "perhaps" in the documentation indicates that.

/Henrik

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel



__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] installing dependencies: binary vs source

2010-11-13 Thread Uwe Ligges



On 12.11.2010 01:40, Hervé Pagès wrote:

Hi,

Installing from binaries on Windows:

 > install.packages("multtest")
Warning: dependency 'Biobase' is not available
trying URL
'http://cran.fhcrc.org/bin/windows/contrib/2.12/multtest_2.6.0.zip'
Content type 'application/zip' length 1645590 bytes (1.6 Mb)
opened URL
downloaded 1.6 Mb

package 'multtest' successfully unpacked and MD5 sums checked

The downloaded packages are in

C:\Users\biocbuild2\AppData\Local\Temp\2\RtmpPzRqzb\downloaded_packages

Note the warning that a dependency is missing. But still the package
got installed even though it won't be loadable.

Now installing from source on Windows:

 > install.packages("multtest", type="source")
Warning: dependency 'Biobase' is not available
trying URL 'http://cran.fhcrc.org/src/contrib/multtest_2.6.0.tar.gz'
Content type 'application/x-gzip' length 1457444 bytes (1.4 Mb)
opened URL
downloaded 1.4 Mb

ERROR: dependency 'Biobase' is not available for package 'multtest'
* removing 'D:/biocbld/bbs-2.7-bioc/R/library/multtest'

The downloaded packages are in

'C:\Users\biocbuild2\AppData\Local\Temp\2\RtmpPzRqzb\downloaded_packages'
Warning message:
In install.packages("multtest", type = "source") :
installation of package 'multtest' had non-zero exit status

Note the warning *and* ERROR.

Is this the intended behavior of install.packages() when installing
from binaries?



Hervé,

yes, I think so. If you ask to install a package, it is installed unless 
it cannot be installed (as it was the case since R had to load Biobase 
which was unavailable).



Best,
Uwe




Thanks,
H.

PS: Sorry I don't have access to an R-2.13 installation where I can
test this at the moment.

 > sessionInfo()
R version 2.12.0 (2010-10-15)
Platform: x86_64-pc-mingw32/x64 (64-bit)

locale:
[1] LC_COLLATE=English_United States.1252
[2] LC_CTYPE=English_United States.1252
[3] LC_MONETARY=English_United States.1252
[4] LC_NUMERIC=C
[5] LC_TIME=English_United States.1252

attached base packages:
[1] stats graphics grDevices utils datasets methods base




__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] trouble compiling RMySQL (and others) for 64 bit windows.

2010-11-13 Thread Uwe Ligges

I just found this obviously unanswered message:

Yes, you need Rtools installed as described in the manual "R 
Installation and Administration" which explains what to do in more 
detail. It makes sense to upgrade to R-2.12.0 if you have not already 
done so.


Best,
Uwe Ligges




On 21.09.2010 22:11, Ted Byers wrote:

I have a 64 bit machine running 64 bit windows 7 pro, 64 bit MySQL, and 64
bit R 2.11.1.

I have also installed RTools for 64 bit windows for this version of R
(archive name is oldWin64toolchain.zip; the install path for its contents
is C:\RTools, if that matters).  I can open up a commandline window and
invoke any of the programs in both bin directories (both added to the system
path).
There are several packages for which I could not find 64 bit binaries
RMySQL, RPostgreSQL, RQRMlib,&c.  While I don't have time at present to
develop ne packages for R, these packages are things I routinely use on my
32 bit machine (where, thankfully, all seems to be working fine).
Therefore, my only interest is in getting or making the 64 bit binaries for
these packages so I can duplicate on the new 64 bit machine what I had been
doing on the old 32 bit machine.

Note, I routinely develop new software using MS VS (originally v 6, and then
VS 2005, and now vs 2010), and if I need to work up code to run on some
flavour of unix, I use the cygwin environment.  Therefore, I have no qualms
about compiling programs I use from source.  I just prefer not to if there
is already a binary distribution for whatever platform I happen to be using.

I began by trying to follow the instructions provided on
http://biostat.mc.vanderbilt.edu/wiki/Main/RMySQL, and found a couple
issues.



First, there was no Renviron.site in C:/Program Files/R/R-2.11.1-x64/etc so
I made one and placed in it the following:

MYSQL_HOME=C:\PROGRA~1\MySQL\MYSQLS~1.1

The full path to the installation of MySQL is: C:\Program Files\MySQL\MySQL
Server 5.1

Unlike what is said on the biostat.mc.vanderbilt.edu pages, MYSQL_HOME is
still empty:



Sys.getenv('MYSQL_HOME')

MYSQL_HOME
 ""
This is when I start R AFTER having made the Renviron.site file.

Something I notice, though, that may have a bearing on this is that although
Emacs finds my new Renviron.site file when I navigate to that directory, it
does not appear in Windows Explorer.  I am wondering if Windows 7 is somehow
blocking access to it.  If that guess is correct, the question becomes, how
do I fix that?  If it isn't correct, what should I check?  This is not an
insurmountable problem, though as I can always set that environment variable
at the beginning of a session.  I do that already on other systems that are
32 bit clients that have to talk to 64 bit servers.  It is just mildly
disturbing that R does not seem to know about the Renviron.site file I made
for it.

Second, I read in the instructions the following:



3. *Re-start R and execute install.packages('RMySQL',type='source')* at
the R prompt.

As long as you followed the above steps correctly, 
RMySQL<https://mail.google.com/wiki/Main/RMySQL>will install cleanly and you 
will be able to immediately load it and use it.


However, when I follow this instruction I get:

install.packages('RMySQL',type='source')

Warning in install.packages("RMySQL", type = "source") :
   argument 'lib' is missing: using
'C:\Users\Ted\Documents/R/win64-library/2.11'
--- Please select a CRAN mirror for use in this session ---
trying URL 'http://probability.ca/cran/src/contrib/RMySQL_0.7-5.tar.gz'
Content type 'application/x-gzip' length 160769 bytes (157 Kb)
opened URL
downloaded 157 Kb
* installing *source* package 'RMySQL' ...
Warning in system("sh ./configure.win") : sh not found
ERROR: configuration failed for package 'RMySQL'
* removing 'C:/Users/Ted/Documents/R/win64-library/2.11/RMySQL'
The downloaded packages are in
 ‘C:\Users\Ted\AppData\Local\Temp\Rtmp7xg8yb\downloaded_packages’
Warning message:
In install.packages("RMySQL", type = "source") :
   installation of package 'RMySQL' had non-zero exit status




It is clearly failing before it could choke on the MYSQL_HOME value.  On
reading it, it is no surprise to me that it failed to find sh as I recognize
that as one of several unix shells.  What I don't know is how I should alter
the instructions provided on the vanderbilt site so that the install works
on Windows 7.  I know I have access to sh in cygwin, but I really don't want
to confound my cygwin environment with what I use for R.

While I have not used RTools before, I would assume that whatever issues I
am presently facing would impact any package for which I need to build 64
bit binaries for Windows 7.  So what do I need to know in order to
effectively use RTools on compiling an arbitrary pa

Re: [Rd] Compiling R 2.12.0 from source: error (temp dir)

2010-11-18 Thread Uwe Ligges

TMPDIR is an wenvironment variable to be set in your OS, for example.

Uwe Ligges


On 18.11.2010 11:40, Janko Thyson wrote:

I've created a /tmp directory so I wouldn't have to change TMPDIR. So far,
so good. But now I get the error below. Anything I forgot regarding tcltk?

Thx,
Janko

ERROR:
In file included from init.c:22:0:
tcltk.h:23:17: fatal error: tcl.h: No such file or directory
compilation terminated.
make[4]: *** [init.o] Error 1
make[3]: *** [mksrc-win] Error 1
make[2]: *** [all] Error 2
make[1]: *** [R] Error 1
make: *** [all] Error 2

SYSTEM INFO:
  - Windows XP SP 3
  - R-2.12.0
  - Eclipse 3.6.1
  - StatET 0.9.x


-Ursprüngliche Nachricht-
Von: Janko Thyson [mailto:janko.thy...@ku-eichstaett.de]
Gesendet: Donnerstag, 18. November 2010 11:13
An: 'Prof Brian Ripley'
Cc: 'r-de...@r-project. org'
Betreff: AW: [Rd] Compiling R 2.12.0 from source: error (temp dir)


-Ursprüngliche Nachricht-
Von: Prof Brian Ripley [mailto:rip...@stats.ox.ac.uk]
Gesendet: Mittwoch, 17. November 2010 18:42
An: Janko Thyson
Cc: 'r-de...@r-project. org'
Betreff: Re: [Rd] Compiling R 2.12.0 from source: error (temp dir)

Is this on Windows?  (Please do consult the posting guide and tell us
the 'at a minimum' information we asked for.)

If so, it seems you forget the bit about setting TMPDIR right at the
top of the section on 'Building the core files':

Set the environment variable @env{TMPDIR} to point to a writable
directory, with a path specified with forward slashes and no

spaces.

(The default is @file{/tmp}, which may not be useful on Windows.)



Sorry, I always forget to provide that info.

Could you tell me where/how I have to set TMPDIR? I've looked in
MkRules.local but didn't find anything. Or is that an argument at 'make
all recommended'?

Thanks,
Janko

SYSTEM INFO:
- Windows XP SP 3
- R-2.12.0
- Eclipse 3.6.1
- StatET 0.9.x


On Wed, 17 Nov 2010, Janko Thyson wrote:


Dear list,



I've just tried to compile R 2.12.0 from source as I think I found

an

error

in a C function that I would like to fix and check before I go

ahead

with

posting the presumed error.



I've got the R Toolset 2.12 installed and configured correctly and

followed

the Admin manual closely (including the entire bitmap stuff; exact

same

versions as in the manual). Also, all anti virus software is turned

off (as

it complained on some .exe). I have Admin rights on my box.



When I run 'make all recommended' I get the following error after a

while:




cannot create /tmp/R5436: directory nonexistent

mv: cannot stat `/tmp/R5436': No such file or directory

make[3]: *** [mkR] Error 1

make[2]: *** [all] Error 2

make[1]: *** [R] Error 1

make: *** [all] Error 2



Any ideas what this is about? Seems that the compiler can't create

a

temp

directory because of a missing directory.



Thanks for any hints,

Janko


[[alternative HTML version deleted]]

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel



--
Brian D. Ripley,  rip...@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, UKFax:  +44 1865 272595


__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] Error in generating sweave-tex -> pdf file-cont.

2010-12-23 Thread Uwe Ligges



On 23.12.2010 11:47, carol white wrote:

I also copied Sweave.sty in the directory of my Rnw file (according to
http://www.stat.uni-muenchen.de/~leisch/Sweave/FAQ.html) but texi2dvi not found
when I ran R CMD check. I also found this solution inconvenient because if one
develops different R packages, he shouldn't copy the Sweave.sty in all
directores containing Rnw file.



You can also add the R subdirectory that includes Sweave.sty and freinds 
to the search path for your TeX distribution.

In that case you won't need to pay attention on Sweave.sty upgrades.

Uwe Ligges







- Original Message 
From: Duncan Murdoch
To: carol white
Cc: r-devel@r-project.org
Sent: Wed, December 22, 2010 10:33:01 PM
Subject: Re: [Rd] Error in generating sweave-tex ->  pdf file

On 22/12/2010 1:30 PM, carol white wrote:

Should the Sweave package be in /usr/share/texmf/tex/latex/? How about
Sweave.sty?


I meant Sweave.sty, there's no separate Sweave package.  It should be in
the R home directory, somewhere within share/texmf.

Duncan Murdoch


Thanks



- Original Message 
From: Duncan Murdoch
To: carol white
Cc: r-devel@r-project.org
Sent: Wed, December 22, 2010 6:42:07 PM
Subject: Re: [Rd] Error in generating sweave-tex ->   pdf file

On 22/12/2010 12:27 PM, carol white wrote:

  Hi,
  I created a Sweave file (see below). when I want to convert tex
  file generated from it into pdf, I get error message as follows:

  >texi2dvi("test.tex", pdf=TRUE)
  Error in texi2dvi("test.tex", pdf = TRUE) :
 Running 'texi2dvi' on 'test.tex' failed.
  LaTeX errors:
  ! Undefined control sequence.
  l.8 \begin
 {Schunk}


The Schunk, Sinput, and Soutput environments are defined in Sweave package.
Something went wrong and latex didn't find them, either because it didn't find
Sweave.sty, or because it did, but that file has been messed up.



  ?
  ! Interruption.
  ! Interruption.
  
  {
  l.8 \begin{
  Schunk}
  ! Undefined control sequence.
  l.9 \begin
 {Sinput}
  The control sequence at the end of the top line
  of your error message was never \def'ed. If you have
  
  test.Rnw

  \usepackage{Sweave}
  \ documentclass [ a4paper ]{ article }
  \ title { Sweave Example 1}
  \ begin { document }
  \ maketitle


Are there really spaces between the backslashes and the macros?  I think that
doesn't work.  You should also have the \usepackage{Sweave} line after the
opening \documentclass line.

Duncan Murdoch


  In this example we embed parts of the examples from the
  help page into a \ LaTeX {} document :
  <>=
  y=2
  y = y +1
  @
  which shows that the location parameter of the Ozone
  distribution varies significantly from month to month . Finally we
  include a boxplot of the data :

  \end{ document }

  __
  R-devel@r-project.org mailing list
  https://stat.ethz.ch/mailman/listinfo/r-devel






__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] Bug filed on unzip() function

2010-12-23 Thread Uwe Ligges

This message contains a good question:

Is there any reason why the bug reports are no longer mailed to R-devel?
I'd appreciate to get a notice what is going on in the bug repository 
without having to look on those web pages.


Best wishes,
Uwe



On 21.12.2010 18:50, Ken Williams wrote:

Hi,

A few days ago I filed a bug report on the unzip() function:

   https://bugs.r-project.org/bugzilla3/show_bug.cgi?id=14462

I haven't gotten any comments yet, so I thought I'd ask for comments
here.  I also see on the description of R-devel that the list "also
receives all (filtered, i.e. non-spam!) bug reports from R-bugs", but
I don't see it here.

Eventually I would like to help unzip() gain large-file support, such
as is offered by http://info-zip.org/UnZip.html version 6.0.  A
corresponding zip() function would be nice too.

Thanks.

  -Ken

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] matrix multiplication speed R

2011-01-14 Thread Uwe Ligges



On 14.01.2011 11:38, Joris Meys wrote:

Please give the code you used for the matrix multiplication. 5 times is a
bit much.


No, it is reasonable for matrix multiplication:

Matlab ships with optimized BLAS for various CPU types. In R, you have 
to get an optimized BLAS yourself.


How to link against optimized BLAS versions or how to substitute the 
BLAS is mentioned in the R INstallation and Administration manual.


Best,
Uwe Ligges





On Fri, Jan 14, 2011 at 9:09 AM, oyvfos  wrote:



Hi,
A quick bench-mark of an R matrix muliplication 500by500 X 500by1, all
random variates, with matlab reveals a huge difference in speed (5 times at
least). Is there anything that can be done in R to speed up the
multiplication?
Kind regards,  Oyvind
--
View this message in context:
http://r.789695.n4.nabble.com/matrix-multiplication-speed-R-tp3217257p3217257.html
Sent from the R devel mailing list archive at Nabble.com.

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel







__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] "Simulate" package namespace at development stage

2011-01-24 Thread Uwe Ligges



On 23.01.2011 21:21, Janko Thyson wrote:

Dear list,

I was wondering if it is possible to create and use a package namespace at
the development stage of a package. To clarify, I would like to make sure
that my package functions (and not some other functions that happen to have
identical names) are called by prepending function names appropriately (e.g.
my.package::foo()). Is that possible before a package is actually build and
loaded? If so, could you tell me how to do it?


No, unless you work around by assigning the stuff in certain 
environments, which would be less convenient than just 
building/installing/testing the package.


Uwe Ligges



Thanks a lot!
Janko

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] trojan at current development version?

2011-01-28 Thread Uwe Ligges



On 28.01.2011 13:49, peter dalgaard wrote:


On Jan 28, 2011, at 09:47 , Andreas Mayr wrote:


Hi,

is it possible, that the current development version  for Windows (
http://cran.at.r-project.org/bin/windows/base/R-2.13.0dev-win.exe) is
infected by a trojan/virus. My antivir-program (www.avira.com) seems to find
a trojan in open.exe at bin\i386.


We have seen false positives before (accidental mismatch between virus 
signatures and legitimate programs). But presumably, the Windows maintainers 
will double-check, just in case.


Oh yes, we got such reports before. People reported to Avira and it went 
away. Now it is there again. Hopeless, I assume.


Duncan: Perhaps we can add at the download page that Avira reports 
open.exe to be infected from time to time.


Best wishes,
Uwe








__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] R limits documented?

2011-02-12 Thread Uwe Ligges
I think it is easiest to point people to the manual "R Internals" for 
questions on the size of integers, pointers etc.


Best,
Uwe Ligges



On 12.02.2011 03:24, David Winsemius wrote:


On Feb 11, 2011, at 8:46 PM, Simon Urbanek wrote:



On Feb 11, 2011, at 8:45 PM, Simon Urbanek wrote:



On Feb 11, 2011, at 7:55 PM, David Winsemius wrote:



On Feb 11, 2011, at 7:09 PM, Dominick Samperi wrote:


Is there documentation on R limits?
That is, max matrix size, etc.?

Diagnostics when limits are exceeded are not always
meaningful. For example:

x <- rep(0,5*5)

Error in rep(0, 5 * 5) : invalid 'times' argument
In addition: Warning message:
In as.vector(data) : NAs introduced by coercion



x <- rep(0,4*5)
gc()

used (Mb) gc trigger (Mb) max used (Mb)
Ncells 4673306 249.6 6945861 371.0 5315868 283.9
Vcells 2165579376 16522.1 4374103452 33371.8 4165580443 31780.9

object.size(x)

1600040 bytes

So that is about 2/3 of my installed memory. This seems to be a
limitation due to the maximum positive integer being ~ 2*10^9

2*10^9 < 5*5

[1] TRUE

2*10^9 < 4*5

[1] FALSE



The actual limit is for obvious reasons 2^31-1


as.integer(2^31-1)

[1] 2147483647

as.integer(2^31)

[1] NA
Warning message:
NAs introduced by coercion

(ok, for those that this is not obvious: the integer type ("int" in
C) is 32-bit wide and it is a signed type so the range is -2^31-1 ..
2^31-1 -- the minus one on each side is the representation of NA and
0 respectively).



correction: the range should have read -(2^31-1) .. 2^31


I was using the number given in the help page documentation for
"integer". (Part of the question was whether it was "documented".) I did
understand that it was d/t the 4 byte range.

Regarding the second part of the OP's question this is from the
"character" help page:
"as.character truncates components of language objects to 500 characters
(was about 70 before 1.3.1)."

And there was a posting from Prof Ripley regarding some other
limitations that had been recently modified:
https://stat.ethz.ch/pipermail/r-devel/2010-November/058989.html



__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] error in: testing if installed package can be loaded

2011-03-28 Thread Uwe Ligges



On 21.03.2011 18:01, Thomas Roth wrote:

hi,

I am preparing my package for R 2.13
build and check gives no warnings just OK's

However when running R CMD INSTALL it gives me (nfortunately it is in
german)





You can change to English by setting

set LANGUAGE=en

before running R CMD check.




** help
*** installing help indices
** building package indices ...
** testing if installed package can be loaded
Fehler: '\U' ohne Hex-Ziffern in der Zeichenkette beginnend mit "C:\U"
genutzt
Ausführung angehalten
Fehler: loading failed


Interesting. From which path are you testing. Using which command? 
What's the name of the package? Can we see the package? Do you have 
recent Rtools installed?


[Checking packages works on winbuilder with R-2.13.0 alpha for 64-bit 
Windows for all CRAN packages without such a message.]


Best,
Uwe Ligges




Is this the packages fault? because i wouldn't know where to look...

sessionInfo()  gives

R version 2.13.0 alpha (2011-03-17 r54849)
Platform: x86_64-pc-mingw32/x64 (64-bit)

locale:
[1] LC_COLLATE=German_Germany.1252  LC_CTYPE=German_Germany.1252
  LC_MONETARY=German_Germany.1252 LC_NUMERIC=C
[5] LC_TIME=German_Germany.1252

attached base packages:
[1] stats graphics  grDevices utils datasets  methods   base

other attached packages:
[1] qualityTools_1.41

loaded via a namespace (and not attached):
[1] tools_2.13.0

Best Whishes

Thomas Roth

[[alternative HTML version deleted]]




__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] datalist and data objects in R Package building

2011-03-28 Thread Uwe Ligges



On 24.03.2011 16:51, andrew stewart wrote:

Hello all,

I have,say 4 R objects...  bar1, bar2, bar3, bar4.. that I'd like to include
in an R package "foobar".

The desired functionality would be:


library(foobar)
data(foo)
ls()

[1] "bar1" "bar2" "bar3" "bar4"

I've tried the following two approaches:

1) I created the file 'datalist' under pre-build directory 'foobar/data/'
with the following contents:
foo: bar1 bar2 bar3 bar4

After package build and install, "data(foo)" reports that data set 'foo' not
found (bar1, bar2, etc are all available individually, and are listed under
data() as "bar1 (foo)".



If you want just one object "foo", then prpare a list

foo <- list(bar1,...)

that contains the 4 objects bar1, ... .
You can load that objects and access the list components afterwards.

I think you misunderstood the data concept: You can save objects and 
load them if the package is installed. That's it.


Best,
Uwe Ligges




2) I created an image via save.image resulting in foo.rda (containing bar1,
bar2, etc).

data(foo) now loads bar1 - bar4, but 'foo' doesn't appear in the list of
available datasets displayed when trying to tab complete within data().


So my question is, what's the correct approach for what I'm trying to do
here?  Any advice welcome and appreciated.

Thanks,
Andrew

[[alternative HTML version deleted]]

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] datalist and data objects in R Package building

2011-03-28 Thread Uwe Ligges



On 28.03.2011 17:49, andrew stewart wrote:

Thank you for your response.

Yes, using a call to data() after 1) building and 2) installing my own
package is exactly what I'm trying to accomplish.  I am building a package.
  I would like to load the data objects that are part of the custom package
that I have created and installed on my machine.  Apologies if I wasn't
clear about that part.


Then just apply data() on all data names in your package or bundle the 
data in lists. If you want to load all data object all the time you load 
your package, I'd recommend to enable lazy loading of the data, so you 
do not need to explicitly load by data are loaded on demand.


Best,
Uwe Ligges





2011/3/28 Uwe Ligges




On 24.03.2011 16:51, andrew stewart wrote:


Hello all,

I have,say 4 R objects...  bar1, bar2, bar3, bar4.. that I'd like to
include
in an R package "foobar".

The desired functionality would be:

  library(foobar)

data(foo)
ls()


[1] "bar1" "bar2" "bar3" "bar4"

I've tried the following two approaches:

1) I created the file 'datalist' under pre-build directory 'foobar/data/'
with the following contents:
foo: bar1 bar2 bar3 bar4

After package build and install, "data(foo)" reports that data set 'foo'
not
found (bar1, bar2, etc are all available individually, and are listed
under
data() as "bar1 (foo)".




If you want just one object "foo", then prpare a list

foo<- list(bar1,...)

that contains the 4 objects bar1, ... .
You can load that objects and access the list components afterwards.

I think you misunderstood the data concept: You can save objects and load
them if the package is installed. That's it.

Best,
Uwe Ligges



  2) I created an image via save.image resulting in foo.rda (containing

bar1,
bar2, etc).

data(foo) now loads bar1 - bar4, but 'foo' doesn't appear in the list of
available datasets displayed when trying to tab complete within data().


So my question is, what's the correct approach for what I'm trying to do
here?  Any advice welcome and appreciated.

Thanks,
Andrew

[[alternative HTML version deleted]]

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel







__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] Suggests and examples

2011-04-03 Thread Uwe Ligges



On 03.04.2011 19:31, Jay Emerson wrote:

I apologize in advance for probably missing something obvious, but if
someone could point me in the right direction I'd be grateful.  This
NOTE is not unique to our package (I list a few others, below).

Package bcp has several Suggests (strucchange, for example).



Well, at least the version ion CRAN does not have any Suggests entry in 
its DESCRIPTION file...


Uwe




Then in an Rd file, we have

if (require(strucchange)) {

   # Doing some examples making use of strucchange

}

The CRAN check results reports the following NOTE:

checking for unstated dependencies in examples ... NOTE
'library' or 'require' calls not declared from:
DNAcopy coda strucchange

I note the same problems in other packages (e1071, Deducer, diveMOVE,
gplots, ...)

Any hints?  I'm pretty confident that Suggests: is preferable to
Depends: in such a case, but I can't seem to address this note.
Thanks,

Jay




__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] R CMD build --resave-data

2011-04-11 Thread Uwe Ligges



On 11.04.2011 02:47, Hervé Pagès wrote:

Hi,

More about the new --resave-data option

As mentioned previously here

https://stat.ethz.ch/pipermail/r-devel/2011-April/060511.html

'R CMD build' and 'R CMD INSTALL' handle this new option
inconsistently. The former does --resave-data="gzip" by default.
The latter doesn't seem to support the --resave-data= syntax:
the --resave-data flag must either be present or not. And by
default 'R CMD INSTALL' won't resave the data.

Also, because now 'R CMD build' is resaving the data, shouldn't it
reinstall the package in order to be able to do this correctly?

Here is why. There is this new warning in 'R CMD check' that complains
about files not of a type allowed in a 'data' directory:


http://bioconductor.org/checkResults/2.8/bioc-LATEST/Icens/lamb1-checksrc.html


The Icens package also has .R files under data/ with things like:

bet <- matrix(scan("CMVdata", quiet=TRUE),nc=5,byr=TRUE)

i.e. the R code needs to access some of the text files located
in the data/ folder. So in order to get rid of this warning I
tried to move those text files to inst/extdata/ and I modified
the code in the .R file so it does:

CMVdata_filepath <- system.file("extdata", "CMVdata", package="Icens")
bet <- matrix(scan(CMVdata_filepath, quiet=TRUE),nc=5,byr=TRUE)

But now 'R CMD build' fails to resave the data because the package
was not installed first and the CMVdata file could not be found.

Unfortunately, for a lot of people that means that the safe way to
build a source tarball now is with

R CMD build --keep-empty-dirs --no-resave-data



Hervé,

actually is makes some sense to have these defaults from a CRAN 
maintainer's point of view:


--keep-empty-dirs:
we found many packages containing empty dirs unnecessarily and the idea 
is to exclude them at the build state rather than at the later 
installation stage. Note that the package maintainer is supposed to run 
build (and knows if the empty dirs are to be included, the user who runs 
INSTALL does not).


--no-resave-data:
We found many packages with unsufficiently compressed data. This should 
be fixed when building the package, not later when installing it, since 
the reduces size is useful in the source tarball already.


So it does make some sense to have different defaults in build as 
opposed to INSTALL from my point of view (although I could live with 
different, tough).


If you need further arguments for the discussion: I also tend to use 
--no-vignettes nowadays if my code does not change considerably. ;-)


Best wishes,
Uwe




I hope the list of options/flags that we need to use to "fix" 'R CMD
build' (and make it consistent with R CMD INSTALL) is not going to
grow too much ;-)

Thanks,
H.




__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] duplicates() function

2011-04-11 Thread Uwe Ligges

Thanks for your answer, but:
1. can you please cite the question? It is hard for mailing list readers 
to follow now.

2. I think
   which(duplicated(x))
should be simpler, faster and less confusing, if your code would be the 
solution - which is not.
3. Please read the original question carefuly and find that your code 
and my optimization of it above gives a different undesired answer.


Best,
Uwe Ligges






On 09.04.2011 01:05, B77S wrote:

which(duplicated(x)=="TRUE")

--
View this message in context: 
http://r.789695.n4.nabble.com/duplicates-function-tp3436584p3437614.html
Sent from the R devel mailing list archive at Nabble.com.

__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


Re: [Rd] R CMD build --resave-data

2011-04-13 Thread Uwe Ligges



On 13.04.2011 02:53, Hervé Pagès wrote:

Hi Uwe,

On 11-04-11 08:13 AM, Uwe Ligges wrote:



On 11.04.2011 02:47, Hervé Pagès wrote:

Hi,

More about the new --resave-data option

As mentioned previously here

https://stat.ethz.ch/pipermail/r-devel/2011-April/060511.html

'R CMD build' and 'R CMD INSTALL' handle this new option
inconsistently. The former does --resave-data="gzip" by default.
The latter doesn't seem to support the --resave-data= syntax:
the --resave-data flag must either be present or not. And by
default 'R CMD INSTALL' won't resave the data.

Also, because now 'R CMD build' is resaving the data, shouldn't it
reinstall the package in order to be able to do this correctly?

Here is why. There is this new warning in 'R CMD check' that complains
about files not of a type allowed in a 'data' directory:


http://bioconductor.org/checkResults/2.8/bioc-LATEST/Icens/lamb1-checksrc.html




The Icens package also has .R files under data/ with things like:

bet <- matrix(scan("CMVdata", quiet=TRUE),nc=5,byr=TRUE)

i.e. the R code needs to access some of the text files located
in the data/ folder. So in order to get rid of this warning I
tried to move those text files to inst/extdata/ and I modified
the code in the .R file so it does:

CMVdata_filepath <- system.file("extdata", "CMVdata", package="Icens")
bet <- matrix(scan(CMVdata_filepath, quiet=TRUE),nc=5,byr=TRUE)

But now 'R CMD build' fails to resave the data because the package
was not installed first and the CMVdata file could not be found.

Unfortunately, for a lot of people that means that the safe way to
build a source tarball now is with

R CMD build --keep-empty-dirs --no-resave-data



Hervé,

actually is makes some sense to have these defaults from a CRAN
maintainer's point of view:

--keep-empty-dirs:
we found many packages containing empty dirs unnecessarily and the idea
is to exclude them at the build state rather than at the later
installation stage. Note that the package maintainer is supposed to run
build (and knows if the empty dirs are to be included, the user who runs
INSTALL does not).

--no-resave-data:
We found many packages with unsufficiently compressed data. This should
be fixed when building the package, not later when installing it, since
the reduces size is useful in the source tarball already.

So it does make some sense to have different defaults in build as
opposed to INSTALL from my point of view (although I could live with
different, tough).


If you deliberately ignore the fact that 'R CMD INSTALL' is also used
by developers to install from the *package source tree* (by opposition
to end users who use it to install from a *source tarball*, even though
they don't use it directly), then you have a point. So maybe I should
have been more explicit about the problem that it can be for the
*developer* to have 'R CMD build' and 'R CMD INSTALL' behave
differently by default.

Of course I'm not suggesting that 'R CMD INSTALL' should behave
differently (by default) depending on whether it's used on a source
tarball (mode 1) or a package source tree (mode 2).

I'm suggesting that, by default, the 3 commands (R CMD build +
R CMD INSTALL in mode 1 and 2) behave consistently.

With the latest changes, and by default, 'R CMD INSTALL' is still doing
the right thing, but not 'R CMD build' anymore.

I perfectly understand the intention behind those new flags, which is
to try to "optimize" the resulting source tarball but what would you
think if 'gcc' had some optimization flags that can generate broken
executables (under some circumstances) and if these flags were enabled
by default?

Note that I would have no problem with 'R CMD build' trying to resave
the data by default if the current implementation of that feature
was working properly, but unfortunately it's broken (see my previous
email for the details).


It is one thing to talk about sensible defaults and another thing to 
talk about bugs. I just talked about sensible defaults. And I have not 
had the time to look iunto details. I just arrived in Dortmund 15 
minutes ago and I the first thing I have to do is repairing some 
winbuilder stuff and get 2.13.0 ready on it. I may look into other 
details later this week or at the beginning of next week.


Uwe




Thanks,
H.



If you need further arguments for the discussion: I also tend to use
--no-vignettes nowadays if my code does not change considerably. ;-)

Best wishes,
Uwe




I hope the list of options/flags that we need to use to "fix" 'R CMD
build' (and make it consistent with R CMD INSTALL) is not going to
grow too much ;-)

Thanks,
H.







__
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel


  1   2   3   4   5   6   7   >