Path: news.mathworks.com!newsfeed-00.mathworks.com!news.kjsl.com!feeder.erje.net!eu.feeder.erje.net!news.mixmin.net!aioe.org!.POSTED!not-for-mail
From: <HIDDEN>
Newsgroups: comp.soft-sys.matlab
Subject: Re: Interp1 Best Method?
Date: Wed, 17 Apr 2013 09:57:09 -0500
Organization: Aioe.org NNTP Server
Lines: 22
Message-ID: <kkmd7e$ajg$1@speranza.aioe.org>
References: <kkm41o$7ha$1@newscl01ah.mathworks.com>
NNTP-Posting-Host: ESh/+szx1ov8kvsN026/7g.user.speranza.aioe.org
Mime-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-Complaints-To: abuse@aioe.org
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.2.28) Gecko/20120306 Thunderbird/3.1.20
X-Notice: Filtered by postfilter v. 0.8.2
Xref: news.mathworks.com comp.soft-sys.matlab:793744

On 4/17/2013 7:20 AM, XLT_Frank wrote:
> Morning. I am looking to determine if interop1 is the best method for
> the following:
>
> data1 has two columns, time1 and sensor value. the intervals are on
> demand with 4000+ rows
>
> data2 has two columns, time2 and sensor value. the intervals are at 20Hz
> with 32,000+ rows
>
> I want to take data2 and realign with data1 because I only need to know
> the sensor values in data2 when the sensor value in data1 occurs. Is
> this method also okay when dealing with floating point values for my
> time code (still deciding on format of time vs. date vs. time and date
> serial).

I'd instead use the integer sampling rate as the time instead of float 
since you want an exact comparison and that's iffy w/ floating point and 
then use ISMEMBER  or INTERSECT.

--