getting "Cell contents reference from a non-cell array object" error

1 Ansicht (letzte 30 Tage)
Mekala balaji
Mekala balaji am 31 Okt. 2014
Kommentiert: Image Analyst am 31 Okt. 2014
%%trying to read multiple text files, and store data, and plot
clc;clear all;
clc
%tic
FileList=dir('D:\Matlab2010\Filesfolder\Code for files\Textfilesreference/');
j=1;
for i=3:1:(size(FileList))
FileName{j}=FileList(i).name;
j=j+1;
%disp(FileName);
end
% for i=1:size(FileName,2)
% FileDate{j} = FileName{j}(00:50);
% end
for j=1:size(FileName,2)
fin=fopen(['D:\Matlab2010\Filesfolder\Code for files\Textfilesreference/',FileName{j}],'r');
s=1;
while ~feof(fin)
tt=fgetl(fin); %Scan all lines
%fclose(fin);
%disp(FileName);
if s>=25 && s<=41
aa=(tt);
Desc{s-24,:}=strsplit(aa(1:47));
Dataopen{s-24,:}=strsplit(aa(50:65));
Dataend{s-24,:}=strsplit(aa(72:size(aa,2)));
% Data{s-24,:}=aa(50:size(aa,2));
% Data_Split{s-24,:}=strsplit(Data{s-24,:});
end
s=s+1;
end
for k=1:size(Dataopen,1)
Data_All{j}{i,1}=strcat(Desc{i}{1,:});
Data_All{j}{i,2}=Data_Split{i}{1,1};
Data_All{j}{i,3}=Data_Split{i},{1,2};
end
end
After I run this code i am "Cell contents reference from a non-cell array object" error Pl help
  1 Kommentar
Image Analyst
Image Analyst am 31 Okt. 2014
You forgot to paste in the error message - you just snipped out a small part of it and left out the most crucial part - the line of code that cause the error! Please paste in all the red text. I can't even run this code because you didn't attach any data files, so I can't even replicate your error because it doesn't get that far.

Melden Sie sich an, um zu kommentieren.

Antworten (0)

Kategorien

Mehr zu Graphics Object Properties finden Sie in Help Center und File Exchange

Tags

Community Treasure Hunt

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

Start Hunting!

Translated by