How to plot the error between two signals?

21 ビュー (過去 30 日間)
afef
afef 2017 年 9 月 25 日
コメント済み: afef 2017 年 9 月 27 日
I did the filtering of an EEG signal using fir filter then i implement this fiter in c langage. Now i need to plot the error between the to filter but i don't know how to do that. Can anyone help me please.
  6 件のコメント
Walter Roberson
Walter Roberson 2017 年 9 月 25 日
plot(x-a) ?
afef
afef 2017 年 9 月 25 日
Ok i will try it .

サインインしてコメントする。

採用された回答

KSSV
KSSV 2017 年 9 月 26 日
x = 1:10;
y1 = 2*x;
y2 = 3.5*x;
% error
dy = y2-y1 ;
% Multiple plot commands, with "hold" on
figure
hold on
plot(x,y1,'r');
plot(x,y2,'b');
plot(x,dy,'g');
%
legend('Signal1','Signal2','error')
  3 件のコメント
Walter Roberson
Walter Roberson 2017 年 9 月 26 日
編集済み: Walter Roberson 2017 年 9 月 26 日
KSSV needed some data for illustration purposes, so he created a range of x from 1 to 10, and created one line as 2*x and a second line as 3.5 * x. In your actual code you would replaces those three lines with your own data.
afef
afef 2017 年 9 月 27 日
Ok i understand now.thanks

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeDigital and Analog Filters についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by