Learn R Programming

operator.tools

Utilities for working with R's operators

This package provides an extensible collection of utilities for programming with operators that appear in language objects such as formulas, calls and expressions. Various routines allow operations classifying operators, translating between an operator and its underlying function, and inverting some types of operators, etc. All methods can be extended to custom infix operators.

Installation

Stable Version

install.packages('formula.tools')

Development Verison

devtools::install_github("decisionpatterns/formula.tools")

Important Functions

  • operators: Get list of known operators
  • setOperator: Register a new type of operator
    • removeOperator: UNregister an operator
  • is.operator: Test if object is an operator
  • can.operator: Can object be coerced to an operator
  • as.operator: Coerce object to an operator if possible
  • operator.type: get the type of an operator

Copy Link

Version

Install

install.packages('operator.tools')

Monthly Downloads

22,071

Version

1.6.3.1

License

GPL-2 | file LICENSE

Issues

Pull Requests

Stars

Forks

Maintainer

Christopher Brown

Last Published

January 29th, 2026

Functions in operator.tools (1.6.3.1)

notin

NOT IN
setOperator

Registers an operator for use with operator.tools package.
removeOperator

Unregister a an operator.
.initOps

Initialize operators
can.operator

can.operator
fun2name

Convert between a function and its name and vice versa.
operators

Return the _names_ of defined operators.
is.operator

Utilities for operators
rel.type

Get the relational type of a relational operator.
operator.type

Return the type for an operator.
inverse

Invert an R operator