1 | | = makeNcmlDataset = |
2 | | |
3 | | |
4 | | |
5 | | === ''__Description'' |
6 | | |
7 | | Generates a NcML file from a collection of netCDF files. |
8 | | |
9 | | |
10 | | === ''__Usage'' |
11 | | |
12 | | {{{ |
13 | | makeNcmlDataset(source.dir, ncml.file) |
14 | | }}} |
15 | | |
16 | | |
17 | | === ''__Arguments'' |
18 | | |
19 | | * `source.dir`: character string indicating a valid path of the directory containing the files |
20 | | * `ncml.file`: character string indicating the NcML file name (and path, default to working directory), including the extension ''.ncml''. |
21 | | |
22 | | The output is a NcML file named as `file.name` which will be stored in the `output.dir`. |
23 | | |
24 | | |
25 | | === ''__Details'' |
26 | | |
27 | | * All files of the same dataset should be put together in the same directory, indicated by the `source.dir` argument. |
28 | | * Currently the function works only with netCDF (''.nc'') file collections. |
29 | | * A number of useful recommendations regarding dataset naming are provided [http://www.unidata.ucar.edu/software/netcdf-java/reference/DatasetUrls.html#NcmlScan here] |
30 | | |
31 | | |
32 | | === ''__Value'' |
33 | | |
34 | | Creates a NcML file at the specified location |
35 | | |
36 | | === ''__Notes'' |
37 | | |
38 | | A NcML file is a [http://en.wikipedia.org/wiki/XML XML] representation of netCDF metadata. This is approximately the same information one gets when dumping the header of a netCDF file (e.g. by typing on the terminal the command `ncdump -h`). By means of NcML it is possible to create virtual datasets by modifying and aggregating other datasets, thus providing maximum flexibility and ease of access to data stored in collections of files containing data from different variables/time slices. The function `makeNcmlDataset` is intended to deal with reanalysis, forecasts and other climate data products, often consisting of collections of netCDF files corresponding to different variables and partitioned by years/decades or other time slices. It operates by applying to types of [http://www.unidata.ucar.edu/software/netcdf/ncml/v2.2/Aggregation.html aggregation operations]: |
39 | | |
40 | | 1. `Union`: Performs the union of all the dimensions, attributes, and variables in multiple NetCDF files |
41 | | 2. `JoinExisting`: Variables of the same name (in different files) are connected along their existing, outer dimension, called the aggregation dimension. In this case the aggregation dimension is ''time''. |
42 | | |
43 | | |
44 | | === ''__Examples'' === |
45 | | |
46 | | An example of this function is provided in the [wiki:SpecsEuporias/RPackage/Examples#loadSeasonalForecast Examples section] |
47 | | |
48 | | |
49 | | |
50 | | |
51 | | |
284 | | |
285 | | |
286 | | |
| 233 | = makeNcmlDataset = |
| 234 | |
| 235 | |
| 236 | |
| 237 | === ''__Description'' |
| 238 | |
| 239 | Generates a NcML file from a collection of netCDF files. |
| 240 | |
| 241 | |
| 242 | === ''__Usage'' |
| 243 | |
| 244 | {{{ |
| 245 | makeNcmlDataset(source.dir, ncml.file) |
| 246 | }}} |
| 247 | |
| 248 | |
| 249 | === ''__Arguments'' |
| 250 | |
| 251 | * `source.dir`: character string indicating a valid path of the directory containing the files |
| 252 | * `ncml.file`: character string indicating the NcML file name (and path, default to working directory), including the extension ''.ncml''. |
| 253 | |
| 254 | The output is a NcML file named as `file.name` which will be stored in the `output.dir`. |
| 255 | |
| 256 | |
| 257 | === ''__Details'' |
| 258 | |
| 259 | * All files of the same dataset should be put together in the same directory, indicated by the `source.dir` argument. |
| 260 | * Currently the function works only with netCDF (''.nc'') file collections. |
| 261 | * A number of useful recommendations regarding dataset naming are provided [http://www.unidata.ucar.edu/software/netcdf-java/reference/DatasetUrls.html#NcmlScan here] |
| 262 | |
| 263 | |
| 264 | === ''__Value'' |
| 265 | |
| 266 | Creates a NcML file at the specified location |
| 267 | |
| 268 | === ''__Notes'' |
| 269 | |
| 270 | A NcML file is a [http://en.wikipedia.org/wiki/XML XML] representation of netCDF metadata. This is approximately the same information one gets when dumping the header of a netCDF file (e.g. by typing on the terminal the command `ncdump -h`). By means of NcML it is possible to create virtual datasets by modifying and aggregating other datasets, thus providing maximum flexibility and ease of access to data stored in collections of files containing data from different variables/time slices. The function `makeNcmlDataset` is intended to deal with reanalysis, forecasts and other climate data products, often consisting of collections of netCDF files corresponding to different variables and partitioned by years/decades or other time slices. It operates by applying to types of [http://www.unidata.ucar.edu/software/netcdf/ncml/v2.2/Aggregation.html aggregation operations]: |
| 271 | |
| 272 | 1. `Union`: Performs the union of all the dimensions, attributes, and variables in multiple NetCDF files |
| 273 | 2. `JoinExisting`: Variables of the same name (in different files) are connected along their existing, outer dimension, called the aggregation dimension. In this case the aggregation dimension is ''time''. |
| 274 | |
| 275 | |
| 276 | === ''__Examples'' === |
| 277 | |
| 278 | An example of this function is provided in the [wiki:SpecsEuporias/RPackage/Examples#loadSeasonalForecast Examples section] |
| 279 | |
| 280 | |
| 281 | |
| 282 | |
| 283 | |
| 284 | |
| 285 | |
| 286 | |