Programming |
The portfolio display
method lists the contents of each contained object by calling the object's display
method. It then lists the client name and total asset value.
function display(p) % DISPLAY Display a portfolio object for k = 1:length(p.indAssets) display(p.indAssets{k}) end stg = sprintf('\nAssets for Client: %s\nTotal Value: %9.2f\n',... p.name,p.totalValue); disp(stg)
The Portfolio Constructor Method | The Portfolio pie3 Method |
© 1994-2005 The MathWorks, Inc.