title: Sort Pandas dataframe according to list of column names
body: <p>I have a pandas dataframe like this-</p>
  
  <pre><code>d = {'class': [0, 1,1,0,1,0], 'A': [0,4,8,1,0,0],'B':[4,1,0,0,3,1],'Z':[0,9,3,1,4,7]}
  df = pd.DataFrame(data=d)
  
      A   B   Z   class
  0   0   4   0   0
  1   4   1   9   1
  2   8   0   3   1
  3   1   0   1   0
  4   0   3   4   1
  5   0   1   7   0
  </code></pre>
  
  <p>and I have a list like this-<code>['Z','B','class','A']</code></p>
  
  <p>Now I want to sort my pandas dataframe according to the list of column names</p>
  
  <p>therefore the new dataframe would have the columns names-</p>
  
  <pre><code>Z  B  class A
  </code></pre>