Azzera filtri
Azzera filtri

How do I delete an element from a structure?

2 visualizzazioni (ultimi 30 giorni)
I have this
k.range = [-pi/4 pi/2] ;
k.init = sqrt(2)/2 ;
k.options = odeset('Events',@mystopper);
suppose I want to delete k.options how do I do it?
I found nothing in doc structure...

Risposta accettata

Mischa Kim
Mischa Kim il 29 Mag 2014
Modificato: Mischa Kim il 29 Mag 2014
Douglas, use rmfield:
k = rmfield(k,'options');

Più risposte (0)

Categorie

Scopri di più su Structures in Help Center e File Exchange

Tag

Community Treasure Hunt

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

Start Hunting!

Translated by