Other packages > Find by keyword >

matchr  

Pattern Matching and Enumerated Types in R
View on CRAN: Click here


Download and install matchr package within the R console
Install from CRAN:
install.packages("matchr")

Install from Github:
library("remotes")
install_github("cran/matchr")

Install by package version:
library("remotes")
install_version("matchr", "0.1.0")



Attach the package and use:
library("matchr")
Maintained by
Christopher Mann
[Scholar Profile | Author Map]
All associated links for this package
First Published: 2021-09-09
Latest Update: 2021-09-09
Description:
Inspired by pattern matching and enum types in Rust and many functional programming languages, this package offers an updated version of the 'switch' function called 'Match' that accepts atomic values, functions, expressions, and enum variants. Conditions and return expressions are separated by '->' and multiple conditions can be associated with the same return expression using '|'. 'Match' also includes support for 'fallthrough'. The package also replicates the Result and Option enums from Rust.
How to cite:
Christopher Mann (2021). matchr: Pattern Matching and Enumerated Types in R. R package version 0.1.0, https://cran.r-project.org/web/packages/matchr. Accessed 21 Nov. 2024.
Previous versions and publish date:
No previous versions
Other packages that cited matchr R package
View matchr citation profile
Other R packages that matchr depends, imports, suggests or enhances
Complete documentation for matchr
Functions, R codes and Examples using the matchr R package
Some associated functions: Enum . Err . Match . Matchply . None . Ok . Option . Result . Some . Try . bang . enum_type . fallthrough . grapes-.-grapes . grapes-fn-grapes . into_option . into_result . is.enum . is.enum_type . is.err . is.none . is.ok . is.some . is.variant . match_cond . unwrap . variant . 
Some associated R codes: check.R . enum.R . fallthrough.R . fun.R . match.R . result_option.R . unwrap.R .  Full matchr package functions and examples
Downloads during the last 30 days
Get rewarded with contribution points by helping add
Reviews / comments / questions /suggestions ↴↴↴

Today's Hot Picks in Authors and Packages

r2resize  
In-Text Resize for Images, Tables and Fancy Resize Containers in 'shiny', 'rmarkdown' and 'quarto' Documents
Automatic resizing toolbar for containers, images and tables. Various resizable or expandable contai ...
Download / Learn more Package Citations See dependency  
deductive  
Data Correction and Imputation Using Deductive Methods
Attempt to repair inconsistencies and missing values in data records by using information from vali ...
Download / Learn more Package Citations See dependency  
RcppHNSW  
'Rcpp' Bindings for 'hnswlib', a Library for Approximate Nearest Neighbors
'Hnswlib' is a C++ library for Approximate Nearest Neighbors. This package provides a minimal R int ...
Download / Learn more Package Citations See dependency  
pkgdepends  
Package Dependency Resolution and Downloads
Find recursive dependencies of 'R' packages from various sources. Solve the dependencies to obtain ...
Download / Learn more Package Citations See dependency  
crossrun  
Joint Distribution of Number of Crossings and Longest Run
Joint distribution of number of crossings and the longest run in a series of independent Bernoulli ...
Download / Learn more Package Citations See dependency  
kgschart  
KGS Rank Graph Parser
Restore underlining numeric data from rating history graph of KGS (an online platform of the game o ...
Download / Learn more Package Citations See dependency  

23,229

R Packages

199,929

Dependencies

62,984

Author Associations

23,230

Publication Badges

© Copyright 2022 - present. All right reserved, rpkg.net.  Based in Cambridge, Massachusetts, USA