Re: [Rd] False positives in check for lost braces (in tools::checkRd())

2023-11-07 Thread Martin Becker
you very much, so I don't have to wait for the release of the new version of Rdpack on CRAN before submitting. Best regards, Martin -- apl. Prof. Dr. Martin Becker, Akad. Oberrat Lehrstab Statistik Quantitative Methoden Fakultät für Empirische Humanwissenschaften und Wirtschaftswissenschaft Univer

Re: [Rd] False positives in check for lost braces (in tools::checkRd())

2023-11-07 Thread Martin Becker
Am 07.11.23 um 23:00 schrieb Ivan Krylov: On Tue, 7 Nov 2023 17:13:05 +0100 Martin Becker wrote: More specifically, a 'Lost braces' NOTE is issued (at least sometimes) when using the \insertRef{...}{...} command from the Rdpack package. Does anything change if you use the development

[Rd] False positives in check for lost braces (in tools::checkRd())

2023-11-07 Thread Martin Becker
. Best regards and many thanks, Martin -- apl. Prof. Dr. Martin Becker, Akad. Oberrat Lehrstab Statistik Quantitative Methoden Fakultät für Empirische Humanwissenschaften und Wirtschaftswissenschaft Universität des Saarlandes Campus C3 1, Raum 2.17 66123 Saarbrücken Deutschland

Re: [Rd] feature request: optim() iteration of functions that return multiple values

2023-08-05 Thread Martin Becker
For a solution that does not require any change to the original function being optimized, the following one-liner could be used, which converts existing functions to functions that return only the first element: returnFirst <- function(fun) function(...) do.call(fun,list(...))[[1]] Example:

Re: [Rd] Request: Suggestions for good teaching packages, esp. with C code

2011-02-16 Thread Martin Becker
. Martin -- Dr. Martin Becker Statistics and Econometrics Saarland University Campus C3 1, Room 217 66123 Saarbruecken Germany __ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel

Re: [Rd] Request: Suggestions for good teaching packages, esp. with C code

2011-02-16 Thread Martin Becker
return() is intended to work. Best, luke On Wed, 16 Feb 2011, Duncan Murdoch wrote: On 11-02-16 7:31 AM, Martin Becker wrote: On 15.02.2011 22:48, David Scott wrote: On 16/02/2011 7:04 a.m., Paul Johnson wrote: ... 4. We don't want gratuitous use of return at the end of functions. Why do people

Re: [Rd] hist.default()$density

2010-04-09 Thread Martin Becker
= dens, Martin Becker wrote: Dear developers, the current implementation of hist.default() calculates 'density' (and 'intensities') as dens - counts/(n*h) where h has been calculated before as h - diff(fuzzybreaks) which results in 'fuzzy' values for the density, see e.g. tmp - hist(1:10

[Rd] hist.default()$density

2010-03-30 Thread Martin Becker
*diff(tmp$breaks)),digits=15) [1] 0.9996008 Is this intended, or should the calculation of dens read dens - counts/(n*diff(breaks)) instead (or should hist.default()$breaks return the fuzzy breaks)? Best wishes Martin -- Dr. Martin Becker Statistics and Econometrics Saarland University

Re: [Rd] Problem with gsl package

2010-02-28 Thread Martin Becker
OF THE ERROR BY RETURN E-MAIL AND DELETE THIS MESSAGE FROM YOUR SYSTEM. Thank you for your cooperation. [[alternative HTML version deleted]] __ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel -- Dr. Martin Becker

[Rd] suggestion: tiny documentation improvement for R-admin

2010-02-17 Thread Martin Becker
it would be favourable to note this already in subsection 3.1.2, where the first 'make' commands pop up. Please find attached a corresponding patch for rev. 51148. Thanks, Martin -- Dr. Martin Becker Statistics and Econometrics Saarland University Campus C3 1, Room 206 66123 Saarbruecken Germany

[Rd] tiny typo in translation (src/library/tools/po/R-de.po)

2010-02-08 Thread Martin Becker
. Martin Becker Statistics and Econometrics Saarland University Campus C3 1, Room 206 66123 Saarbruecken Germany Index: src/library/tools/po/R-de.po === --- src/library/tools/po/R-de.po(revision 51109) +++ src/library/tools/po/R

Re: [Rd] RFC: lchoose() vs lfactorial() etc

2009-12-15 Thread Martin Becker
Robin Hankin wrote: ... Is this the place to discuss having complex arguments for gamma()? ... If this discussion starts I would second the wish for the functionality of gsl's lngamma_complex in base R. Best wishes Martin -- Dr. Martin Becker Statistics and Econometrics Saarland University

Re: [Rd] Strange code in `?`

