フィルターのクリア

Inconsistent Formatting Published HTML

2 ビュー (過去 30 日間)
Victor v. Spaandonk
Victor v. Spaandonk 2020 年 7 月 1 日
編集済み: Victor v. Spaandonk 2020 年 7 月 1 日
I publish a lot of results in html, but often have trouble getting text and figure to appear at the proper place, or at all.
I know of "snapnow" and "drawnow", but they give varying results, sometimes worsening the problem when called inside nested functions (I think).
Does someone have a robust way of getting text and figures to appear inside the proper chapters?
(I often use if-then to exclude certain chapters from running.)
Below a few examples of issues:
  1. Chapter titles outside an if-then statement mis-places text and figure vanishes
% main example 1
if 1
%% chapter 1
t = 1:0.01:10;
b = sin(2*t);
figure;
plot(t,b,'b');
disp('hello world');
end
%% chapter 2
if 1
figure;
plot(t,2*b,'r');
disp('hello world 2');
end
if 1
%% chapter 3
figure;
plot(t,3*b,'k');
disp('hello world 3');
end
2. Duplicate images.
I couldn't quickly reproduce this in an example. It seems to occur only in longer files with lots of nested functions so I couldn't pin-point the problem there.
Any help is appreciated!

回答 (0 件)

カテゴリ

Help Center および File ExchangeProgramming についてさらに検索

製品


リリース

R2018b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by