function snowfall_histogram ( )

%*****************************************************************************80
%
%% snowfall_histogram plots a histogram of yearly total snowfalls.
%
%  Licensing:
%
%    This code is distributed under the GNU LGPL license.
%
%  Modified:
%
%    30 April 2018
%
%  Author:
%
%    John Burkardt
%
  fprintf ( 1, '\n' );
  fprintf ( 1, 'snowfall_histogram:\n' );
  fprintf ( 1, '  MATLAB version\n' );
  fprintf ( 1, '  Make a histogram of yearly total snowfall data.\n' );

  y = load ( 'snowfall_data.txt' );

  [ m, n ] = size ( y );
  fprintf ( 1, '\n' );
  fprintf ( 1, '  %d x %d data records read from file.\n', m, n );
%
%  For simplicity, copy column 10, and call it "inches".
%
  inches = y(:,10);

  histogram ( inches );
  grid on
  xlabel ( '<-- Total Yearly Snow in Inches -->', 'Fontsize', 16 )
  ylabel ( '<-- Frequency -->', 'Fontsize', 16 )
  title ( 'Yearly Snowfall in Michigan', 'Fontsize', 16 )
%
%  Save the graphics in a file.
%
  filename = 'snowfall_histogram.png';
  print ( '-dpng', filename )
  fprintf ( 1, '\n' );
  fprintf ( 1, '  Graphics saved as "%s"\n', filename );
%
%  Terminate.
%
  fprintf ( 1, '\n' );
  fprintf ( 1, 'snowfall_histogram:\n' );
  fprintf ( 1, '  Normal end of execution.\n' );

  return
end

