How do I apply a 1-D median filter and a moving average filter to this set of data?

3 views (last 30 days)
data = [ 10000 -1.202118049
14918.95558 -0.919568637
22257.52355 -0.332079504
33205.90052 -0.9507341
49539.73548 -0.311056814
73908.11129 -0.234900899
110263.1829 -0.909766624
164501.1528 0.249091768
245418.5391 -1.649532359
366138.8283 -0.890747269
546240.8915 -0.679462154
814934.3596 -0.546853842
1215796.951 -0.375618783
1813842.07 -0.598653135
2706062.927 0.195205505
4037163.26 0.207519359
6023025.934 0.288909309
8985725.636 -0.138220046
13405764.16 0.113403922
20000000 -1.157502068]; %Paste data in here

Accepted Answer

Image Analyst
Image Analyst on 18 Feb 2019
Try medfilt1():
filteredData = medfilt1(data, windowWidth);

More Answers (0)

Categories

Find more on Signal Generation and Preprocessing in Help Center and File Exchange

Community Treasure Hunt

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

Start Hunting!