|
17 | 17 | % get the version of ITS_LIVE, v02 is the latest version (by 2024-07) |
18 | 18 | % however, this version is in h5 format, can only be read by `h5read`, NOT `ncread` |
19 | 19 | data_version = getfieldvalue(options,'version', 2); |
| 20 | + |
| 21 | + % Greenland (default) or Antarctica |
| 22 | + hem = getfieldvalue(options,'hemisphere', 'n'); |
| 23 | + |
| 24 | + if strcmp(hem,'n') |
| 25 | + icesheet = 'Greenland'; |
| 26 | + else |
| 27 | + icesheet = 'Antarctica'; |
| 28 | + end |
| 29 | + |
20 | 30 | if data_version == 1 |
21 | | - foldername = '/totten_1/ModelData/Greenland/ITS_LIVE/v01/'; |
| 31 | + foldername = ['/totten_1/ModelData/', icesheet, '/ITS_LIVE/v01/']; |
22 | 32 | elseif data_version == 2 |
23 | | - foldername = '/totten_1/ModelData/Greenland/ITS_LIVE/'; |
| 33 | + foldername = ['/totten_1/ModelData/', icesheet, '/ITS_LIVE/']; |
24 | 34 | else |
25 | 35 | error(['ITS_LIVE version ', data_version, ' is not supported!']) |
26 | 36 | end |
|
43 | 53 | % find all the data files with Tstart<=t<=Tend |
44 | 54 | dataInd = (dataTime>=Tstart) & (dataTime<=Tend); |
45 | 55 | if ((Tstart ==0) & (Tend==0)) |
46 | | - disp(' Use ITS_LIVE composite 120 m velocity map '); |
| 56 | + disp([' Use ITS_LIVE composite 120 m velocity map for ', icesheet]); |
47 | 57 | else |
48 | | - disp([' For the selected period: ', datestr(decyear2date((Tstart)),'yyyy-mm-dd'), ' to ', datestr(decyear2date((Tend)),'yyyy-mm-dd'), ', there are ', num2str(sum(dataInd)), ' records' ]); |
| 58 | + disp([' For the selected period: ', datestr(decyear2date((Tstart)),'yyyy-mm-dd'), ' to ', datestr(decyear2date((Tend)),'yyyy-mm-dd'), ', there are ', num2str(sum(dataInd)), ' records for ', icesheet ]); |
49 | 59 | end |
50 | 60 |
|
51 | 61 | dataToLoad = {templist(dataInd).name}; |
|
0 commit comments