|
1 |
| -# gt (development version) |
| 1 | +# gt 0.11.0 |
2 | 2 |
|
3 |
| -* `summary_rows()` now throws a more informative error message that you should use `grand_summary_rows()` if no row groups are detected (@olivroy, #1292). |
4 |
| - This change was introduced in [gt 0.9.0](https://posit.co/blog/big-changes-to-making-summary-rows-in-gt-0-9-0/) |
5 |
| -* gt now depends on R 3.6 (@olivroy, #1731). |
| 3 | +## New features |
| 4 | + |
| 5 | +* **gt** tables can now be rendered in the grid graphics system with the new `as_gtable()` function (#180, #420, #509, #961, #1652, #1701). Thank you @teunbrand for this valuable contribution! (#1563, #1648, #1655, #1727) |
| 6 | + |
| 7 | +* With the new `fmt_chem()` function, it's possible to format chemical formulas and chemical equations in the table body. (#1636) |
| 8 | + |
| 9 | +* We added `fmt_email()` we can transform email addresses in table cells into usable 'mailto:' links. This operates similarly to `fmt_url()` but removes some unneeded anchor tag attributes (#1616). (#1649) |
| 10 | + |
| 11 | +* The new `fmt_tf()` function lets you format logical values in a **gt** table. You could express these as a 'yes' or 'no', a 'true' or 'false', or, perhaps use pairings of complementary symbols that make sense in a table (#1650). (#1654) |
| 12 | + |
| 13 | +* The new `fmt_country()` was added to help with making country names consistent and localizable. The input text can either consist of 2- or 3-letter ISO 3166-1 country codes. (#1645, #1696) |
| 14 | + |
| 15 | +* Math formulas (written in LaTeX) can now be rendered to HTML through `md()` and `fmt_markdown()`. The LaTeX formulas can be set between `$` or `$$` delimiters for inline and block rendering styles. While this requires the **katex** package to work (it's an optional dependency), the rendering of formulas is dependency-free in the output (#375, #616, #1163). (#1578) |
| 16 | + |
| 17 | +* We added the `unit_conversion()` helper function to help you perform unit conversions. This function returns a conversion factor for transforming a value from one form of measurement units to a target form. This works wonderfully in the `scale_by` argument that is present in many number-based `fmt_*()` functions. (#1704, #1709, #1710, #1729) |
| 18 | + |
| 19 | +* The `plot()` method was added for `gt_tbl` so that one can quickly create a reprex visual example (e.g., `exibble |> gt() |> plot()`). (#1742) |
| 20 | + |
| 21 | +* `info_time_style()` and `info_date_style()` gain a `locale` argument to preview time and date formatting in a specific locale. (#1747) |
| 22 | + |
| 23 | +* `data_color()` throws a more informative error message if `rows` didn't resolve to anything (#1659). (@olivroy, #1660). |
| 24 | + |
| 25 | +* Several datasets were added to the package: `reactions`, `photolysis`, `peeps`, `nuclides`, `gibraltar`, and `films`. (#1619, #1641, #1664, #1668, #1686, #1695) |
| 26 | + |
| 27 | +## Improvements to the LaTeX output format |
6 | 28 |
|
7 |
| -* `info_time_style()` and `info_date_style()` gain a `locale` argument to preview datetime formatting in a given locale. |
| 29 | +* A host of improvements were made to LaTeX output such that styling made through `tab_options()` and `tab_style()` is now honored. The styling implemented now includes: (1) font size, underlining, italicizing, bolding, indenting text, coloring text, filling cell backgrounds, and modifying text case (i.e., uppercase, lowercase, sentence case) (#1472). (#1594, #1603, #1746, thanks so much @kbrevoort) |
8 | 30 |
|
9 |
| -* `opt_interactive()` gains `height` to help specify your widget's height (@olivroy, #1544). |
| 31 | +* Text in spanner labels is now nicely wrapped in LaTeX output, where before there would be no wrapping at all (#1656). (#1716, #1746) |
10 | 32 |
|
11 |
| -* `opt_interactive()` now shows row names if `rownames_to_stub = TRUE` (@olivroy, #1702). |
| 33 | +* The `gt()` setting of `row_group_as_column == TRUE` is now implemented in LaTeX output. (#1716) |
12 | 34 |
|
13 |
| -* `data_color()` throws a more informative error message if `rows` didn't resolve to anything (@olivroy, #1659). |
| 35 | +* LaTeX output now understands and can convert from lengths expressed in pixels (an internal conversion to pt units is performed) (#1582). (#1595) |
| 36 | + |
| 37 | +* A fix was made to correct an error related to converting px units to pt units for LaTeX output. (#1591, thank you @AaronGullickson) |
| 38 | + |
| 39 | +## Improvements to interactive HTML tables via `opt_interactive()` |
| 40 | + |
| 41 | +* The performance of interactive table rendering through `opt_interactive()` has been improved (#1289). (#1735) |
| 42 | + |
| 43 | +* `opt_interactive()` now shows row names if `rownames_to_stub = TRUE` (#1702). (@olivroy, #1706) |
| 44 | + |
| 45 | +* There's now better support for displaying group columns, if present, in interactive tables (#1705). (@olivroy, #1725, #1758, #1760) |
| 46 | + |
| 47 | +* Interactive tables can now display the stub header label created with `tab_stubhead()`. (@olivroy, #1758). |
| 48 | + |
| 49 | +* There is no longer an error when having a hidden column under a spanner label in an interactive HTML table (i.e., `opt_interactive()`) context. (#1629) |
| 50 | + |
| 51 | +* Interactive tables now render the first level of column groups added by `tab_spanner()` (#1618). Thanks @obsaditelnost for your work on this! (#1623) |
| 52 | + |
| 53 | +* The `opt_interactive()` function now has the `height` argument to help specify the height of an interactive table (#1544). (@olivroy, #1723). |
| 54 | + |
| 55 | +* When using `opt_interactive(use_pagination = FALSE)` the pagination controls are now entirely removed instead of merely being non-functional (#1542). (#1642) |
| 56 | + |
| 57 | +* When supplying a locale value to an interactive table, we now ensure that the supplied locale is normalized (so `"fr_CH"` will be internally corrected to `"fr-CH"`) (#1637). (#1643) |
| 58 | + |
| 59 | +## Minor improvements and bug fixes |
14 | 60 |
|
15 |
| -* PDF output now allows the font size of a table to be set using the table.font.size parameter in the tab_options function (#1472). The font sizes of individual table cells (including those in the body, stubs, column headings, etc.) can be set using tab_style function. Several other options specified in tab_style are now reflected in PDF output. |
| 61 | +* The `fill_color` argument in `fmt_icon()` now allows the use of named vector/list to apply different colors to different icons (#1560). (#1647) |
16 | 62 |
|
17 |
| -* `data_color()` throws a more informative error if a calculation failed (@olivroy, #1373). |
| 63 | +* `fmt_flag()` gains a `locale` argument so that SVG title text displays country names in any locale language. (#1645) |
18 | 64 |
|
19 |
| -* `gtsave()` saves correctly to .rtf if using `cols_label()` and `summary_rows()` or `grand_summary_rows()` (@olivroy, #1233) |
| 65 | +* To better represent missing values in nanoplots, the `"marker"` option has been added in `cols_nanoplot()` (#1567). (#1587) |
20 | 66 |
|
21 |
| -* interactive tables are now rendering the first level of column groups, added by `tab_spanner()` (@obsaditelnost, #1618) |
| 67 | +* Many of the `info_*()` functions were upgraded with better functionality and a refreshed look. (#1720, #1748, #1754) |
22 | 68 |
|
23 |
| -* `cols_hide()` no longer errors if no column was supplied. Error messages are also clearer when supplying a column that doesn't exist (@olivroy, #1631). |
| 69 | +* The `metro` dataset has been updated with six new Line 11 stations that opened on 2024-06-13. (#1708) |
24 | 70 |
|
25 |
| -* `cols_units()`, `tab_footnote()` and `tab_style()` now give better error messages when `locations` is not correctly specified (@olivroy, #475, #1638 , #1640, #1733). |
| 71 | +* For HTML tables produced in Quarto, we now use the `data-qmd-base64` attribute along with base64 text when passing Markdown text to Quarto (which handles the Markdown conversion) (#1487, #1488). (#1688, #1690, #1734) |
26 | 72 |
|
27 |
| -* `opt_interactive()` has better support for displaying group columns if present (`row_groups_as_column` has no effect on the output) (@olivroy, #1705). |
| 73 | +* Scientific and engineering notation will no longer unexpectedly wrap lines in HTML for smaller column widths. (#1621) |
| 74 | + |
| 75 | +* Footnote marks in HTML table outputs no longer unexpectedly increase the text line height (#1556). (#1644) |
| 76 | + |
| 77 | +* We now ensure tables print correctly when called from inline code in `.qmd` or `.Rmd` documents (#1055). (#1689) |
| 78 | + |
| 79 | +* `data_color()` throws a more informative error if an internal calculation failed (e.g., presence of infinite values) (#1373). (@olivroy, #1585) |
| 80 | + |
| 81 | +* `data_color()` provides an informative error message if `rows` doesn't resolve to anything. (@olivroy, #1659) |
| 82 | + |
| 83 | +* `summary_rows()` now throws a more informative error message that you should use `grand_summary_rows()` if no row groups are detected (#1292). (@olivroy, #1752) |
| 84 | + |
| 85 | +* Boxplot-based nanoplots now correctly determine which data points are outliers. (#1756) |
| 86 | + |
| 87 | +* The issue where having a row group set as a column in the stub, corrupting the setting of column widths in HTML output tables, has been fixed (#1253, #1510). (#1744) |
| 88 | + |
| 89 | +* The rendering of footnotes and source notes received fixes to ensure that all requested notes are inserted and also that the typesetting options in `tab_options()` is implemented (#1505, #1615). (#1620, #1751) |
| 90 | + |
| 91 | +* Using a `fmt_*()` function while the stub is composed of Markdown or HTML no longer results in an error (#1600). (#1627) |
| 92 | + |
| 93 | +* The combination of using `cols_label()` + `summary_rows()` / `grand_summary_rows()` no longer causes an error for RTF output through `gtsave()` (#1233). (#1596) |
| 94 | + |
| 95 | +* We now ensure that `id` values are stripped of HTML tags when using `tab_row_group()`. Previously this condition would create corrupted row group labels (#1143). (#1750) |
| 96 | + |
| 97 | +* `cols_hide()` no longer errors if a column wasn't supplied. Error messages are also clearer when supplying a column that doesn't exist (#1631). (#1632) |
| 98 | + |
| 99 | +* `cols_units()`, `tab_footnote()` and `tab_style()` now give better error messages when `locations` is not correctly specified (#475). (@olivroy, #1638, #1640, #1733) |
| 100 | + |
| 101 | +* Error messages are now improved for `rm_spanners()`, `rm_footnotes()`, and `rm_source_notes()` (#1638). (#1661) |
| 102 | + |
| 103 | +* Error messages for the `vec_*()` functions are now standardized with `check_vector_valid()`. (#1662) |
| 104 | + |
| 105 | +* Running **testthat** tests no longer fails on Windows due to `gtsave()` path incompatibilities (#1626). (#1627) |
| 106 | + |
| 107 | +* Tests run on Windows are less noisy now (no more render related warnings). (#1634) |
| 108 | + |
| 109 | +* Much code refactoring, linting, and test improvements were performed by @olivroy, resulting in many performance gains. (#1666, #1683, #1694, #1699, #1715, #1718, #1728, #1730, #1731, #1732, #1733, #1753) |
| 110 | + |
| 111 | +* **gt** now depends on R 3.6. (#1599, #1731). |
| 112 | + |
| 113 | +## Documentation enhancements |
| 114 | + |
| 115 | +* Many small documentation fixes were performed. (#1555, #1598, #1633, #1658, #1663, #1676, #1685, #1700, #1703, #1717, #1719, #1721) |
| 116 | + |
| 117 | +* More examples were added to further demonstrate how various functions can be used. (#1646, #1667, #1677, #1698, #1724, #1737) |
28 | 118 |
|
29 | 119 | # gt 0.10.1
|
30 | 120 |
|
|
44 | 134 |
|
45 | 135 | * Introduced a small performance improvement by no longer calling `utils::packageVersion()` internally (#1524). (#1525, thank you @slodge)
|
46 | 136 |
|
47 |
| -* Code and test refactoring was performed to generally improve performance and code readability. (#1480, thanks @olivroy) |
48 |
| -* The `gtsave()` function now returns the file path invisibly instead of `TRUE`. (#1478, thank you @olivroy) |
| 137 | +* Code and test refactoring was performed to generally improve performance and code readability. (#1480) |
| 138 | + |
| 139 | +* The `gtsave()` function now returns the file path invisibly instead of `TRUE`. (#1478) |
49 | 140 |
|
50 |
| -* Most functions now produce better error messages if not provided with a `gt_tbl` object. (#1504, c/o @olivroy) |
| 141 | +* Most functions now produce better error messages if not provided with a `gt_tbl` object. (#1504, #1624) |
51 | 142 |
|
52 | 143 | * The URL formatting through `fmt_url()` has been improved by preventing link text breaking across lines (#1509). (#1537)
|
| 144 | + |
53 | 145 | * We now remove some unnecessary newlines in the HTML text produced by `as_raw_html()`, which caused an issue when integrating **gt** tables into **blastula** email messages (#1506). (#1520)
|
54 | 146 |
|
55 | 147 | * The `tab_spanner_delim()` now lets you use `delim` strings longer than a single character (#1469). (#1513)
|
|
0 commit comments