Changelog
Source:NEWS.md
Version 0.27
o Moved missing values frequencies in the attributes, for functions
wsummary() and wtable()
o Fixed bug interpreting a multi-byte character value as missing
o New function wmeasures() to allow for multiple summaries
o New function valid_na_index() to validate the na_index correctness
o Discard inconsistent declared missing metadata before it can affect
formatting, summaries, conversions or data-frame operations
o New optional argument "decimals" in function declared(), to assist
in values displayVersion 0.26
CRAN release: 2026-04-02
o Weighted functions now have a default "w*" naming, with "w_*" still
available as an alias, for backward compatibility
o Changed default for argument "values" in function wtable(), now TRUE
o Tables of frequencies now print the values to the left of the labels
o Extended weighted.mean() for objects of class "declared"
o Declared tables of frequencies now play nicely with dotchart()
o Improved internal function to check measurement levels
o Removed argument "margin" from function wtable()
o New internal function direct_declared()Version 0.25
CRAN release: 2024-09-08
o Adapted class methods for declared objects with "`Date`" inputs
o Improved function `sum()` for declared objects
o Fixed bug in `undeclare()` with numeric values and character (declared)
missing values (thanks to Kyle Husmann for the report)
o New methods for `vec_proxy()` and `vec_restore()` for objects of class
"`declared`" (thanks to Kyle Husmann for the PR)Version 0.24
CRAN release: 2023-12-07
o Objects of class "`Date`" are now accepted as input for a declared object
o The package no longer automatically coerces from numeric to integer
o Improved version of `w_table()` for duplicated labels
o Bug fix in `as.haven()` for declared missing values with no labels
(thanks to Marijana Glavica for the report)Version 0.21
CRAN release: 2023-05-16
* Function `declared()` now recognize a "`labels`" attribute of the input
object, if it already exists
* Fixed bug in function `measurement()`, when dealing with variables with
missing range only (no discrete missing values declared)
* To prevent abrupt errors when subsetting a data frame with declared
variables, the default action is now to impose unique value labels
* The function labels() gains a new argument "`print_as_df`" (TRUE by default)
to print the labels as a data frame
* Printing a declared object now display a maximum of seven value labels,
with a message indicating how many are left out
* New functions `w_IQR()` and `w_fivenum()`Version 0.18
CRAN release: 2022-09-29
* Improved method for `rbind()` data frames, taking care of declared variables
* Function value_labels() has been replaced with the generic base function
`labels()`, and the function `variable_label()` has been replaced with the
function `label()`
* Changed default for `as.factor()`, with values and (where available) levels
(thanks to Daniel Antal for the report)
* New generic function `drop_na()` to drop information about the declared
missing valuesVersion 0.15
CRAN release: 2022-04-13
* Class method for many / most primitive functions, with declared objects
* Bug fix in `w_table()` affecting zero frequency categories
* Dropped alias `frtable()` from function `w_table()`
* New function `is.empty()`, testing the presence of undeclared missing values
* Main function `declare()` is now generic, allowing flexibility to create
custom methods for any other classes of objects
* Removed dependency on package admisc, by incorporating the necessary
functionality as internal functionsVersion 0.13
CRAN release: 2022-04-03
* New functions `w_mode()` and `w_standardize()`
* Fixed `w_summary()`, summaries should not be rounded by default
* Fixed `w_mean()` to weight negative values
Thanks to an anonymous reviewer for reporting and suggesting the following:
* New argument "`drop`" in function `undeclare()`
* Bug fix in the class methods for `head()` and `tail()`
* Function declared now duly recognizes input factors
* Extended `as.factor()` for objects of class "`declared`"
* Added proper class methods for primitive arithmetic operations
* New functions `as.declared()`, `is.declared()`
* Added explanatory documentation (for instance in the DESCRIPTION file) to
explain the reasons for reimplementing some of the base functionsVersion 0.10
CRAN release: 2022-02-22
* New functions `w_mean()`, `w_var()` and `w_sd()`, `w_quantile()` and
`w_median()`, to obtain weighted versions of mean, variance and standard
deviation, quantiles and median, respectively, adapted to declared objects
* Fixed a bug in `as.haven.declared()`, when all values are (declared)
missing and labels are not numeric
* Argument "`weight`" changed to "`wt`" in `w_table()`
* New arguments in function `w_table()`: "`observed`" to only print observed
values, and "`margin`" to calculate proportions in crosstabs
* Function `w_table()` now accepts a second argument "`y`" to create crosstabs
* Function `frtable()` renamed to `w_table()` standing for weighted tableVersion 0.9
CRAN release: 2022-02-11
* New argument "`weight`" in function `frtable()`, allowing to weight not
only valid but also missing values
* More robust function `frtable()` in treating declared values with
overlapping labels (e.g. hierarchical ISCO codes and categories)
* Fixed a bug in `declared()` when all values are completely missing