Skip to content

knitr 1.49

Latest
Compare
Choose a tag to compare
@yihui yihui released this 08 Nov 14:03
· 3 commits to master since this release

NEW FEATURES

  • In-chunk references of the form <<label>> can be disabled via the chunk option ref.chunk = FALSE now (thanks, @jennybc @gadenbuie, #2360).

  • Added support for fig.alt for LaTeX output, i.e., using \includegraphics[alt={alt text}] (thanks, @capnrefsmmat, #2378).

  • The environment in which code chunks are evaluated can be changed by passing a custom environment to knit_global() now (thanks, @abhsarma, #2358).

BUG FIXES

  • In-chunk references of the form <<label>> should not be resolved if label is not found in the document (thanks, @jennybc @gadenbuie, #2360).

  • The chunk option autodep = TRUE stopped working due to a regression from #2321 (thanks, @heavywatal #2344, @atusy #2377).

  • asis_output() was not passed to the output hook (thanks, @cderv, #2332).

  • Avoid partial matching of the Date/Publication field when generating citation('knitr'), otherwise R will emit a warning when options(warnPartialMatchDollar = TRUE) (thanks, @fkohrt, #2361).

MAJOR CHANGES

  • Unbalanced chunk delimiters (fences) in R Markdown documents are strictly prohibited now.

  • For code chunks with error = TRUE, purl() and hook_purl() will wrap the code in try({...}) (thanks, @bastistician #2338, @jeroen #2368).

MINOR CHANGES

  • If a character value is passed to the chunk option message or warning, it will be coerced by as.logical(), e.g., a character string "NA" will be coerced to NA (thanks, @cderv, #2375).

  • Issue a warning when the chunk option dependson receives an invalid value (thanks, @otoomet, #2376).

  • Changed the format of the reference card from PDF to HTML so building this package will not require LaTeX. See vignette('knitr-refcard', package = 'knitr').

  • Switched the vignette engine from knitr to litedown::vignette for some package vignettes.