maximum number of characters of the latex interpreter?
이전 댓글 표시
Hi
I wanted to write a multiline text in a text box with the latex interpreter but found that there seems to be a limit on how many characters I can use. Is there a way around it?
For example the following code works for N<17 but crashes the latex interpreter for N>=17:
N=17;
A=reshape(1:N^2,N,N)';
Na=length(A(:,1));
ltex=cell(Na,1);
for inda=1:Na
ltex{inda}=num2str(A(inda,:));
end
figure
th=text(0.1,0.9,ltex,'interpreter','latex')
set(th,'verticalAlignment','top')
댓글 수: 4
Oleg Komarov
2011년 9월 12일
What do you need the latex interpreter for?
And besides, you're missing $ in the strings.
What are you trying to achieve?
Fred
2011년 9월 13일
Oleg Komarov
2011년 9월 13일
Please correct the above example (since you know):
Warning: Unable to interpret LaTeX string
I'm using R2011a Win32 Vista.
Fred
2011년 9월 14일
채택된 답변
추가 답변 (1개)
Oleg Komarov
2011년 9월 13일
A workaround:
N = 20;
ltex = cellstr(reshape(sprintf('%3.0f\\;',1:N^2).',[],N).');
axes('Ylim',[0,18])
for n = 17:-1:1
th = text(0.02,n,['$' ltex{18-n} '$'],'interpreter','latex');
end
댓글 수: 2
Fred
2011년 9월 14일
Walter Roberson
2011년 9월 14일
You could put them inside a uipanel() and then they would move together.
카테고리
도움말 센터 및 File Exchange에서 Numeric Types에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!