powered by
NULL
Check if condition is not NULL, if so output outputIfNotNull, otherwise, output outputIfNull.
outputIfNotNull
outputIfNull
ifNotNull(condition, outputIfNotNull, outputIfNull = NULL)
argument 1
argument 2
argument 3
outputIfNotNull if condition is not NULL, outputIfNull otherwise.
# NOT RUN { ifNotNull(NULL, "x") ifNotNull(NULL, "x", "y") ifNotNull(1 < 2, "x", "y") # }
Run the code above in your browser using DataLab