Skip to content

Commit

Permalink
vbump 0.6.3, [skip vbump] (#726)
Browse files Browse the repository at this point in the history
* vbump 0.6.3, [skip vbump]

* update description

* Update DESCRIPTION

Signed-off-by: Davide Garolini <[email protected]>

* reorder NEWS entries

* avoid forcats

---------

Signed-off-by: Davide Garolini <[email protected]>
Co-authored-by: Davide Garolini <[email protected]>
  • Loading branch information
shajoezhu and Melkiades authored Aug 30, 2023
1 parent d398f5e commit 0a9e373
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 17 deletions.
13 changes: 9 additions & 4 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,13 +1,18 @@
Package: rtables
Title: Reporting Tables
Version: 0.6.2.9011
Version: 0.6.3
Date: 2023-08-29
Authors@R: c(
person("Gabriel", "Becker", , "[email protected]", role = c("aut", "cre")),
person("Gabriel", "Becker", , "[email protected]", role = "aut",
comment = "Original creator of the package"),
person("Adrian", "Waddell", , "[email protected]", role = "aut"),
person("Daniel", "Sabanés Bové", , "[email protected]", role = "ctb"),
person("Maximilian", "Mordig", , "[email protected]", role = "ctb"),
person("Davide", "Garolini", , "[email protected]", role = "ctb")
person("Davide", "Garolini", , "[email protected]", role = "ctb"),
person("Emily", "de la Rua", , "[email protected]", role = "ctb"),
person("Abinaya", "Yogasekaram", , "[email protected]", role = "ctb"),
person("Joe", "Zhu", , "[email protected]", role = c("ctb", "cre")),
person("F. Hoffmann-La Roche AG", role = c("cph", "fnd"))
)
Description: Reporting tables often have structure that goes beyond simple
rectangular data. The 'rtables' package provides a framework for
Expand All @@ -24,7 +29,7 @@ URL: https://github.com/insightsengineering/rtables,
https://insightsengineering.github.io/rtables/
BugReports: https://github.com/insightsengineering/rtables/issues
Depends:
formatters (>= 0.5.1.9002),
formatters (>= 0.5.2),
magrittr,
methods,
R (>= 2.10)
Expand Down
23 changes: 12 additions & 11 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,22 +1,23 @@
## rtables 0.6.2.9011
## rtables 0.6.3
### New Features
* Analysis functions (`cfun/afun`) can use new parameters to extend analysis calculations: `.alt_df_row` and `.alt_df` give access to `alt_counts_df` across columns, while `.all_col_exprs` and `.all_col_counts` contains global information about all columns.
* Binding objects via `rbind` will retain titles/footer information if identical in all objects or only present in the first object being bound.

### Enhancements
* Analysis functions (`cfun/afun`) have more information about current column split; `.spl_context` has access to `cur_col_id`, `cur_col_expr`, `cur_col_split`, and `cur_col_split_val`.
* Analysis functions (`cfun/afun`) can use new parameters to extend analysis calculations. `.alt_df_row` gives access to `alt_counts_df` across columns, while `.all_col_exprs` and `.all_col_counts` contains global information about all columns.
* Added `.alt_df` to have the exact same subset of `df` in `afun/cfun`.
* Added check for `.alt_df_row` that prevents its calculation if not present in analysis functions.
* Removed superfluous warning which arose for custom split functions when reference group is is set (https://github.com/insightsengineering/rtables/issues/707#issuecomment-1678810598)
* Binding objects via `rbind` will retain titles/footer information if identical in all objects or only present in the first object being bound.
* Added vignette on exploratory analysis with `qtable`.
* Extracted `qtable_layout` from `qtable`.

### Bug Fixes
* Page-by splits which generate zero facets (and thus tables which would have zero pages when rendered) now throw an informative error at table build time.
* Removed superfluous warning which arose for custom split functions when reference group is is set (https://github.com/insightsengineering/rtables/issues/707#issuecomment-1678810598).
* Fixed `qtable` labeling via `row_labels` ([#698](https://github.com/insightsengineering/rtables/issues/698)).
* Error catching and test coverage for cases where `alt_counts_df` presents different splits from `df`.

### Miscellaneous
* Cleaned up spelling in documentation ([#685](https://github.com/insightsengineering/rtables/issues/685))
* Custom appearance vignette updated with decimal alignment support.
* Alignment checks have been moved into `formatters`: `formatters::check_aligns` superseded internal function `chk_rtables_align` and `formatters::list_valid_aligns` superseded `rtables_aligns`.
* Page-by splits which generate zero facets (and thus tables which would have zero pages when rendered) now throw an informative error at table build time.
* Cleaned up spelling in documentation ([#685](https://github.com/insightsengineering/rtables/issues/685))
* Added `qtable_layout` and fixed `qtable` labeling via `row_labels` ([#698](https://github.com/insightsengineering/rtables/issues/698))
* Added vignette on exploratory analysis with `qtable`.
* Error catching and test coverage for cases where `alt_counts_df` presents different splits from `df`.

## rtables 0.6.2
* Fixed major regressions for `page_by` machinery caused by migration to `formatters` 0.5.1 pagination framework.
Expand Down
5 changes: 3 additions & 2 deletions vignettes/exploratory_analysis.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ the latter is done in the [Custom Aggregation] section.

```{r}
# Recode NA values
tmp_adsl[[1]] <- forcats::fct_na_value_to_level(tmp_adsl[[1]], level = "<NA>")
tmp_adsl[[1]] <- addNA(tmp_adsl[[1]])
qtable(tmp_adsl, row_vars = "ARM", col_vars = "SEX")
```
Expand All @@ -159,7 +159,8 @@ qtable(tmp_adsl, row_vars = "ARM", col_vars = "new1")
Explicitly labeling the `NA` levels in the column facet adds a column to the
table:
```{r}
tmp_adsl$new2 <- forcats::fct_na_value_to_level(tmp_adsl$new1, level = "<NA>")
tmp_adsl$new2 <- addNA(tmp_adsl$new1)
levels(tmp_adsl$new2)[4] <- "<NA>" # NA needs to be a recognizible string
qtable(tmp_adsl, row_vars = "ARM", col_vars = "new2")
```

Expand Down

0 comments on commit 0a9e373

Please sign in to comment.