show_polygonsValues

PURPOSE ^

SYNOPSIS ^

function show_polygonsValues(imdl,data,colors,edgeColor,lineStyle)

DESCRIPTION ^

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 function show_polygonsValues(imdl,data,colors,edgeColor,lineStyle)
0002 
0003 if nargin<3
0004     colors= 'jet';
0005     edgeColor= 'none';
0006     lineStyle= '-';
0007 elseif nargin<4
0008     edgeColor= 'none';
0009     lineStyle= '-';
0010 elseif nargin<5
0011     edgeColor= 'none';
0012     lineStyle= '-';    
0013 end
0014 
0015 if isfield(imdl,'inv_solve')
0016 polygonsX= imdl.inv_solve.polygonsX;
0017 polygonsY= imdl.inv_solve.polygonsY;
0018 elseif isfield(imdl,'polygonsX')
0019 polygonsX= imdl.polygonsX;
0020 polygonsY= imdl.polygonsY;
0021 end
0022 
0023 if size(data,1)>1 % data must be a row vector
0024     data= data';
0025 end
0026 if size(polygonsX,2)~= size(data,2)
0027     polygonsX= polygonsX';
0028 end
0029 if size(polygonsY,2)~= size(data,2)
0030     polygonsY= polygonsY';
0031 end
0032 
0033 fill(polygonsX,polygonsY,data,'EdgeColor',edgeColor,'LineStyle',lineStyle);
0034 hold on;
0035 % colorbar
0036 if ischar(colors)
0037     colormap(colors)
0038 else
0039     set(gcf,'Colormap',colors)
0040 end
0041 
0042 
0043 end

Generated on Tue 31-Dec-2019 17:03:26 by m2html © 2005