Error in Plot Function

1 次查看(过去 30 天)
John Carroll
John Carroll 2021-2-17
I am reciving the following error when trying to plot:
Error using plot
Vectors must be the same length.
Error in lab2 (line 50)
plot(X2,twoHZ,'b--');
code:
figure (1)
subplot(2,3,1)
plot(X2,twoHZ,'b--');
xlabel('time(sec)')
ylabel('height (m)')
title('Two Hz')
Any help would be much apprciated!
  1 个评论
Walter Roberson
Walter Roberson 2021-2-17
We do not know what the sizes of X2 and twoHZ are, or how they are constructed.
All we know from the error message is that X2 and twoHZ are different sizes.

请先登录,再进行评论。

回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Line Plots 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by