title: Pre-allocating the String size in Matlab
body: <p>I am very well aware on how to pre-allocate Matrix sizes using ones, zeros and cell command but what about a String ?</p>
  
  <p>Suppose I have a Matrix named <code>data</code> whose each value is between 1-255 now if i want to print these number's ASCII characters instead of numbers it selves, I'd do that,</p>
  
  <pre><code>msg='';
  
      for i = 1 : length(data)
          msg=horzcat(msg,floor(data(i))); % horzcat doesn't ignore spaces
      end
  
  msg
  </code></pre>
  
  <p>in the above code Matlab is unaware of the size of the <code>msg</code> before the loop ends, What i really want to do is to declare the size of the variable <code>msg</code> before the loop starts.</p>
  
  <p>How can i do that ?</p>