Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

options for format_value() : drop leading 0, minus and plus signs #711

Closed
bwiernik opened this issue Jan 13, 2023 · 0 comments · Fixed by #724
Closed

options for format_value() : drop leading 0, minus and plus signs #711

bwiernik opened this issue Jan 13, 2023 · 0 comments · Fixed by #724
Assignees
Labels
Enhancement 💥 Implemented features can be improved or revised

Comments

@bwiernik
Copy link
Contributor

We use format_value() a bunch in see and visualisation_recipe() for formatting labels on graphs. It would be useful to include some more number formatting options to make these prettier. Three that come to mind:

  1. Drop leading zeros (e.g., from visualisation_recipe.see_easycorr_matrix)
  2. Format negative signs as minus signs vs hyphens
  3. Format positive signs as plus or figure space vs nothing

For 2 or 3, cf. r-lib/scales#366

@strengejacke strengejacke added the Enhancement 💥 Implemented features can be improved or revised label Feb 3, 2023
@strengejacke strengejacke self-assigned this Feb 21, 2023
strengejacke added a commit that referenced this issue Feb 22, 2023
…724)

* options for `format_value()` : drop leading 0, minus and plus signs
Fixes #711

* test, news, version bump

* add stlye for signs

* news

* deal with factors

* test

* Apply automatic changes

---------

Co-authored-by: strengejacke <strengejacke@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Enhancement 💥 Implemented features can be improved or revised
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants