adding requests to conda install docs
[JPSSData.git] / plot_bounds.m
blob39fb35ed08abd5870b9cd6bb1d8d0c0cf9f39d3d
1 function plot_bounds(lon,lat,U,L)
2 % Call:
3 % plot_bounds(lon,lat,U,L)
5 % Description:
6 % Plots the bounds to apply to SVM
8 % Inputs:
9 %   lon,lat  longitude and latitude coordinates
10 %   U        upper bounds
11 %   L        lower bounds
13 % Developed in Matlab 9.2.0.556344 (R2017a) on MACINTOSH.
14 % Angel Farguell (angel.farguell@gmail.com), 2019-06-17
15 %-------------------------------------------------------------------------
17 uu = U;
18 uu(uu==max(uu(:))) = nan;
19 nu = sum(sum(~isnan(uu)));
20 ll = L;
21 ll(ll==min(ll(:))) = nan;
22 nl = sum(sum(~isnan(ll)));
24 figure
25 S = repmat(5,nu,1);
26 C = repmat([1,0,0],nu,1);
27 hu = scatter3(lon(~isnan(uu)), lat(~isnan(uu)), uu(~isnan(uu)), S, C, 'filled');
28 alpha = 0.7;
29 set(hu, 'MarkerEdgeAlpha', alpha, 'MarkerFaceAlpha', alpha)
30 hold on
31 S = repmat(5,nl,1);
32 C = repmat([0.2,0.7,0.2],nl,1);
33 hl = scatter3(lon(~isnan(ll)), lat(~isnan(ll)), ll(~isnan(ll)), S, C, 'filled');
34 alpha = 0.2;
35 set(hl, 'MarkerEdgeAlpha', alpha, 'MarkerFaceAlpha', alpha)
38 end