tidytidbits0.3.3 package

A Collection of Tools and Helpers Extending the Tidyverse

format_p_values_at

Format numeric columns for display

identity_order

Ordering function: identity order

invalid

A notion of valid and invalid

invert_value_and_names

Inverting name and value

local_variables

"Variable generating" functions

add_prop_test

Add results of prop.test to data frame

all_or_all_na

All() giving NA only if all values are NA

any_or_all_na

Any() giving NA only if all values are NA

append_object

Appending in a pipe, never unlisting

are_true

Vectorised conversion to logical, treating NA as False

as_formatted_number

Format numeric value for output

as_formatted_p_value

Formatting p values

as_percentage_label

Format as percentage for output

categorical_test_by

Categorical test in a pipe

contingency_table_as_matrix

Convert contingency table to classical R matrix

contingency_table_by

Create data frame formed like a contingency-table

count_at

Count by multiple variables

count_by

Count according to grouping

dina

The DIN A paper formats

equal_including_na

Compare vectors, treating NA like a value

eval_unquoted

Execute code after tidy evaluation

expression_list

Extract symbols from an expression of symbols and operators

first_non_nas

Row-wise first value which is not NA

first_non_nas_at

Row-wise first value that is not NA

first_not

First argument that does not equal a given value

first_not_na

First argument that is not NA

first_which_non_na_at

Row-wise first index of column that is not NA

first_which_not_na

First which() is not na

format_numbers_at

Format numeric columns for display

lookup

Lookup in a dictionary

lookup_function_from_dict

Creating a lookup function from dictionary

lump

Generic lumping

lump_rows

Lump rows of a tibble

named_palette

Named color palette

order_factor_by

Reorder a factor

orderer_function_from_sorted_vectors

Orderer function for complex sorting

pluck_vector

Pluck with simplified return value

prepare_directory

Directory creation

prepare_path

Directory creation and file path concatenation

prepend_object

Prepending in a pipe, never unlisting

print_deparsed

Print deparsed language

rename_factor

Rename a factor.

rename_reorder_factor

Rename and reorder a factor.

replace_sequential_duplicates

Replace sequential duplicates

save_pdf

Save plot as PDF

save_png

Save plot as PNG

sequential_duplicates

Detect sequential duplicates

str_locate_match

Combine str_match and str_locate

symbol_as_quosure

Make quosure from symbol

syntactically_safe

Syntactically safe names

true_or_na

Test for logical true or NA

truthy

A python / javascript-like "truthy" notion

tuple_assignment

Infix operator for python-style tuple assignment

which_non_na

Get indices of non-NA values

with_name

Slice by name

with_value_containing

Slice by value

A selection of various tools to extend a data analysis workflow based on the 'tidyverse' packages. This includes high-level data frame editing methods (in the style of 'mutate'/'mutate_at'), some methods in the style of 'purrr' and 'forcats', 'lookup' methods for dict-like lists, a generic method for lumping a data frame by a given count, various low-level methods for special treatment of 'NA' values, 'python'-style tuple-assignment and 'truthy'/'falsy' checks, saving to PDF and PNG from a pipe and various small utilities.

  • Maintainer: Marcel Wiesweg
  • License: GPL-3
  • Last published: 2025-08-18