Infix Functions For Vector Operations

Vector operations between grapes: An infix-only package! The 'invctr' functions perform common and less common operations on vectors, data frames matrices and list objects: - Extracting a value (range), or, finding the indices of a value (range). - Trimming, or padding a vector with a value of your choice. - Simple polynomial regression. - Set and membership operations. - General check & replace function for NAs, Inf and other values.


Build Status Build status CRAN status lifecycle

This package contains only infix functions (grapes-function-grapes), most of them shorten the syntax for common vector operations, such as finding indices and extracting values from vectors.

The main function classes are:

  • Extractors - Extract indices or values from the front or the rear of a vector
  • Insiders & Outsiders - Determine whether values in a vector are inside or outside a specific range and/or exctract those values
  • Counters - Automatically increment a value or a numerical object (e.g. in a while loop)
  • Padders & Trimmers - Padd or Trim the front and/or rear of a vector
  • Regressors - Perform simple polynomial regression on vectors

In addition, some infix functions for very specific tasks are provided, e.g., the rose tinted infix %00% provides a means to deal with functions that return NA, Inf, NULLor other error/exception values by turning them into a user specified value.


Reference manual

It appears you don't have a PDF plugin for this browser. You can click here to download the reference manual.


0.1.0 by Fred Hasselman, 2 months ago

Report a bug at

Browse source code at

Authors: Fred Hasselman [aut, cre]

Documentation:   PDF Manual  

GPL-3 license

Imports rlang, plyr

Suggests spelling, knitr, rmarkdown, testthat

See at CRAN