The ‘Changes in R’ article from the 2015-2 issue.
CHANGES IN R 3.2.3
NEW FEATURES
Some recently-added Windows time zone names have been added to the conversion table used to convert these to Olson names. (Including those relating to changes for Russia in Oct 2014, as in PR#16503.)
(Windows) Compatibility information has been added to the manifests
for Rgui.exe, Rterm.exe and Rscript.exe. This should allow
win.version() and Sys.info() to report the actual Windows
version up to Windows 10.
Windows "wininet" FTP first tries EPSV / PASV mode rather than
only using active mode (reported by Dan Tenenbaum).
which.min(x) and which.max(x) may be much faster for logical and
integer x and now also work for long vectors.
The ‘emulation’ part of tools::texi2dvi() has been somewhat
enhanced, including supporting quiet = TRUE. It can be selected by
texi2dvi = "emulation".
(Windows) MiKTeX removed its texi2dvi.exe command in Sept 2015:
tools::texi2dvi() tries texify.exe if it is not found.
(Windows only) Shortcuts for printing and saving have been added to
menus in Rgui.exe. (Request of PR#16572.)
loess(..., iterTrace=TRUE) now provides diagnostics for robustness
iterations, and the print() method for summary(<loess>) shows
slightly more.
The included version of PCRE has been updated to 8.38, a bug-fix release.
View() now displays nested data frames in a more friendly way.
(Request with patch in PR#15915.)
INSTALLATION and INCLUDED SOFTWARE
The included configuration code for libintl has been updated to
that from gettext version 0.19.5.1 — this should only affect how
an external library is detected (and the only known instance is
under OpenBSD). (Wish of PR#16464.)
configure has a new argument –disable-java to disable the checks
for Java.
The configure default for MAIN_LDFLAGS has been changed for the
FreeBSD, NetBSD and Hurd OSes to one more likely to work with
compilers other than gcc (FreeBSD 10 defaults to clang).
configure now supports the OpenMP flags -fopenmp=libomp (clang)
and -qopenmp (Intel C).
Various macros can be set to override the default behaviour of
configure when detecting OpenMP: see file config.site.
Source installation on Windows has been modified to allow for MiKTeX
installations without texi2dvi.exe. See file MkRules.dist.
BUG FIXES
regexpr(pat, x, perl = TRUE) with Python-style named capture did
not work correctly when x contained NA strings. (PR#16484)
The description of dataset ToothGrowth has been
improved/corrected. (PR#15953)
model.tables(type = "means") and hence TukeyHSD() now support
"aov" fits without an intercept term. (PR#16437)
close() now reports the status of a pipe() connection opened
with an explicit open argument. (PR#16481)
Coercing a list without names to a data frame is faster if the elements are very long. (PR#16467)
(Unix-only) Under some rare circumstances piping the output from
Rscript or R -f could result in attempting to close the input
file twice, possibly crashing the process. (PR#16500)
(Windows) Sys.info() was out of step with win.version() and did
not report Windows 8.
topenv(baseenv()) returns baseenv() again as in R 3.1.0 and
earlier. This also fixes compilerJIT(3) when used in .Rprofile.
detach()ing the methods package keeps .isMethodsDispatchOn()
true, as long as the methods namespace is not unloaded.
Removed some spurious warnings from configure about the
preprocessor not finding header files. (PR#15989)
rchisq(*, df=0, ncp=0) now returns 0 instead of NaN, and
dchisq(*, df=0, ncp=*) also no longer returns NaN in limit cases
(where the limit is unique). (PR#16521)
pchisq(*, df=0, ncp > 0, log.p=TRUE) no longer underflows (for ncp
> ~60).
nchar(x, "w") returned -1 for characters it did not know about
(e.g. zero-width spaces): it now assumes 1. It now knows about most
zero-width characters and a few more double-width characters.
Help for which.min() is now more precise about behavior with
logical arguments. (PR#16532)
The print width of character strings marked as "latin1" or
"bytes" was in some cases computed incorrectly.
abbreviate() did not give names to the return value if minlength
was zero, unlike when it was positive.
(Windows only) dir.create() did not always warn when it failed to
create a directory. (PR#16537)
When operating in a non-UTF-8 multibyte locale (e.g. an East Asian
locale on Windows), grep() and related functions did not handle
UTF-8 strings properly. (PR#16264)
read.dcf() sometimes misread lines longer than 8191 characters.
(Reported by Hervé Pagès with a patch.)
within(df, ..) no longer drops columns whose name start with a
".".
The built-in HTTP server converted entire Content-Type to
lowercase including parameters which can cause issues for multi-part
form boundaries (PR#16541).
Modifying slots of S4 objects could fail when the methods package was not attached. (PR#16545)
splineDesign(*, outer.ok=TRUE) (splines) is better now
(PR#16549), and interpSpline() now allows sparse=TRUE for
speedup with non-small sizes.
If the expression in the traceback was too long, traceback() did
not report the source line number. (Patch by Kirill Müller.)
The browser did not truncate the display of the function when
exiting with options("deparse.max.lines") set. (PR#16581)
When bs(*, Boundary.knots=) had boundary knots inside the data
range, extrapolation was somewhat off. (Patch by Trevor Hastie.)
var() and hence sd() warn about factor arguments which are
deprecated now. (PR#16564)
loess(*, weights = *) stored wrong weights and hence gave slightly
wrong predictions for newdata. (PR#16587)
aperm(a, *) now preserves names(dim(a)).
poly(x, ..) now works when either raw=TRUE or coef is
specified. (PR#16597)
data(package=*) is more careful in determining the path.
prettyNum(*, decimal.mark, big.mark): fixed bug introduced when
fixing PR#16411.
CHANGES IN R 3.2.2
SIGNIFICANT USER-VISIBLE CHANGES
It is now easier to use secure downloads from https:// URLs on
builds which support them: no longer do non-default options need to
be selected to do so. In particular, packages can be installed from
repositories which offer https:// URLs, and those listed by
setRepositories() now do so (for some of their mirrors).
Support for https:// URLs is available on Windows, and on other
platforms if support for libcurl was compiled in and if that
supports the https protocol (system installations can be expected
to do). So https:// support can be expected except on rather old
OSes (an example being OS X ‘Snow Leopard’, where a non-system
version of libcurl can be used).
(Windows only) The default method for accessing URLs via
download.file() and url() has been changed to be "wininet"
using Windows API calls. This changes the way proxies need to be set
and security settings made: there have been some reports of ftp:
sites being inaccessible under the new default method (but the
previous methods remain available).
NEW FEATURES
cmdscale() gets new option list. for increased flexibility when
a list should be returned.
configure now supports texinfo version 6.0, which (unlike the
change from 4.x to 5.0) is a minor update. (Wish of PR#16456.)
(Non-Windows only) download.file() with default method = "auto"
now chooses "libcurl" if that is available and a https:// or
ftps:// URL is used.
(Windows only) setInternet2(TRUE) is now the default. The
command-line option –internet2 and environment variable
R_WIN_INTERNET2 are now ignored.
Thus by default the "internal" method for download.file() and
url() uses the "wininet" method: to revert to the previous
default use setInternet2(FALSE).
This means that https:// URLs can be read by default by
download.file() (they have been readable by file() and url()
since R 3.2.0).
There are implications for how proxies need to be set (see
?download.file).
chooseCRANmirror() and chooseBioCmirror() now offer HTTPS
mirrors in preference to HTTP mirrors. This changes the
interpretation of their ind arguments: see their help pages.
capture.output() gets optional arguments type and split to
pass to sink(), and hence can be used to capture messages.
C-LEVEL FACILITIES
Rconfig.h now defines HAVE_ALLOCA_H if the platform has
the alloca.h header (it is needed to define alloca on Solaris
and AIX, at least: see ‘Writing R Extensions’ for how to use it).INSTALLATION and INCLUDED SOFTWARE
libtool script generated by configure has been modified to
support FreeBSD >= 10 (PR#16410).BUG FIXES
The HTML help page links to demo code failed due to a change in R 3.2.0. (PR#16432)
If the na.action argument was used in model.frame(), the
original data could be modified. (PR#16436)
getGraphicsEvent() could cause a crash if a graphics window was
closed while it was in use. (PR#16438)
matrix(x, nr, nc, byrow = TRUE) failed if x was an object of
type "expression".
strptime() could overflow the allocated storage on the C stack
when the timezone had a non-standard format much longer than the
standard formats. (Part of PR#16328.)
options(OutDec = s) now signals a warning (which will become an
error in the future) when s is not a string with exactly one
character, as that has been a documented requirement.
prettyNum() gains a new option input.d.mark which together with
other changes, e.g., the default for decimal.mark, fixes some
format()ting variants with non-default getOption("OutDec") such
as in PR#16411.
download.packages() failed for type equal to either "both" or
"binary". (Reported by Dan Tenenbaum.)
The dendrogram method of labels() is much more efficient for
large dendrograms, now using rapply(). (Comment #15 of PR#15215)
The "port" algorithm of nls() could give spurious errors.
(Reported by Radford Neal.)
Reference classes that inherited from reference classes in another
package could invalidate methods of the inherited class. Fixing this
requires adding the ability for methods to be “external”, with the
object supplied explicitly as the first argument, named .self. See
"Inter-Package Superclasses" in the documentation.
readBin() could fail on the SPARC architecture due to alignment
issues. (Reported by Radford Neal.)
qt(*, df=Inf, ncp=.) now uses the natural qnorm() limit instead
of returning NaN. (PR#16475)
Auto-printing of S3 and S4 values now searches for print() in the
base namespace and show() in the methods namespace instead of
searching the global environment.
polym() gains a coefs = NULL argument and returns class "poly"
just like poly() which gets a new simple=FALSE option. They now
lead to correct predict()ions, e.g., on subsets of the original
data.
rhyper(nn, <large>) now works correctly. (PR#16489)
ttkimage() did not (and could not) work so was removed. Ditto for
tkimage.cget() and tkimage.configure(). Added two Ttk widgets
and missing subcommands for Tk’s image command: ttkscale(),
ttkspinbox(), tkimage.delete(), tkimage.height(),
tkimage.inuse(), tkimage.type(), tkimage.types(),
tkimage.width(). (PR#15372, PR#16450)
getClass("foo") now also returns a class definition when it is
found in the cache more than once.
Text and figures are licensed under Creative Commons Attribution CC BY 4.0. The figures that have been reused from other sources don't fall under this license and can be recognized by a note in their caption: "Figure from ...".
For attribution, please cite this work as
Team, "Changes in R", The R Journal, 2015
BibTeX citation
@article{RJ-2015-2-r-changes,
author = {Team, The R Core},
title = {Changes in R},
journal = {The R Journal},
year = {2015},
note = {https://journal.r-project.org/news/RJ-2015-2-r-changes},
volume = {7},
issue = {2},
issn = {2073-4859},
pages = {293-297}
}