Tim Hesterberg
2012-Apr-08 18:37 UTC
[Rd] Add DUP = FALSE when tabulate() calls .C("R_tabulate"
In base/R/tabulate.R, tabulate() calls .C("R_tabulate"; I suggest adding DUP = FALSE to that call.
Prof Brian Ripley
2012-Apr-09 08:48 UTC
[Rd] Add DUP = FALSE when tabulate() calls .C("R_tabulate"
On 08/04/2012 19:37, Tim Hesterberg wrote:> In base/R/tabulate.R, tabulate() calls .C("R_tabulate"; > I suggest adding DUP = FALSE to that call.We can do that. Note that R-patched already does less copying[*], but adding DUP=FALSE may avoid one copy of 'dup' if it is an integer vector. We can avoid another for a factor .... [*] tracemem() is still reporting 'copies' that are not full duplications. -- Brian D. Ripley, ripley at stats.ox.ac.uk Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/ University of Oxford, Tel: +44 1865 272861 (self) 1 South Parks Road, +44 1865 272866 (PA) Oxford OX1 3TG, UK Fax: +44 1865 272595