function out = GetNextDataLine(FID)
%out = GetNextDataLine(FID)
%This function returns the next line of actual data from a file
%ignoring all whitespace or all comment lines
%returns -1 if EOF
%
%INPUT
%FID = pointer to file to be read
%
%OUTPUT
%out = formated string that has had all comments removed and 
%whitespace decreased to single spaces.  Returns -1 if EOF 
%
%Written by K. Steffen (ksteffen@unm.edu) at the University of New Mexico,
%Department of Earch and Planetary Science and copyrighted under the GNU
%public license, see APHID.m and www.gnu.org for details
%
%Last Modified June 17, 2003
test = 0;
while test == 0
	out = Parser(FID);

	if out == -2
		out = -1;
		return
	end
	if ischar(out)
		test = 1;
	end
end