필터 지우기
필터 지우기

Two Array merging into one based on range

조회 수: 5 (최근 30일)
NIKHIL
NIKHIL 2020년 11월 10일
Hello team,
I have to 2 time series array:
Signal_1= [20, 10];
Signal_2 = [ 40, 20, 40, 10, 40];
I want to merge or insert Signal_1 into Signal_2 based range and Signal_1 completely enclosed between Signal_2.
Range_1 = peak2peak(Signal_1); % 10
Range_2 = peak2peak(Signal_2); % [20 20 30 30]; Although this will 30 alone but in array i mentioned range for each 2 values
Based on range, Range_1<Range_2, it can be merged into any of these values.
But [20 10] lies outside [40 20 40] range. While it enclosed between [40 10 40].
Please help in writing code for this this.
Final expected result = [40 20 40 10 20 10 40]

답변 (0개)

카테고리

Help CenterFile Exchange에서 Multirate Signal Processing에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by