function president_heights_prepare ( )

%*****************************************************************************80
%
%% PRESIDENT_HEIGHTS_PREPARE extracts data from a CSV file, writes to TXT file.
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    18 July 2018
%
%  Author:
%
%    John Burkardt
%
  timestamp ( );
  fprintf ( 1, '\n' );
  fprintf ( 1, 'PRESIDENT_HEIGHTS_PREPARE:\n' );
  fprintf ( 1, '  MATLAB/Octave version %s:\n', version ( ) );
  fprintf ( 1, '  Read a president/height CSV file.\n' );
  fprintf ( 1, '  Write a height TXT file.\n' );
%
%  Read the CSV file.
%
  filename = 'president_heights_data.csv';
  data = csvread ( filename, 1, 1 );
%
%  Save the array.
%
  filename = 'president_heights_data.txt';
  save ( filename, '-ascii', 'data' );
  fprintf ( 1, '\n' );
  fprintf ( 1, '  Data saved to file "%s"\n', filename );
%
%  Terminate.
%
  fprintf ( 1, '\n' );
  fprintf ( 1, 'PRESIDENT_HEIGHTS_PREPARE:\n' );
  fprintf ( 1, '  Normal end of execution.\n' );
  timestamp ( );

  return
end

