title: Best practice for dropping Pandas dataframe columns / rows
body: <p>I recently learned that it is possible to use the <code>iloc</code> function for dropping columns and rows of dataframe objects (as detailed in this <a href="https://thispointer.com/drop-first-row-of-pandas-dataframe-3-ways/" rel="nofollow noreferrer">Tutorial</a>); for example, to drop the zeroth row of a dataframe we can write <code>df = df.iloc[1: , :]</code>.</p>
  <p>At work I often need to drop columns or rows by index, so the <code>iloc</code> function seems easier to use than Pandas' prepackaged <code>drop</code> function. However, is there any drawback in using the first method?</p>