function matrix_bar3 ( )

%*****************************************************************************80
%
%% MATRIX_BAR3 uses a 3D bar plot to display outliers in a 5x6 data array.
%
%  Licensing:
%
%    This code is distributed under the GNU LGPL license.
%
%  Modified:
%
%    24 April 2018
%
%  Author:
%
%    John Burkardt
%
  fprintf ( 1, '\n' );
  fprintf ( 1, 'MATRIX_BAR3:\n' );
  fprintf ( 1, '  MATLAB version\n' );
  fprintf ( 1, '  Read a text file of a 5x6 array of data values.\n' );
  fprintf ( 1, '  Create a 3D bar plot to show outliers.\n' );
  fprintf ( 1, '  Call outliers() to find row and column outliers.\n' );
%
%  Read TXT file.
%
  data = load ( 'matrix.txt' );
  [ m, n ] = size ( data );
  check = isoutlier ( data );
%
%  Print data.
%
  fprintf ( 1, '\n' );
  fprintf ( 1, '  Data matrix:\n' );
  fprintf ( 1, '\n' );
  for i = 1 : m
    for j = 1 : n
      fprintf ( 1, ' %3d', data(i,j) );
    end
    fprintf ( 1, '\n' );
  end
%
%  Diagnose column outliers.
%
  check = isoutlier ( data );

  fprintf ( 1, '\n' );
  fprintf ( 1, '  Column outliers marked by "1"\n' );
  fprintf ( 1, '\n' );
  for i = 1 : m
    for j = 1 : n
      fprintf ( 1, ' %3d', check(i,j) );
    end
    fprintf ( 1, '\n' );
  end
%
%  Diagnose row outliers.
%
  check = ( isoutlier ( data' ) )';

  fprintf ( 1, '\n' );
  fprintf ( 1, '  Row outliers marked by "1"\n' );
  fprintf ( 1, '\n' );
  for i = 1 : m
    for j = 1 : n
      fprintf ( 1, ' %3d', check(i,j) );
    end
    fprintf ( 1, '\n' );
  end
%
%  Plot data.
%
  bar3 ( data )
  grid ( 'on' )
  xlabel ( '<-- Columns -->', 'FontSize', 16 )
  ylabel ( '<-- Rows -->', 'FontSize', 16 )
  title ( 'Looking for Data Outliers', 'FontSize', 24 )

  filename = 'matrix_bar3.png';
  print ( '-dpng', filename )
%
%  Terminate.
%
  fprintf ( 1, '\n' );
  fprintf ( 1, 'MATRIX_BAR3:\n' );
  fprintf ( 1, '  Normal end of execution.\n' );

  return
end
