./math/R-forcats, Tools for working with categorical variables (factors)

[ CVSweb ] [ Homepage ] [ RSS ] [ Required by ] [ Add to tracker ]

Branch: CURRENT, Version: 1.0.0, Package name: R-forcats-1.0.0, Maintainer: pkgsrc-users

Helpers for reordering factor levels (including moving specified
levels to front, ordering by first appearance, reversing, and randomly
shuffling), and tools for modifying factor levels (including
collapsing rare levels into other, 'anonymising', and manually

Required to run:
[math/R] [devel/R-magrittr] [devel/R-rlang] [math/R-tibble] [math/R-ellipsis]

Required to build:

Master sites: (Expand)

Version history: (Expand)

CVS history: (Expand)

   2023-06-12 01:00:19 by Makoto Fujiwara | Files touched by this commit (2)
Log message:
(math/R-forcats) Updated 0.5.1 to 1.0.0

# forcats 1.0.0

## New features

* New `fct_na_value_to_level()` and `fct_na_level_to_value()` to convert
  NA values to NA levels and vice versa (#337).

## Minor improvement and bug fixes

* All functions now validate their inputs, giving more useful errors if you
  accidentally misspecify an input.

* `fct_collapse()` can now use `other_level = NA` (#291).

* `fct_count()` works with factors that contain `NA`s in levels.

* `fct_explicit_na()` is deprecated in favour of `fct_na_value_to_level()`.

* `fct_expand()` gains an `after` argument so that you can choose where
  the new levels are placed (#138).

* `fct_infreq()` gains the ability to weight by another variable using the `w`
  argument (#261).

* `fct_inorder()` now works when not all levels appear in the data (#262).

* `fct_lump_prop()` and friends now work correctly if you supply weights
  and have empty levels (#292).

* `fct_lump_n()` and `fct_lump_prop()` will now create an "Other" \ 
level even
  if it only consists of a single level. This makes them consistent with the
  other `fct_lump_*` functions (#274).

* `fct_other()` no longer generates a warning if no levels are replaced with
  other (#265).

* `fct_relevel()`, `fct_cross()`, and `fct_expand()` now error if you name the
  arguments in `...` since those names are ignored and your code probably
  doesn't do what you think it does (#319).

* `fct_reorder()` and `fct_reorder2()` now remove `NA` values in `.x` with a
  warning (like  `ggplot2::geom_point()` and friends). You can suppress the
  warning by setting `.na_rm = TRUE` (#315).

* `fct_reorder()` and `fct_reorder2()` gain a new `.default` argument that
  controls the placement of  empty levels (including levels that might become
  empty after removing missing values in `.x`) (#266).

* `fct_unique()` now captures implicit missing values if present (#293).

# forcats 0.5.2

* New `fct()` which works like `factor()` but errors if values of `x`
  are not included in the levels specification (#299)

* `first2()` and `last2()` now ignore missing values in both `x` and `y` (#303).

* Error messages are more informative.
   2021-10-26 12:56:13 by Nia Alarie | Files touched by this commit (458)
Log message:
math: Replace RMD160 checksums with BLAKE2s checksums

All checksums have been double-checked against existing RMD160 and
SHA512 hashes
   2021-10-07 16:28:36 by Nia Alarie | Files touched by this commit (458)
Log message:
math: Remove SHA1 hashes for distfiles
   2021-06-06 15:45:50 by Makoto Fujiwara | Files touched by this commit (2)
Log message:
(math/R-forcats) Updated 0.4.0 to 0.5.1

# forcats 0.5.1

* Re-license as MIT (#277).

* `fct_lump_n()` no longer uses a partial argument name (@malcolmbarrett, #276).

# forcats 0.5.0

* `as_factor()` gains a logical method that always returns a factor with
  levels "FALSE" and "TRUE" (#185).

* `fct_c()`, `fct_collapse()` and `fct_recode()` are now explicitly
  documented as using [dynamic dots](https://rlang.r-lib.org/reference/dyn-dots.html)
  (@labouz, #234).

* `fct_collapse()` now accepts a `other_level` argument, to allow a
   user-specified `Other` level (@gtm19, #194). It now correctly collapses
   factors when `other_level` is not `NULL` (#172), and makes `"Other"` the
   last level (#202) (@gtm19, #172 & #202)

* `fct_count()` no longer converts implicit NAs into explicit NAs (#151).

* `fct_inseq()` behaves more robustly when factor levels aren't all numbers

* `fct_lump()` has been split up into three new functions: `fct_lump_prop()`,
  `fct_lump_n()`, and `fct_lump_lowfreq()`. (@jonocarroll, #167, #142).
  All `fct_lump_()` functions check their inputs more carefully
  (@robinson_es, #169)

* `fct_reorder2()` gains a helper function `first2()`, that sorts `.y` by the
  first value of `.x` (@jtr13).
   2019-08-08 21:53:58 by Brook Milligan | Files touched by this commit (189) | Package updated
Log message:
Update all R packages to canonical form.

The canonical form [1] of an R package Makefile includes the

- The first stanza includes R_PKGNAME, R_PKGVER, PKGREVISION (as
  needed), and CATEGORIES.

- HOMEPAGE is not present but defined in math/R/Makefile.extension to
  refer to the CRAN web page describing the package.  Other relevant
  web pages are often linked from there via the URL field.

This updates all current R packages to this form, which will make
regular updates _much_ easier, especially using pkgtools/R2pkg.

[1] http://mail-index.netbsd.org/tech-pkg/2019/08/02/msg021711.html