# NOT RUN {
# FORMULA
f <- A + B ~ C + D
lhs(f)
lhs(f) <- quote( E / F )
rhs(f)
rhs(f) <- quote( G + H )
op(f)
op(rhs(f))
op( quote(A) ) # NULL:
op.type(f)
# ONE-SIDED FORMULA
f <- ~ A #
lhs(f) # NULL
rhs(f) # A
# EXPRESSION
e <- expression( A + B == C + D )
lhs(e)
rhs(e)
op(e)
op.type(e)
# CALL
c <- quote( A + B > C + D )
lhs(c)
lhs(c) <- quote(E)
rhs(c)
op(c)
op.type(c)
# ASSIGNMENT
a <- quote( A <- B )
lhs(a)
rhs(a)
op(a)
op.type(a)
# }
Run the code above in your browser using DataLab