por default
C:\Program Files\R\R-3.4.0
LENGUAJE DE PROGRAMACION R
https://cran.r-project.org/mirrors.html
NEWS | R Documentation |
If you want to double-check that the package you have downloaded matches the package distributed by CRAN, you can compare the md5sum of the .exe to the fingerprint on the master server. You will need a version of md5sum for windows: both graphical and command line versions are available.
Frequently asked questions
- Does R run under my version of Windows?
- How do I update packages in my previous version of R?
- Should I run 32-bit or 64-bit R?
Please see the R FAQ for general information about R and the R Windows FAQ for Windows-specific information.
Other builds
- Patches to this release are incorporated in the r-patched snapshot build.
- A build of the development version (which will eventually become the next major release of R) is available in the r-devel snapshot build.
- Previous releases
Note to webmasters: A stable link which will redirect to the current Windows binary release is
<CRAN MIRROR>/bin/windows/base/release.htm.
R News
CHANGES IN R 3.4.0
SIGNIFICANT USER-VISIBLE CHANGES
- (Unix-alike) The default methods for
download.file()
andurl()
now choose"libcurl"
except for file:// URLs. There will be small changes in the format and wording of messages, including in rare cases if an issue is a warning or an error. For example, when HTTP re-direction occurs, some messages refer to the final URL rather than the specified one.
Those who use proxies should check that their settings are compatible (see?download.file
: the most commonly used forms work for both"internal"
and"libcurl"
). table()
has been amended to be more internally consistent and become back compatible to R <= 2.7.2 again. Consequently,table(1:2, exclude = NULL)
no longer contains a zero count for<NA>
, butuseNA = "always"
continues to do so.summary.default()
no longer rounds, but its print method does resulting in less extraneous rounding, notably of numbers in the ten thousands.factor(x, exclude = L)
behaves more rationally whenx
orL
are character vectors. Further,exclude = <factor>
now behaves as documented for long.- Arithmetic, logic (
&
,|
) and comparison (aka ‘relational’, e.g.,<
,==
) operations with arrays now behave consistently, notably for arrays of length zero.
Arithmetic between length-1 arrays and longer non-arrays had silently dropped the array attributes and recycled. This now gives a warning and will signal an error in the future, as it has always for logic and comparison operations in these cases (e.g., comparematrix(1,1) + 2:3
andmatrix(1,1) < 2:3
). - The JIT (‘Just In Time’) byte-code compiler is now enabled by default at its level 3. This means functions will be compiled on first or second use and top-level loops will be compiled and then run. (Thanks to Tomas Kalibera for extensive work to make this possible.)
For now, the compiler will not compile code containing explicit calls tobrowser()
: this is to support single stepping from thebrowser()
call.
JIT compilation can be disabled for the rest of the session usingcompiler::enableJIT(0)
or by setting environment variable R_ENABLE_JIT to0
. xtabs()
works more consistently withNA
s, also in its result no longer setting them to0
. Further, a new logical optionaddNA
allows to countNA
s where appropriate. Additionally, for the casesparse = TRUE
, the result'sdimnames
are identical to the default case's.- Matrix products now consistently bypass BLAS when the inputs have
NaN
/Inf
values. Performance of the check of inputs has been improved. Performance when BLAS is used is improved for matrix/vector and vector/matrix multiplication (DGEMV is now used instead of DGEMM).
One can now choose from alternative matrix product implementations viaoptions(matprod = )
. The"internal"
implementation is not optimized for speed but consistent in precision with other summations in R (usinglong double
accumulators where available)."blas"
calls BLAS directly for best speed, but usually with undefined behavior for inputs withNaN
/Inf
. factor()
now usesorder()
to sort its levels, notsort.list()
. This makesfactor()
support custom vector-like objects if methods for the appropriate generics are defined. This change has the side effect of makingfactor()
succeed on empty or length-one non-atomic vector(-like) types (e.g., list), where it failed before.
NEW FEATURES
- User errors such as
integrate(f, 0:1, 2)
are now caught. - Add
signature
argument todebug()
,debugonce()
,undebug()
andisdebugged()
for more conveniently debugging S3 and S4 methods. (Based on a patch by Gabe Becker.) - Add
utils::debugcall()
andutils::undebugcall()
for debugging the function that would be called by evaluating the given expression. When the call is to an S4 generic or standard S3 generic,debugcall()
debugs the method that would be dispatched. A number of internal utilities were added to support this, most notablyutils::isS3stdGeneric()
. (Based on a patch by Gabe Becker.) - Add
utils::strcapture()
. Given a character vector and a regular expression containing capture expressions,strcapture()
will extract the captured tokens into a tabular data structure, typically adata.frame
. str()
andstrOptions()
get a new optiondrop.deparse.attr
with improved but changed default behaviour for expressions. Forexpression
objectsx
,str(x)
now may remove extraneous white space and truncate long lines.str(<looooooooong_string>)
is no longer very slow; inspired by Mikko Korpela's proposal in PR#16527.str(x)
's default method is more “accurate” and hence somewhat more generous in displaying character vectors; this will occasionally change R outputs (and need changes to some ‘*.Rout(.save)’ files).
For a classed integer vector such asx <- xtabs(~ c(1,9,9,9))
,str(x)
now shows both the class and"int"
, instead of only the latter.isSymmetric(m)
is much faster for large asymmetric matricesm
via pre-tests and a new optiontol1
(with which strict back compatibility is possible but not the default).- The result of
eigen()
now is of class"eigen"
in the default case when eigenvectors are computed. - Zero-length date and date-time objects (of classes
"POSIX[cl]?t"
) nowprint()
“recognizably”. xy.coords()
andxyz.coords()
get a newsetLab
option.- The
method
argument ofsort.list()
,order()
andsort.int()
gains an"auto"
option (the default) which should behave the same as before whenmethod
was not supplied. stopifnot(E, ..)
now reports differences whenE
is a call toall.equal()
and that is not true.boxplot(<formula>, *)
gain optional argumentsdrop
,sep
, andlex.order
to pass tosplit.default()
which itself gains an argumentlex.order
to pass tointeraction()
for more flexibility.- The
plot()
method forppr()
has enhanced default labels (xmin
andmain
). sample.int()
gains an explicituseHash
option (with a back compatible default).identical()
gains anignore.srcref
option which drops"srcref"
and similar attributes when true (as by default).diag(x, nrow = n)
now preservestypeof(x)
, also for logical, integer and rawx
(and as previously for complex and numeric).smooth.spline()
now allows direct specification oflambda
, gets ahatvalues()
method and keepstol
in the result, and optionally parts of the internal matrix computations.addNA()
is faster now, e.g. when applied twice. (Part of PR#16895.)- New option
rstandard(<lm>, type = "predicted")
provides the “PRESS”–related leave-one-out cross-validation errors for linear models. - After seven years of deprecation, duplicated factor levels now produce a warning when printed and an error in
levels<-
instead of a warning. - Invalid factors, e.g., with duplicated levels (invalid but constructable) now give a warning when printed, via new function
.valid.factor()
. sessionInfo()
has been updated for Apple's change in OS naming as from ‘10.12’ (‘macOS Sierra’ vs ‘OS X El Capitan’).
ItstoLatex()
method now includes therunning
component.options(interrupt=)
can be used to specify a default action for user interrupts. For now, if this option is not set and theerror
option is set, then an unhandled user interrupt invokes theerror
option. (This may be dropped in the future asinterrupt
conditions are noterror
conditions.)- In most cases user interrupt handlers will be called with a
"resume"
restart available. Handlers can invoke this restart to resume computation. At the browser prompt ther
command will invoke a"resume"
restart if one is available. Some read operations cannot be resumed properly when interrupted and do not provide a"resume"
restart. - Radix sort is now chosen by
method = "auto"
forsort.int()
for double vectors (and hence used forsort()
for unclassed double vectors), excluding ‘long’ vectors.
sort.int(method = "radix")
no longer rounds double vectors. - The
default
anddata.frame
methods forstack()
preserve the names of empty elements in the levels of theind
column of the return value. Set the newdrop
argument toTRUE
for the previous behavior. - Speedup in
simplify2array()
and hencesapply()
andmapply()
(for the case of names and common length > 1), thanks to Suharto Anggono's PR#17118. table(x, exclude = NULL)
now setsuseNA = "ifany"
(instead of"always"
). Together with the bug fixes for this case, this recovers more consistent behaviour compatible to older versions of R. As a consequence,summary()
for a logical vector no longer reports (zero) counts forNA
when there are noNA
s.dump.frames()
gets a new optioninclude.GlobalEnv
which allows to also dump the global environment, thanks to Andreas Kersting's proposal in PR#17116.system.time()
now usesmessage()
instead ofcat()
when terminated early, such thatsuppressMessages()
has an effect; suggested by Ben Bolker.citation()
supports ‘inst/CITATION’ files from package source trees, withlib.loc
pointing to the directory containing the package.try()
gains a new argumentoutFile
with a default that can be modified viaoptions(try.outFile = .)
, useful notably forSweave
.- The unexported low-level functions in package parallel for passing serialized R objects to and from forked children now support long vectors on 64-bit platforms. This removes some limits on higher-level functions such as
mclapply()
(but returning gigabyte results from forked processes via serialization should be avoided if at all possible). - Connections now
print()
without error even if invalid, e.g. after having been destroyed. apropos()
andfind(simple.words = FALSE)
no longer match object names starting with . which are known to be internal objects (such as.__S3MethodsTable__.
).- Convenience function
hasName()
has been added; it is intended to replace the common idiom!is.null(x$name)
without the usually unintended partial name matching. strcapture()
no longer fixes column names nor coerces strings to factors (suggested by Bill Dunlap).strcapture()
returnsNA
for non-matching values inx
(suggested by Bill Dunlap).source()
gets new optional arguments, notablyexprs
; this is made use of in the new utility functionwithAutoprint()
.sys.source()
gets a newtoplevel.env
argument. This argument is useful for frameworks running package tests; contributed by Tomas Kalibera.Sys.setFileTime()
andfile.copy(copy.date = TRUE)
will set timestamps with fractions of seconds on platforms/filesystems which support this.- (Windows only.)
file.info()
now returns file timestamps including fractions of seconds; it has done so on other platforms since R 2.14.0. (NB: some filesystems do not record modification and access timestamps to sub-second resolution.) - The license check enabled by
options(checkPackageLicense = TRUE)
is now done when the package's namespace is first loaded. ppr()
andsupsmu()
get an optionaltrace
argument, andppr(.., sm.method = ..spline)
is no longer limited to sample size n <= 2500.- The
POSIXct
method forprint()
gets optionaltz
andusetz
arguments, thanks to a report from Jennifer S. Lyon. - New function
check_packages_in_dir_details()
in package tools for analyzing package-check log files to obtain check details. - Package tools now exports function
CRAN_package_db()
for obtaining information about current packages in the CRAN package repository, and several functions for obtaining the check status of these packages. - The (default) Stangle driver
Rtangle
allowsannotate
to be a function and gets a newdrop.evalFALSE
option. - The default method for
quantile(x, prob)
should now be monotone inprob
, even in border cases, see PR#16672. bug.report()
now tries to extract an email address from a BugReports field, and if there is none, from a Contacts field.- The
format()
andprint()
methods forobject.size()
results get new optionsstandard
anddigits
; notably,standard = "IEC"
andstandard = "SI"
allow more standard (but less common) abbreviations than the default ones, e.g. for kilobytes. (From contributions by Henrik Bengtsson.) - If a reference class has a validity method,
validObject
will be called automatically from the default initialization method for reference classes. tapply()
gets new optiondefault = NA
allowing to change the previously hardcoded value.read.dcf()
now consistently interprets any ‘whitespace’ to be stripped to include newlines.- The maximum number of DLLs that can be loaded into R e.g. via
dyn.load()
can now be increased by setting the environment variableR_MAX_NUM_DLLS
before starting R. - Assigning to an element of a vector beyond the current length now over-allocates by a small fraction. The new vector is marked internally as growable, and the true length of the new vector is stored in the
truelength
field. This makes building up a vector result by assigning to the next element beyond the current length more efficient, though pre-allocating is still preferred. The implementation is subject to change and not intended to be used in packages at this time. - Loading the parallel package namespace no longer sets or changes the
.Random.seed
, even if R_PARALLEL_PORT is unset.
NB: This can break reproducibility of output, and did for a CRAN package. - Methods
"wget"
and"curl"
fordownload.file()
now give an R error rather than a non-zero return value when the external command has a non-zero status. - Encoding name
"utf8"
is mapped to"UTF-8"
. Many implementations oficonv
accept"utf8"
, but not GNU libiconv (including the late 2016 version 1.15). sessionInfo()
shows the full paths to the library or executable files providing the BLAS/LAPACK implementations currently in use (not available on Windows).- The binning algorithm used by bandwidth selectors
bw.ucv()
,bw.bcv()
andbw.SJ()
switches to a version linear in the input sizen
forn > nb/2
. (The calculations are the same, but for largern/nb
it is worth doing the binning in advance.) - There is a new option
PCRE_study
which controls whengrep(perl = TRUE)
and friends ‘study’ the compiled pattern. Previously this was done for 11 or more input strings: it now defaults to 10 or more (but most examples need many more for the difference from studying to be noticeable). grep(perl = TRUE)
and friends can now make use of PCRE's Just-In-Time mechanism, for PCRE >= 8.20 on platforms where JIT is supported. It is used by default whenever thepattern
is studied (see the previous item). (Based on a patch from Mikko Korpela.)
This is controlled by a new optionPCRE_use_JIT
.
Note that in general this makes little difference to the speed, and may take a little longer: its benefits are most evident on strings of thousands of characters. As a side effect it reduces the chances of C stack overflow in the PCRE library on very long strings (millions of characters, but see next item).
Warning: segfaults were seen using PCRE with JIT enabled on 64-bit Sparc builds.- There is a new option
PCRE_limit_recursion
forgrep(perl = TRUE)
and friends to set a recursion limit taking into account R's estimate of the remaining C stack space (or 10000 if that is not available). This reduces the chance of C stack overflow, but because it is conservative may report a non-match (with a warning) in examples that matched before. By default it is enabled if any input string has 1000 or more bytes. (PR#16757) getGraphicsEvent()
now works onX11(type = "cairo")
devices. Thanks to Frederick Eaton (for reviving an earlier patch).- There is a new argument
onIdle
forgetGraphicsEvent()
, which allows an R function to be run whenever there are no pending graphics events. This is currently only supported on X11 devices. Thanks to Frederick Eaton. - The
deriv()
and similar functions now can compute derivatives oflog1p()
,sinpi()
and similar one-argument functions, thanks to a contribution by Jerry Lewis. median()
gains a formal...
argument, so methods with extra arguments can be provided.strwrap()
reducesindent
if it is more than halfwidth
rather than giving an error. (Suggested by Bill Dunlap.)- When the condition
code
inif(.)
orwhile(.)
is not of length one, an error instead of a warning may be triggered by setting an environment variable, see the help page. - Formatting and printing of bibliography entries (
bibentry
) is more flexible and better documented. Apart from settingoptions(citation.bibtex.max = 99)
you can also useprint(<citation>, bibtex=TRUE)
(orformat(..)
) to get the BibTeX entries in the case of more than one entry. This also affectscitation()
. Contributions to enablestyle = "html+bibtex"
are welcome.
No hay comentarios:
Publicar un comentario