title: How to interpret a RGB array in R
body: <p>I'm having troubles with interpreting the RGB values I get from an image read in R.</p>
  
  <p>The array I get show values from 0-1, when the RGB colour range is from 0-255. I tried to convert it back to the 0-255 range adjusting a script like this,</p>
  
  <pre><code>picturemax &lt;- max(picture)
  picturemin &lt;- min(picture)
  p.picture &lt;- as.numeric(picture)
  if (picturemax &gt; 255 || picturemin &lt; 0) 
  p.picture &lt;- (picture - picturemin)/(picturemax - picturemin)
  p.picture
  </code></pre>
  
  <p>retrieved from <a href="https://stat.ethz.ch/pipermail/r-help/2003-January/029098.html" rel="nofollow">https://stat.ethz.ch/pipermail/r-help/2003-January/029098.html</a>
  I just change the values in the script from 0-1 to 0-255, but the array still show 0-1 values, just different ones.</p>
  
  <p>My picture-files are also very large, and the array does not fit in the R Console. As I would like to get the RGB data in to an excel sheet or as a text file, I don't know what to do or how to attack that problem.</p>
  
  <p>I apologize if my questions are too basic, but I'm happy for all the help I can get.
  Any suggestions?</p>
  
  <p>Cheers, 
  Maria</p>