フィルターのクリア

Average of Wave from 10 waves in single graph

17 ビュー (過去 30 日間)
Lokeswara reddy pamulapate
Lokeswara reddy pamulapate 2019 年 11 月 20 日
コメント済み: Star Strider 2020 年 2 月 19 日
Hello Everyone,
I have a doubt concerning the average of the wave from a set of waves from sinlge dataset. I need to get a single average curve from all the curves from the figure. I am new to matlab and can not figure it out and have not been able Screenshot (6) .pngto do so for a long time. I need you to help and it would be great for me. Thanks in advance.
  3 件のコメント
Jan
Jan 2019 年 11 月 20 日
Please calm down. Posting a question twice will confuse the ones who want to help you and maybe waste their time, when they type an answer, which has been given already. Therefore I have cleaned up your identical former question.
You cannot expect the voluntary helpers to post an answer in some minutes. Mentioning, that the problem is "urgent" is counterproductive. See: https://www.mathworks.com/matlabcentral/answers/29922-why-your-question-is-not-urgent-or-an-emergency
There is only one curve in the image, so asking for an average is not meaningful. I guess, you mean that te curve is almost periodic and you want an average period. Then please explain, what the inputs are. It is easier to suggest a matching code, if we do not guess tis detail.
Lokeswara reddy pamulapate
Lokeswara reddy pamulapate 2019 年 11 月 20 日
I have the data attched to this. Actually it is the wave of radial artery bloop pressure wave. I want to take the average of all the data to get one average curve from those data.

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

採用された回答

Star Strider
Star Strider 2019 年 11 月 20 日
Try this:
D = load('P_191005_000.mat');
ap = D.b;
Ts = 1E-3; % Assume Sampling Interval
tv = linspace(0, 1, numel(ap))*Ts; % Create Time Vector
[pks, locs] = findpeaks(-ap, 'MinPeakDist',250, 'MinPeakHeight',-85 ); % Determine Peaks & Indices
figure(1)
plot(tv, ap)
hold on
plot(tv(locs), -pks, '+r')
hold off
grid
for k1 = 1:numel(locs)-1
apc{k1} = ap(locs(k1):locs(k1+1)); % Define Frames
tvc{k1} = tv(locs(k1):locs(k1+1));
len(k1) = numel(locs(k1):locs(k1+1));
end
enstrim = cellfun(@(x)x(1:min(len)), apc, 'Uni',0); % Trim Records To Shortest Length
ensavg = mean([enstrim{:}],2); % Ensemble Average
figure(2)
hold all
for k1 = 1:numel(apc)
plot(tvc{k1}-tvc{k1}(1), apc{k1}) % Plot Frames
end
plot(tv(1:numel(ensavg)), ensavg.', '-r', 'LineWidth',2)
hold off
grid
producing:
Average of Wave from 10 waves in single graph - 2019 11 20.png
  31 件のコメント
Lokeswara reddy pamulapate
Lokeswara reddy pamulapate 2020 年 2 月 19 日
Hi, the pulse pressure can be calculated but I need to calculate the Augmented pressure(Anacrotic notch). from these Aorta and femoral.
Star Strider
Star Strider 2020 年 2 月 19 日
For each pulse, identify the dicrotic notch (that appears to define it), as a point in time using the derivative (or whatever technique you choose), then get the pressure at that point in time.

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

その他の回答 (1 件)

KALYAN ACHARJYA
KALYAN ACHARJYA 2019 年 11 月 20 日
編集済み: KALYAN ACHARJYA 2019 年 11 月 20 日
Lets say wave are y1,y2,y3.....up to y10..assuming all are having in same x scale
aveg_data=(y1+y2+y3...+y10)/10;
plot(x,aveg_data)
  5 件のコメント
KALYAN ACHARJYA
KALYAN ACHARJYA 2019 年 11 月 20 日
編集済み: KALYAN ACHARJYA 2019 年 11 月 20 日
Can you share two sample data, so that I can test on it?
Lokeswara reddy pamulapate
Lokeswara reddy pamulapate 2019 年 11 月 20 日
ya sure

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

カテゴリ

Help Center および File ExchangeDescriptive Statistics についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by