title: Matlab set defaultTextInterpreter to LaTeX
body: <p>I am running Matlab R2010A on OS X 10.7.5</p>
  
  <p>I have a simple matlab plot and would like to use LaTeX commands in the axis and legend. However setting: </p>
  
  <p><code>set(0, 'defaultTextInterpreter', 'latex');</code></p>
  
  <p>Has zero effect, and results in a TeX warning that my tex commands can not be parsed. If I open plot tools of this plot, the default interpreter is set to 'TeX'. Manually setting this to 'LaTeX' obviously fixes this, but I can't do this for hundreds of plots.</p>
  
  <p>Now, if I retrieve the default interpreter via the Matlab prompt, i.e
  <code>get(0,'DefaultTextInterpreter')</code></p>
  
  <p>It says 'LaTeX', but again, when I look in the properties of the figure via the plot tools menu, the interpreter remains set to 'TeX'. </p>
  
  <p>Complete plotting code:</p>
  
  <pre><code>figure
  f = 'somefile.eps'
  set(0, 'defaultTextInterpreter', 'latex'); 
  ms = 8;
  fontSize = 18;
  loglog(p_m_sip, p_fa_sip, 'ko-.', 'LineWidth', 2, 'MarkerSize', ms); hold on;
  xlabel('$P_{fa}$', 'fontsize', fontSize);
  ylabel('$P_{m}$', 'fontsize', fontSize);
  legend('$\textbf{K}_{zz}$', 'Location', 'Best');
  set(gca, 'XMinorTick', 'on', 'YMinorTick', 'on', 'YGrid', 'on', 'XGrid', 'on');
  print('-depsc2', f);
  </code></pre>