Home > marsbar > @marsy > display.m

display

PURPOSE ^

display method for marsy objects

SYNOPSIS ^

function display(obj)

DESCRIPTION ^

 display method for marsy objects

 $Id$

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 function display(obj)
0002 % display method for marsy objects
0003 %
0004 % $Id$
0005 
0006 src = '[MarsBaR data object]';
0007 if length(obj) > 1 % array of objects
0008   sz = size(obj);
0009   src = sprintf('%d by %d array of %s', sz(1), sz(2), src);
0010   if isequal(get(0,'FormatSpacing'),'compact')
0011     disp([inputname(1) ' =']);
0012     disp(src);
0013   else
0014     disp(' ')
0015     disp([inputname(1) ' =']);
0016     disp(' ');
0017     disp(src);
0018     disp(' ');
0019   end    
0020 else % single object
0021   X = char(summary(obj));
0022   if isequal(get(0,'FormatSpacing'),'compact')
0023     disp([inputname(1) ' =']);
0024     disp(src);
0025     disp(X)
0026   else
0027     disp(' ')
0028     disp([inputname(1) ' =']);
0029     disp(' ');
0030     disp(src);
0031     disp(' ');
0032     disp(X)
0033     disp(' ');
0034   end    
0035 end

Generated on Wed 11-May-2022 16:26:09 by m2html © 2003-2019