Azzera filtri
Azzera filtri

Info

Questa domanda è chiusa. Riaprila per modificarla o per rispondere.

Hie, how can i solve this error, "Index exceeds matrix dimensions"

1 visualizzazione (ultimi 30 giorni)
The code is as below;
repelem = {};
for ii = 1:numel(subset)
subsetLabels(ii) = repelem((subset(ii).Description),subset(ii).Count,1);
end
Then the error is;
Index exceeds matrix dimensions.
Error in SignLive (line 19)
subsetLabels(ii) = repelem((subset(ii).Description),subset(ii).Count,1);
THANK YOU IN ADVANCE FOR YOUR UNWAVERING SUPPORT AND HELP.
  5 Commenti
KSSV
KSSV il 16 Giu 2020
repelem is a inbuilt function.....you are not supposed to use like that. What version you are using?

Risposte (1)

KSSV
KSSV il 16 Giu 2020
Modificato: KSSV il 16 Giu 2020
Try:
N = numel(subset) ;
subsetLabels = cell(N,1);
for ii = 1:N
subsetLabels{ii} = repelem((subset(ii).Description),subset(ii).Count,1);
end
  3 Commenti
KSSV
KSSV il 16 Giu 2020
What data you have actually? Attach your data.
Talent Mukaro
Talent Mukaro il 16 Giu 2020
Kindly see attached code and the data set pics for one class that is sign zero

Questa domanda è chiusa.

Community Treasure Hunt

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

Start Hunting!

Translated by