Conditions

“Inline” conditions

Not used through if or a similar statement.

Check if a condition is true:

df$var[conditionToTest]

Check if a condition is false:

df$var[ ! conditionToTest]

conditionToTest should be replaced by actual R code.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.