Missing Data ------------ pandas primarily uses the value ``np.nan`` to represent missing data. It is by default not included in computations. See the :ref:`Missing Data section ` Reindexing allows you to change/add/delete the index on a specified axis. This returns a copy of the data. .. ipython:: python df1 = df.reindex(index=dates[0:4], columns=list(df.columns) + ['E']) df1.loc[dates[0]:dates[1],'E'] = 1 df1 To drop any rows that have missing data. .. ipython:: python df1.dropna(how='any') Filling missing data .. ipython:: python df1.fillna(value=5) To get the boolean mask where values are ``nan`` .. ipython:: python pd.isnull(df1)