Macaulay2 » Documentation
Packages » RInterface » RObject » RObject and RObject
next | previous | forward | backward | up | index | toc

RObject and RObject -- logical conjunction of R objects

Description

Compute the element-wise logical conjunction of two R logical vectors, calling R's &.

i1 : RObject true and RObject false

o1 = [1] FALSE

o1 : RObject of type logical

When the inputs contain multiple elements, the output will also contain multiple elements.

i2 : RObject {true, true, false, false} and RObject {true, false, true, false}

o2 = [1]  TRUE FALSE FALSE FALSE

o2 : RObject of type logical

One of the operands may be a Macaulay2 object. It will be converted to an RObject before the operation is performed.

i3 : RObject {true, true, false, false} and {true, false, true, false}

o3 = [1]  TRUE FALSE FALSE FALSE

o3 : RObject of type logical

See also

Ways to use this method:


The source of this document is in /build/reproducible-path/macaulay2-1.26.05+ds/M2/Macaulay2/packages/RInterface/doc/logical.m2:68:0.