Error: Dot indexing is not supported for variables of this type.
1 visualizzazione (ultimi 30 giorni)
Mostra commenti meno recenti
Dear community, when I add a row to a matrix in structure parameter,
a = ones(1,5);
parameter.A = [parameter.A; a];
the following error occurs: Dot indexing is not supported for variables of this type. I don't know how to modify it.
2 Commenti
per isakson
il 22 Mag 2019
Modificato: per isakson
il 22 Mag 2019
Show us the results of
whos parameter
and
parameter
Risposta accettata
per isakson
il 22 Mag 2019
Modificato: per isakson
il 22 Mag 2019
I cannot reproduce your problem. This works
%%
parameter.A = [];
a = ones(1,5);
parameter.A = [parameter.A; a];
b = 2*ones(1,5);
parameter.A = [parameter.A; b]
and outputs
>> parameter =
struct with fields:
A: [2×5 double]
>> parameter.A
ans =
1 1 1 1 1
2 2 2 2 2
>>
Più risposte (1)
Yuichi Mimura
il 22 Mag 2019
Modificato: per isakson
il 22 Mag 2019
If you simply wish to add row "a" to a part of Structure Array "parameter", the below code will realize this.
a = ones(1,5);
parameter.A = a;
>> parameter.A
ans =
1 1 1 1 1
Can this be your solution?
Vedere anche
Categorie
Scopri di più su Call Python from MATLAB in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!