title: How to extract a sub-column from a pandas DataFrame?
body: <p>I have a table with three columns: <strong>A, B</strong> and <strong>C</strong>. Each column is further divided into two sub-columns: <em>Name</em> and <em>Rule</em>.</p>
  
  <p>I need to plot three pie charts out the <em>Name</em> sub-columns using matplotlib, but I don't know how to extract the sub-column. This is what I tried, but it did not work:</p>
  
  <pre><code>chart = df['A'['Name']].value_counts().plot(kind='pie', labels=labels, autopct='%1.1f%%')
  </code></pre>