[Dart-dev] DART/branches Revision: 12897
dart at ucar.edu
dart at ucar.edu
Mon Oct 8 15:41:12 MDT 2018
nancy at ucar.edu
2018-10-08 15:41:12 -0600 (Mon, 08 Oct 2018)
114
forgot to move the replacement of missing values.
it works better if that code comes before the reshape() call.
Modified: DART/branches/roms_interpolation/developer_tests/interpolation/work/plotit_irr.m
===================================================================
--- DART/branches/roms_interpolation/developer_tests/interpolation/work/plotit_irr.m 2018-10-08 21:28:02 UTC (rev 12896)
+++ DART/branches/roms_interpolation/developer_tests/interpolation/work/plotit_irr.m 2018-10-08 21:41:12 UTC (rev 12897)
@@ -3,14 +3,17 @@
nlon = length(lon(1,:));
nlat = length(lat(:,1));
-my_data = reshape(dat, nlon, nlat);
% look for missing r8s
missing_val = -888888;
inds = find(my_data==missing_val);
-if (~isempty(inds)), my_data(inds) = 0.; end
-%if (~isempty(inds)), my_data(inds) = nan; end
+% choose nan or 0 for plotting, whichever gives
+% the easiest-to-interpret results.
+if (~isempty(inds)), my_data(inds) = nan; end
+%f (~isempty(inds)), my_data(inds) = 0.; end
+my_data = reshape(dat, nlon, nlat);
+
scatter(lon, lat, msize, my_data,'filled');
%plot3(lon, lat, my_data);
%imagesc(lon, lat, my_data);
More information about the Dart-dev
mailing list