title: Finding the difference between columns in matrix without loops
body: <p>I have the results from an iterative process, where the results from each iteration is placed beside eachother, like this:</p>
  
  <pre><code>res = 
     43.7826   38.8460   38.6889   38.6912   38.6915
    107.0735   98.5577   98.1212   98.1170   98.1175
   -134.6218 -131.6938 -131.5378 -131.5352 -131.5352
   -105.9498 -103.1403 -102.9195 -102.9139 -102.9139
  </code></pre>
  
  <p>What I want to do is create one matrix that shows the difference between each column, and one matrix that shows the percentage change from one column to the next.</p>
  
  <p>This is obviously simple to do using loops, but is there a clever way to do this without loops (maybe using some built-in Matlab functions)?</p>
  
  <p>Thanks.</p>