Code covered by the BSD License  

Highlights from
iff.m

5.0

5.0 | 3 ratings Rate this file 9 Downloads (last 30 days) File Size: 7.18 KB File ID: #20020
image thumbnail

iff.m

by Tom O'Haver

 

22 May 2008 (Updated 18 Sep 2009)

Interactive Fourier filter written as a single self-contained Matlab function.

| Watch this File

File Information
Description

function iff(x,y)
Interactive Fourier Filter function for data in arguments x,y, with sliders for interactive control of the center frequency, width, and shape of the filter. There are four operating modes: mode=0 for band-pass filter, linear plot;
mode=1 for band-pass filter, semilogx plot;
mode=2 for band-reject (notch) filter, linear plot;
mode=3 for band-reject (notch) filter, semilogx plot.
Shape determines the sharpness of the cut-off. If shape =1, the filter is Gaussian; as shape increases the filter shape becomes more and more rectangular.

Declares global variables IFFDATA and IFFPARAMETERS. Filtered signal is returned in the global variable IFFDATA(3,:,:), so declare IFFDATA as global before calling iff.m to have access to IFFDATA outside of iff.m

T. C. O'Haver (toh@umd.edu), version 3, June 2008. Slider function by matthew jones (matt_jones@fastmail.fm), 2004

MATLAB release MATLAB 6.5 (R13)
Tags for This File  
Everyone's Tags
Tags I've Applied
Add New Tags Please login to tag files.
Comments and Ratings (5)
07 Dec 2009 Ian Howat

??? Index exceeds matrix dimensions.

Error in ==> iff>RedrawFourierFilter at 152
if length(fy)>length(ffilter), ffilter=[ffilter ffilter(1)];end

Error in ==> iff>iffwidth at 103
ry=RedrawFourierFilter(x,y,center,width,shape,mode);

Error in ==> iff>butdownfcn at 478
            feval(params.funhand{l},out,params.h2(l)); % evaluate
            using feval()

??? Error while evaluating figure WindowButtonDownFcn

07 Dec 2009 Ian Howat

whoops - sorry - didnt mean to give you one a rating without giving you the chance to fix this first- here's 5 stars to help even it out.

17 Feb 2010 Andre Guy Tranquille  
09 Aug 2010 Igor

To Ian H.:
x and y must be row vectors.

03 Jun 2011 Tom O'Haver

I've uploaded a new keyboard-operated interactive Fourier filer that works in recent versions of Matlab - tested in 7.8(R2009a). See http://www.mathworks.com/matlabcentral/fileexchange/31646-ifilter-interactive-fourier-filter-function

Please login to add a comment or rating.
Updates
28 May 2008

Change description

24 Jun 2008

bug fixes

18 Sep 2009

Slider function modified by commenting out lines 337 and 373
to prevent crash on Matlab 20078 and 2009.

Tag Activity for this File
Tag Applied By Date/Time
filter design Tom O'Haver 22 Oct 2008 10:02:57
filter analysis Tom O'Haver 22 Oct 2008 10:02:57
interactive fourier filter function Tom O'Haver 22 Oct 2008 10:02:57
filter analysis Graeme Lawson 17 Jul 2009 13:39:16
filter design Taufik Abrao 19 Sep 2009 18:05:03

Contact us at files@mathworks.com