lazy.andor {lazy.andor}R Documentation

lazy.andor: Generation of string infix operators

Details

This package generates infix operators: '&', '&&', '|', '||',
which are almost equivalent to, resp, '%&%', '%&&%', '%|%', '%||%'
in the package lazy.tools.

The difference is that '&' has precedence over '|“ but '%&%“ does NOT.
Therefore, it is better to use parentheses.

See the descriptions of And, Or, and Not in the package lazy.tools.

"a" & "b" is equivalent to And( "a", "b" ) and generates "(a) & (b)".
"a" && "b" is equivalent to And( "a", "b", oper="&&" ) and generates "(a) && (b)".
"a" | "b" is equivalent to Or( "a", "b" ) and generates "(a) | (b)".
"a" || "b" is equivalent to Or( "a", "b", oper="||" ) and generates "(a) || (b)".

Note that '&' has precedence over '|“ but '%&%“ does NOT.

Use eval( parse(text=condition) ) to evaluate the expression.

To remove these operators:
detach("package:lazy.andor", unload=TRUE)


[Package lazy.andor version 0.1.3 Index]