ensureStructsAssign​able( destination, source )

Ensure two structs are compatible for subscripted assignment

Vous suivez désormais cette soumission

If you try to do structA(2) = structB, you may get an error saying "Subscripted assignment between dissimilar structures." This function makes the two structures have the same structure by adding extra fields to make them assignable. Missing fields will be assigned 'nan'.

Citation pour cette source

Sanjay Manohar (2026). ensureStructsAssignable( destination, source ) (https://fr.mathworks.com/matlabcentral/fileexchange/67911-ensurestructsassignable-destination-source), MATLAB Central File Exchange. Extrait(e) le .

Catégories

En savoir plus sur Programming dans Help Center et MATLAB Answers

Informations générales

Compatibilité avec les versions de MATLAB

  • Compatible avec toutes les versions

Plateformes compatibles

  • Windows
  • macOS
  • Linux
Version Publié le Notes de version Action
1.0.0.0