how to preallocate a figure handle?

8 Ansichten (letzte 30 Tage)
zilai si
zilai si am 7 Mai 2019
Beantwortet: KSSV am 7 Mai 2019
Hello everyone, I wonder how to preallocate the array G whose element is figure handle like this?
for i = 1 : 4
G(k) = plot(a, b);

Akzeptierte Antwort

KSSV
KSSV am 7 Mai 2019
h = gobjects(1,10) ;
for i = 1:10
h(i) = plot(rand(1,10)) ;
end

Weitere Antworten (0)

Kategorien

Mehr zu Graphics Object Programming finden Sie in Help Center und File Exchange

Produkte

Community Treasure Hunt

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

Start Hunting!

Translated by