~ubuntu-branches/ubuntu/lucid/nco/lucid

« back to all changes in this revision

Viewing changes to doc/man/ncrcat.1

  • Committer: Bazaar Package Importer
  • Author(s): Brian Mays
  • Date: 2002-02-07 05:42:36 UTC
  • Revision ID: james.westby@ubuntu.com-20020207054236-wgx5jyzn304fiqkb
Tags: 2.2.0-1
New upstream version.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
.TH NCRCAT 1
 
2
.SH NAME
 
3
ncrcat \- netCDF Record Concatenator
 
4
.SH SYNTAX
 
5
ncrcat [-A] [-C] [-c] [-D 
 
6
.IR dbg ]
 
7
[-d 
 
8
.IR dim ,[
 
9
.IR "min" ][,[
 
10
.IR max ]][,[
 
11
.IR stride ]]]
 
12
[-F]
 
13
[-h] [-l 
 
14
.IR path ]
 
15
[-n 
 
16
.IR loop ]
 
17
[-O] [-p 
 
18
.IR path ]
 
19
[-R] [-r] [-v 
 
20
.IR var [,...]]
 
21
[-x] 
 
22
.I input-files
 
23
.I output-file
 
24
.SH DESCRIPTION
 
25
.PP
 
26
.B ncrcat
 
27
concatenates record variables across an arbitrary number
 
28
of input files.
 
29
The final record dimension is by default the sum of the lengths of the
 
30
record dimensions in the input files.
 
31
.PP
 
32
Input files may vary in size, but each must have a record dimension.
 
33
The record coordinate, if any, should be monotonic (or else non-fatal
 
34
warnings may be generated).
 
35
Hyperslabs of the record dimension which include more than one file are
 
36
handled correctly.
 
37
.B ncra
 
38
supports the 
 
39
.I stride
 
40
argument to the 
 
41
.B -d
 
42
hyperslab option for the record dimension only, 
 
43
.I stride
 
44
is not
 
45
supported for non-record dimensions.
 
46
.PP
 
47
.B ncrcat
 
48
applies special rules to ARM convention time fields (e.g.,
 
49
.BR time_offset ).
 
50
.SH EXAMPLES
 
51
.PP
 
52
Concatenate files 
 
53
.BR 85.nc ,
 
54
.BR 86.nc ,
 
55
... 
 
56
.B 89.nc
 
57
along the record dimension, and store the results in 
 
58
.BR 8589.nc :
 
59
.RS
 
60
ncrcat 85.nc 86.nc 87.nc 88.nc 89.nc 8589.nc
 
61
.br
 
62
ncrcat 8[56789].nc 8589.nc
 
63
.br
 
64
ncrcat -n 5,2,1 85.nc 8589.nc
 
65
.RE
 
66
These three methods produce identical answers.
 
67
.PP
 
68
Assume the files 
 
69
.BR 85.nc ,
 
70
.BR 86.nc ,
 
71
... 
 
72
.B 89.nc
 
73
each
 
74
contain a record coordinate 
 
75
.I time
 
76
of length 12 defined such that
 
77
the third record in 
 
78
.B 86.nc
 
79
contains data from March 1986, etc.
 
80
NCO knows how to hyperslab the record dimension across files.
 
81
Thus, to concatenate data from December, 1985--February, 1986:
 
82
.RS
 
83
ncrcat -d time,11,13 85.nc 86.nc 87.nc 8512_8602.nc
 
84
.br
 
85
ncrcat -F -d time,12,14 85.nc 86.nc 87.nc 8512_8602.nc
 
86
.RE
 
87
The file 
 
88
.B 87.nc
 
89
is superfluous, but does not cause an error.
 
90
The 
 
91
.B -F
 
92
turns on the Fortran (1-based) indexing convention.
 
93
.PP
 
94
The following uses the 
 
95
.I stride
 
96
option to concatenate all the March
 
97
temperature data from multiple input files into a single output file
 
98
.RS
 
99
ncrcat -F -d time,3,,12 -v temperature 85.nc 86.nc 87.nc 858687_03.nc
 
100
.RE
 
101
.PP
 
102
Assume the 
 
103
.I time
 
104
coordinate is incrementally numbered such that
 
105
January, 1985 = 1 and December, 1989 = 60.
 
106
Assuming 
 
107
.B ??
 
108
only expands to the five desired files, the following
 
109
concatenates June, 1985--June, 1989: 
 
110
.RS
 
111
ncrcat -d time,6.,54. ??.nc 8506_8906.nc
 
112
.RE