title: R - transform scaled and centered data to original values
body: <p>If I scale and centre numeric column in a data frame (each value in each column divided by respective column SD and the mean of each respective column subtracted from each value) - how do I then back-transform to original values. </p>
  
  <p>In the simple example below I see that the mean and SD of each column are stored in the object d4 after application of  'scale' with centering.</p>
  
  <pre><code>d1 &lt;- as.data.frame(seq(1,20,1))
  d2 &lt;- as.data.frame(seq(0.11,0.3,0.01))
  d3 &lt;- cbind(d1,d2)
  names(d3) &lt;- c("A","B")
  d4 &lt;- scale(d3,center=TRUE)
  d4
  
                  A           B
   [1,] -1.60579308 -1.60579308
   [2,] -1.43676223 -1.43676223
   [3,] -1.26773138 -1.26773138
   [4,] -1.09870053 -1.09870053
   [5,] -0.92966968 -0.92966968
   [6,] -0.76063883 -0.76063883
   [7,] -0.59160798 -0.59160798
   [8,] -0.42257713 -0.42257713
   [9,] -0.25354628 -0.25354628
  [10,] -0.08451543 -0.08451543
  [11,]  0.08451543  0.08451543
  [12,]  0.25354628  0.25354628
  [13,]  0.42257713  0.42257713
  [14,]  0.59160798  0.59160798
  [15,]  0.76063883  0.76063883
  [16,]  0.92966968  0.92966968
  [17,]  1.09870053  1.09870053
  [18,]  1.26773138  1.26773138
  [19,]  1.43676223  1.43676223
  [20,]  1.60579308  1.60579308
  attr(,"scaled:center")
       A      B 
  10.500  0.205 
  attr(,"scaled:scale")
          A         B 
  5.9160798 0.0591608 
  </code></pre>
  
  <p>How can I now use the stored mean and SD values to compute from d4 the data frame of original values</p>