%  Script to high-pass filter w for HW1, p3c

  load('rf18L1.txt');
  w = rf18L1(:,4);
  ns = length(w); 
  rate = 25;                         % Data rate

  cutoff = 0.1/rate;                 % Cutoff frequency 0.1 Hz
  [b, a] = butter(4,cutoff,'high');
  whi = filter(b,a,w);

%  Discard first ncutoff times; these are subject to
%  filter initialization errors

  ncut = round(1/cutoff);
  whi = whi(ncut+1:ns);
