Skip to contents

All vignettes

Use container in interactive session

A starting point for new users, this vignette introduces the basic functionality of {container}. It provides guidance on when to use the package, explains key operations, and illustrates how {container} improves upon base R lists.

Use container for code development

Use this vignette if you want to see how container operations can be used to make it safer and easier to work with list-like data structures. It describes the different methods to add, extract, replace, and remove elements and their nuances. This vignette demonstrates how {container} enhances the robustness of code by providing strict validation and clear, intent-driven operations for adding, extracting, replacing, and removing elements. It highlights features that minimize errors and streamline development workflows.

Manage parameter lists with dict

Focuses on how to simplify and safeguard parameter list management using Dict. This vignette demonstrates intuitive operations for adding, extracting, replacing, and merging parameters, eliminating the need for repetitive checks and error handling.

Manage data columns with dict.table

This vignette showcases dict.table, an extension of data.table with enhanced column management functions. It compares workflows in dict.table and dplyr, demonstrates built-in safeguards for common operations, and highlights how the two frameworks can be seamlessly combined.

Deque, Set, and Dict

Explore the specialized data structures provided by {container}. These are, Deque for efficient double-ended queue operations, Set for unique elements with basic set operations and order-sensitive behavior, and Dict, a dictionary-like structure, offering ordered key-value pairs and safe operations for managing named elements.

Reference semantics

Provides an overview of reference semantics in {container}, where operations like ref_add() modify objects directly. While potentially useful for optimizing performance or reducing code verbosity, this vignette advises cautious use to avoid unnecessary coupling or unintended side effects.