2009-11-03 Thread Martin Becker
for any inconvenience.\n) We now got jokes in R code? Why not? ;-) Best, Philippe -- Dr. Martin Becker Statistics and Econometrics Saarland University Campus C3 1, Room 206 66123 Saarbruecken Germany __ R-devel@r-project.org mailing list https

Re: [Rd] Sweave output encoding in R-2.10.0beta on Windows (Rgui - Rterm)

2009-10-19 Thread Martin Becker
of Rgui and Rterm in R-2.10.0rc). It would be great if someone more involved in Sweave could take a look at (and maybe commit) the attached (untested!) patch (to r50160). Many thanks in advance! Best wishes, Martin Martin Becker wrote: Dear developers, I have come across a (somewhat strange

[Rd] Sweave output encoding in R-2.10.0beta on Windows (Rgui - Rterm)

2009-10-13 Thread Martin Becker
base -- Dr. Martin Becker Statistics and Econometrics Saarland University Campus C3 1, Room 206 66123 Saarbruecken Germany \documentclass{article} \usepackage{c:/Programme/R/R-2.10.0beta/share/texmf/Sweave} \usepackage[latin1]{inputenc} %\usepackage[utf8x]{inputenc} \usepackage[german]{babel

Re: [Rd] Sweave output encoding in R-2.10.0beta on Windows (Rgui - Rterm)

2009-10-13 Thread Martin Becker
wishes, Martin Martin Becker wrote: Dear developers, I have come across a (somewhat strange) change in the encoding of Sweave output from R-2.9.2pat to R-2.10.0beta (apparently specific to Rgui) on Windows installations. Of course, the NEWS file contains quite a few changes concerning

[Rd] creating environments in package's C code

2009-10-01 Thread Martin Becker
Dear developers, is it possible to create environments in C code of packages? Simply using SEXP env; PROTECT (env = allocSExp(ENVSXP)); and assigning the enclosing environment with SET_ENCLOS seems to be insufficient. Best wishes, Martin -- Dr. Martin Becker Statistics and Econometrics

Re: [Rd] Inaccurate complex arithmetic of R (Matlab is accurate)

2009-08-04 Thread Martin Becker
/agingandhealth/People/Faculty_personal_pages/Varadhan.h tml -Original Message- From: Martin Becker [mailto:martin.bec...@mx.uni-saarland.de] Sent: Monday, August 03, 2009 5:50 AM To: Ravi Varadhan Cc

Re: [Rd] Inaccurate complex arithmetic of R (Matlab is accurate)

2009-08-03 Thread Martin Becker
/mailman/listinfo/r-devel -- Dr. Martin Becker Statistics and Econometrics Saarland University Campus C3 1, Room 206 66123 Saarbruecken Germany __ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel

[Rd] how to change FPU control word?

2009-07-27 Thread Martin Becker
hope, there is already a better solution. Any hints appreciated! Thanks, Martin -- Dr. Martin Becker Statistics and Econometrics Saarland University Campus C3 1, Room 206 66123 Saarbruecken Germany __ R-devel@r-project.org mailing list https

[Rd] Small bug in axis.POSIXct

2008-12-01 Thread Martin Becker
the attached patch (for revision 47031). Best wishes, Martin -- Dr. Martin Becker Statistics and Econometrics Saarland University Campus C3 1, Room 206 66123 Saarbruecken Germany diff -u --recursive trunk.orig/src/library/graphics/R/datetime.R trunk/src/library/graphics/R/datetime.R --- trunk.orig/src

Re: [Rd] pnorm

2008-02-07 Thread Martin Becker
I guess that you destroy the accuracy of the calculation by the subtraction. Try 2*(pnorm(8.104474,lower=FALSE)) instead, which results in 5.29742e-16 for me. Regards, Martin jing hua zhao schrieb: Dear R list, I calculated a two-sided p values according to 2*(1-pnorm(8.104474)),

[Rd] Possible bug in cut.Date()

2006-12-20 Thread Martin Becker
Dear list, I suppose that the behaviour of cut.Date() is not as intended for the case ' breaks=year ' (in R 2.4.1 and previous versions): The corresponding code fragment which defines the first breakpoint in this case reads: if (valid == 4) { start$mon - 0 incr

Re: [Rd] Speed of runif() on different Operating Systems

2006-08-30 Thread Martin Becker
Duncan Murdoch schrieb: McLeish published algorithms to simulate these directly in a recent issue of CJS. I don't have the reference handy, but I think it's 2004 or 2005. Duncan Murdoch Thank you for this reference, I think it is the 2002 article *Highs and lows: Some properties of the

[Rd] Speed of runif() on different Operating Systems

2006-08-28 Thread Martin Becker
() instead of Sys.time()-differences yields similar results. Any hint is appreciated, please let me know, if the given information on system/OS or the R output below is not sufficient. Regards, Martin Becker R - Output below Windows XP