Find the first occurrence of an operator in a formula and return the left, right, or both sides of the operator.
findOperator(x, op, side)
The side of the operator requested, NA if requesting the left side of a unary operator, and NULL if the operator is not found.
The formula to parse
The operator to search for (e.g. +
, -
, *
, /
, ...)
Which side of the operator would you like to see: 'left', 'right', or 'both'.
Other Formula parsing:
parse_formula_to_cols()