Programming and Data Types | ![]() ![]() |
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.ind_assets) display(p.ind_assets{k}) end stg = sprintf('\nAssets for Client: %s\nTotal Value: %9.2f\n',... p.name,p.total_value); disp(stg)
![]() | The Portfolio Constructor Method | The Portfolio pie3 Method | ![]() |