title: Order column by their names
body: <p>I am looking to order my columns by name. I know that I can do the following: <code>portManDMA = portManDMA[,c(1,2,6,7,8,9,10,3,4,5,11,12,13,14,15,16,17,18,19)]</code> to reorder the columns, but what I would like to do is actually use the column name in the ordering. For example:</p>
  
  <pre><code>## OriginalMatrix  
  DEF ABC KLM  HIJ
  </code></pre>
  
  <p>Where each 3 letters represent a column name. I would like then reorder them based on the columns names, something like <code>portManDMA = portManDMA[,c("ABC","KLM","DEF","HIJ")]</code>, for example, so that the new ordering would then be:  </p>
  
  <pre><code>## NewMatrix  
  ABC KLM DEF HIJ  
  </code></pre>
  
  <p>Would anyone be able to help me with this? </p>