title: MATLAB how can I save an image?
body: <p>I tried the commands:</p>
  
  <pre><code> imshow(originalImage);
   imsave;
  </code></pre>
  
  <p>it works, but I want the matlab to automatically save the image in bmp format (in the current folder).
  I tried to use:</p>
  
  <pre><code> save('myimage.bmp','originalImage');
  </code></pre>
  
  <p>the picture was saved, but on the image itself, instead of the picture, I saw this message:
  "windows photo viewer can't open this picture because the file apears to be damaged, corrupted, or is too large".
  (the size of the picture is 5kb).</p>
  
  <p>Thanks!</p>