Converts object to numeric, preserving the NULL value.

as.numeric_or_null(x)

Arguments

x

Object to cast.

Value

x casted, or NULL.