How to filter plots to get constant more prominently visible?

조회 수: 2 (최근 30일)
Ali Zeeshan
Ali Zeeshan 2016년 4월 28일
댓글: Ali Zeeshan 2016년 4월 29일
I am working on plots to get the distance between two constants point in the plots. Below is one example plot i generated where x-axis shows the time of video and y-axis hows the height of bounding box. I need to take distance between two points where the bounding box height was constant for some time. Like if bounding box height increases/decreases between the range of 1 to 2 for some time, we consider it that the bounding box height was same for some time. But the graph does not clearly show this pattern, i need to filter the noise and make the constant portion more prominent in order to extract constant portions from plot. If anyone can help me in it.

채택된 답변

Walter Roberson
Walter Roberson 2016년 4월 28일
Use histc() or the newer histcounts() or quantiz() to quantize the values.
Your problem is not well specified in its current form. Are you looking for hard edges, or are you looking for relative movement? If you were looking for relative movement you could look at abs(diff(y)) but you then run the risk of missing gradual drift -- for example, 1.3:.05:2.8 never has more than the small 0.05 difference between any two adjacent values, but the overall change is 1.5; where would you want to put the breakpoints in such a case?
  댓글 수: 1
Ali Zeeshan
Ali Zeeshan 2016년 4월 29일
Walter, have a look on below plot, i need something like shown in red, and then want to extract points shown in green:
I want to ignore the curves that decreases suddenly from some point. I have applied one DPCM Encoding and Decoding Quantization method and its plot is also shown below.
My input values falls between the range of [0 1], so how can i define partition and codebook for it? In above Quantization plot i have used following partition and codebook
partition = [-1:.1:.9]; codebook = [-1:.1:1];

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Filter Analysis에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by