- refactored variable

git-svn-id: http://moon:8086/svn/software/trunk/projects/GnuRadio@450 b431acfa-c32f-4a4a-93f1-934dc6c82436
This commit is contained in:
2019-05-24 05:55:30 +00:00
parent a8153e5a72
commit c6c53e228d
+3 -3
View File
@@ -131,13 +131,13 @@ for k=1:numFrames
% Sort peaks
[v, n] = sort((X-Xm)(peak_pos), 'descend');
peak_cand_sorted = peak_pos(n);
peak_pos_sorted = peak_pos(n);
% Construct peak boxes
peak_pos = [];
peak_boxes_rel = zeros(1, Nh);
peak_boxes_abs = zeros(1, Nh);
for x = peak_cand_sorted,
for x = peak_pos_sorted,
% Find peak widths
left = x;
@@ -209,7 +209,7 @@ for k=1:numFrames
Xm(n) = last;
end
end
% Create peak boxes with correct absolute height
peak_box_values = Xm;
peak_box_values((peak_boxes_rel > 0)) = peak_boxes_abs(peak_boxes_rel > 0);