function [piddat, vect] = readHfile(fname)
% function [pid, vect] = readHfile(fname)
%
% read raw VERTCON points file; return list of PIDS
% and corresponding lat/lon, datum, and ortho height
%
% INPUT
% fname name of file which includes raw height data
%
% OUTPUT
% pid     1 name of point (PID)
%         2 datum
% vect   dimensions (#PID x 4)
%         1-2 lat/long (deg)

% textread may be removed on future versions of Matlab, 
% which would require converting this to 'textscan' OR
% turning back on the slow method (below)
[pid, ht, datum, lat,lon] = textread(char(fname),...
                        '%s %*s %*s %f %s %*s %*s %*s %*s %f %f %*s %*s');
% PID state county ortho_ht datum load_date | PID state county lat lon
% datum
piddat{1} = pid;
piddat{2} = datum;
vect = [lat lon ht];