Why won't cellfun plot a semilog?
조회 수: 13 (최근 30일)
이전 댓글 표시
I have a bunch of data samples stored in a cell array that I am trying to plot using cell fun. For some reason it won't let me plot on a semilog scale and I can't find any reason why that is.
This is the code I have written:
FCabs{k} = abs(FControl{k});
X{k} = (Fs/1024)*(0:1024-1);
figure
hold on
cellfun(@semilogy, X, FClog)
hold off
This is the plot that is output.

댓글 수: 0
채택된 답변
Walter Roberson
2021년 3월 7일
hold on
One of the properties that is "hold" is YScale.
FCabs{k} = abs(FControl{k});
X{k} = (Fs/1024)*(0:1024-1);
fig = figure;
ax = axes(fig);
hold(ax, 'on')
cellfun(@(x,y) plot(ax, x, y), X, FClog);
hold(ax, 'off')
ax.YScale = 'log';
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Data Type Identification에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!