Extract data at regular intervals

Hi There,
I have 2 columns of data, time and concentration. The time data are at intervals of about 5 seconds and there is a corresponding concentration measurement at each time. There are about 20,000 time measurements and I want to reduce this to a more manageable amount. How can I obtain say every 10th time x concentration value?
Thanks

 Accepted Answer

Wayne King
Wayne King on 21 Jun 2013
Edited: Wayne King on 21 Jun 2013
Are you asking for just
X = ones(2e4,2);
Y = X(1:10:end,:);
Y is a two-column matrix containing every 10-th measurement (or measurements taken every 50 seconds).

2 Comments

Thanks
hi can you share your program

Sign in to comment.

More Answers (0)

Categories

Find more on Risk Management Toolbox in Help Center and File Exchange

Asked:

on 21 Jun 2013

Commented:

on 23 Jul 2020

Community Treasure Hunt

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

Start Hunting!