I want to return a data.frame from a function if TRUE, else return NA using return(ifelse(condition, mydf, NA))
return(ifelse(condition, mydf, NA))
However, ifelse strips the column names from