datawizard 0.4.0
MAJOR CHANGES
-
data_match()
now returns filtered data by default. Old behavior (returning
rows indices) can be set by settingreturn_indices = TRUE
. -
The following functions are now re-exported from
{insight}
package:
object_has_names()
,object_has_rownames()
,is_empty_object()
,
compact_list()
,compact_character()
-
data_findcols()
will become deprecated in future updates. Please use the
new replacementsfind_columns()
andget_columns()
. -
The vignette Analysing Longitudinal or Panel Data has now moved to
parameters package.
NEW FUNCTIONS
-
To convert rownames to a column, and vice versa:
rownames_as_column()
andcolumn_as_rownames()
(@etiennebacher, #80). -
find_columns()
andget_columns()
to find column names or retrieve
subsets of data frames, based on various select-methods (including
select-helpers). These function will supersededata_findcols()
in the
future. -
data_filter()
as complement fordata_match()
, which works with logical
expressions for filtering rows of data frames. -
For computing weighted centrality measures and dispersion:
weighted_mean()
,
weighted_median()
,weighted_sd()
andweighted_mad()
. -
To replace
NA
in vectors and dataframes:convert_na_to()
(@etiennebacher, #111).
MINOR CHANGES
-
The
select
argument in several functions (likedata_remove()
,
reshape_longer()
, ordata_extract()
) now allows the use of select-helpers
for selecting variables based on specific patterns. -
data_extract()
gains new arguments to allow type-safe return values,
i.e. always return a vector or a data frame. Thus,data_extract()
can now be used to select multiple variables or pull a single variable
from data frames. -
data_match()
gains amatch
argument, to indicate with which logical
operation matching results should be combined. -
Improved support for labelled data for many functions, i.e. returned
data frame will preserve value and variable label attributes, where
possible and applicable. -
describe_distribution()
now works with lists (@etiennebacher, #105). -
data_rename()
doesn't usepattern
anymore to rename the columns if
replacement
is not provided (@etiennebacher, #103). -
data_rename()
now adds a suffix to duplicated names inreplacement
(@etiennebacher, #103).
BUG FIXES
-
data_to_numeric()
produced wrong results for factors when
dummy_factors = TRUE
and factor contained missing values. -
data_match()
produced wrong results when data contained missing values. -
Fixed CRAN check issues in
data_extract()
when more than one variable
was extracted from a data frame.