Skip to content

Commit 1557950

Browse files
aitapMichaelChirico
authored andcommitted
Fix code blocks in NEWS.md (#7518)
Add a missing triple-backtick separator. Separate the indented code blocks from the preceding paragraph because otherwise Pandoc fails to realise that the whitespace followed by triple-backtick denotes a fenced code block.
1 parent de5d118 commit 1557950

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

NEWS.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@
2626
2. `melt()` returns an integer column for `variable` when `measure.vars` is a list of length=1, consistent with the documented behavior, [#5209](https://github.com/Rdatatable/data.table/issues/5209). Thanks to @tdhock for reporting. Any users who were relying on this behavior can change `measure.vars=list("col_name")` (output `variable` was column name, now is column index/integer) to `measure.vars="col_name"` (`variable` still is column name). This change has been planned since 1.16.0 (25 Aug 2024).
2727

2828
3. Rolling functions `frollmean` and `frollsum` distinguish `Inf`/`-Inf` from `NA` to match the same rules as base R when `algo="fast"` (previously they were considered the same). If your input into those functions has `Inf` or `-Inf` then you will be affected by this change. As a result, the argument that controls the handling of `NA`s has been renamed from `hasNA` to `has.nf` (_has non-finite_). `hasNA` continues to work with a warning, for now.
29+
2930
```r
3031
## before
3132
frollsum(c(1,2,3,Inf,5,6), 2)
@@ -34,8 +35,10 @@
3435
## now
3536
frollsum(c(1,2,3,Inf,5,6), 2)
3637
#[1] NA 3 5 Inf Inf 11
38+
```
3739

3840
4. `frollapply` result is not coerced to numeric anymore. Users' code could possibly break if it depends on forced coercion of input/output to numeric type.
41+
3942
```r
4043
## before
4144
frollapply(c(F,T,F,F,F,T), 2, any)
@@ -45,6 +48,7 @@
4548
frollapply(c(F,T,F,F,F,T), 2, any)
4649
#[1] NA TRUE TRUE FALSE FALSE TRUE
4750
```
51+
4852
Additionally argument names in `frollapply` has been renamed from `x` to `X` and `n` to `N` to avoid conflicts with common argument names that may be passed to `...`, aligning to base R API of `lapply`. `x` and `n` continue to work with a warning, for now.
4953
5054
5. Negative and missing values of `n` argument of adaptive rolling functions trigger an error.
@@ -233,6 +237,7 @@ See [#2611](https://github.com/Rdatatable/data.table/issues/2611) for details. T
233237
```
234238

235239
18. New helper `frolladapt` to facilitate applying rolling functions over windows of fixed calendar-time width in irregularly-spaced data sets, thereby bypassing the need to "augment" such data with placeholder rows, [#3241](https://github.com/Rdatatable/data.table/issues/3241). Thanks to @jangorecki for implementation.
240+
236241
```r
237242
idx = as.Date("2025-09-05") + c(0,4,7,8,9,10,12,13,17)
238243
dt = data.table(index=idx, value=seq_along(idx))

0 commit comments

Comments
 (0)