home *** CD-ROM | disk | FTP | other *** search
/ Liren Large Software Subsidy 10 / 10.iso / l / l460 / 2.ddi / PLOTXY.DI$ / XLABEL.M < prev    next >
Encoding:
Text File  |  1993-03-07  |  370 b   |  15 lines

  1. function xlabel(string)
  2. %XLABEL    X-axis labels for 2-D and 3-D plots.
  3. %     XLABEL('text') adds text below the X-axis on the current axis.
  4. %
  5. %    See also YLABEL, ZLABEL, TITLE, TEXT.
  6.  
  7. %    Copyright (c) 1984-93 by The MathWorks, Inc.
  8.  
  9. h = get(gca,'xlabel');
  10. if isempty(h)
  11.     h = text('HorizontalAlignment','center');
  12.     set(gca,'xlabel',h);
  13. end
  14. set(h,'string',string);
  15.