필터 지우기
필터 지우기

how to solve this error index?

조회 수: 4 (최근 30일)
ramya
ramya 2023년 11월 13일
댓글: ramya 2023년 11월 13일
i Have five files i have to plot 50 percentile plot column 3 data with respect to 120:0.1:150.5 in one single plot
Files = dir('*.csv');
Filesc = struct2cell(Files);
NrFiles = size(Filesc,2);
for k = 1:NrFiles
filename = Filesc{1,k};
T{k,:} = readtable(filename);
end
Final_T = cat(1,T{:});
i=reshape(Final_T.r,5,24)
i = 5×24
1.0e+65 * 0.0000 0.0000 0.0000 -0.0000 0.0000 0.0000 0.0000 -0.0000 -0.0000 -0.0000 0.0000 0.0000 0.0000 0.0001 1.0400 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 -0.0000 0.0000 -0.0000 0.0000 -0.0000 0.0000 -0.0000 0.0000 0.0000 0.0000 -0.0000 -0.0000 -0.0000 0.0000 0.0000 0.0000 0.6970 1.1500 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 -0.0000 0.0000 -0.0000 0.0000 -0.0000 -0.0000 -0.0000 0.0000 0.0000 0.0000 -0.0000 -0.0000 -0.0000 0.0000 0.0000 0.0000 0.7700 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 -0.0000 -0.0000 0.0000 -0.0000 0.0000 -0.0000 -0.0000 0.0000 0.0000 0.0000 0.0000 -0.0000 -0.0000 0.0000 0.0000 0.0000 0.0000 0.8510 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 -0.0000 0.0000 0.0000 -0.0000 0.0000 -0.0000 -0.0000 0.0000 0.0000 0.0000 -0.0000 -0.0000 -0.0000 0.0000 0.0000 0.0000 0.0000 0.9410 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 -0.0000 0.0000 -0.0000 -0.0000
i(:)'
ans = 1×120
0.8142 0.7521 0.6826 0.6062 0.5238 0.4362 -0.3673 -0.2726 -0.1752 -0.0760 0.0239 0.1236 -0.1978 -0.2947 -0.3886 -0.4787 -0.5639 -0.6435 0.6993 0.7671 0.8273 0.8793 0.9224 0.9564 0.7131 0.8761 1.0706 1.3118 1.6262 2.0632
size(i)
ans = 1×2
5 24
x=120:0.2:124.6;
size(x)
ans = 1×2
1 24
per=prctile(i,50) % i hv to take 50 percentile of column 3 data from all the files and plot against 120:0.1:120.5
per = 1×24
1.0e+64 * 0.0000 -0.0000 -0.0000 -0.0000 0.0000 0.0000 0.0000 -0.0000 -0.0000 -0.0000 0.0000 0.0000 0.0004 7.7000 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 -0.0000 -0.0000 0.0000 -0.0000
figure
plot(x, per)
grid
xlabel('b')
ylabel('r')
i am not able to plot properly 50 percentile plot for column 3 data which is present in all data files wrt 120:0.1:124.6 in one single plot . i want all the files data in one plot
  댓글 수: 2
Star Strider
Star Strider 2023년 11월 13일
This looks strikingly similar to how to import file? and I still do not understand the objective.
ramya
ramya 2023년 11월 13일
this time data s changed i have to plot 50 percentile column 3 data of all files wrt 120:0.1:124.6

댓글을 달려면 로그인하십시오.

답변 (0개)

카테고리

Help CenterFile Exchange에서 Manage System Data에 대해 자세히 알아보기

태그

제품


릴리스

R2021a

Community Treasure Hunt

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

Start Hunting!

Translated by