Info

La pregunta está cerrada. Vuélvala a abrir para editarla o responderla.

Getting an error on my reshape function

1 visualización (últimos 30 días)
Prajwal Venkatesh
Prajwal Venkatesh el 27 de En. de 2020
Cerrada: MATLAB Answer Bot el 20 de Ag. de 2021
%%
[~,sheet_name]=xlsfinfo('Bunks.xlsx');
for k=1:numel(sheet_name)
[~,data{k}]=xlsread('Bunks.xlsx',sheet_name{k});
end
for i=1:k
data2{:,i}=string(data{:,i});
end
clc
for j=1:k
matchingstring{1,j}=regexp(data2{1,j}, '[A-Z]{2}\d{4}', 'match');
for l=1:size(data{1,j},1)
for m=1:size(data{1,j},2)
element=data{1,j}(l,m);
count=isstrprop(element,'alpha');
if nnz(cell2mat(count))>7
newdata{1,j}(l,m)=element;
end
end
end
end
%% till the above line it works fine
for it4=1:k
D1=newdata{1,it4}.';
out{1,it4} = reshape(D1(~cellfun(@isempty,D1)),size(newdata{1,it4},1),[])';
out{1,it4} =convertStringsToChars(out{1,it4});
end
  1 comentario
Geoff Hayes
Geoff Hayes el 27 de En. de 2020
Prajwal - what is the error message? Please copy and paste the full error message to this question.

Respuestas (0)

La pregunta está cerrada.

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by