df_empty Function

public pure function df_empty(df) result(is_empty)

Check if dataframe is empty (no rows or no columns)

@param[in] df The data frame @return True if empty, false otherwise

Arguments

Type IntentOptional Attributes Name
type(data_frame), intent(in) :: df

Return Value logical


Source Code

    pure function df_empty(df) result(is_empty)
        type(data_frame), intent(in) :: df
        logical :: is_empty

        is_empty = (df % nrows() == 0 .or. df % ncols() == 0)
    end function df_empty