title: Error about arguments of length zero when judge a dataframe is Null in R
body: <p>Hi there I am new to R and I am trying to see if the df is Null, if it is, then assigned "empty" to it but there is an error like this, do you know how to solve it?</p>
  
  <pre><code>if(is.na(df)){
    df &lt;- "Empty"}
  </code></pre>
  
  <p>Error in if (is.na(data_si)) { : argument is of length zero</p>