7 |
|
[ |
8 |
|
.B \-tS |
9 |
|
][ |
10 |
+ |
.B \-u |
11 |
+ |
][ |
12 |
|
.B \-iaN |
13 |
|
| |
14 |
|
.B \-ifN |
15 |
|
| |
16 |
|
.B \-idN |
17 |
|
| |
18 |
+ |
.B \-iiN |
19 |
+ |
| |
20 |
|
.B \-iwN |
21 |
+ |
| |
22 |
+ |
.B \-ibN |
23 |
+ |
][ |
24 |
+ |
.B "\-in M" |
25 |
|
] |
26 |
|
input1 input2 .. |
27 |
|
.SH DESCRIPTION |
28 |
|
.I Rlam |
29 |
|
simply joins records (or lines) from multiple inputs, separating them with |
30 |
< |
the given separator string (TAB by default). |
30 |
> |
the given string (TAB by default). |
31 |
|
Different separators may be given for different files by specifying |
32 |
|
additional |
33 |
|
.I \-t |
34 |
|
options in between each file name. |
35 |
+ |
Note that there is no space between this option and its argument. |
36 |
|
If none of the input files uses an ASCII separator, then no end-of-line |
37 |
|
character will be printed, either. |
38 |
|
.PP |
50 |
|
Similarly, the |
51 |
|
.I \-id |
52 |
|
and |
53 |
< |
.I \-iw |
53 |
> |
.I \-ii |
54 |
|
options may be used to indicate binary 64-bit doubles or integer words, |
55 |
|
respectively. |
56 |
< |
If an number is immediately follows any of these options, then it |
56 |
> |
The |
57 |
> |
.I \-iw |
58 |
> |
option specifies 2-byte short words, and the |
59 |
> |
.I \-ib |
60 |
> |
option specifies bytes. |
61 |
> |
If a number is immediately follows any of these options, then it |
62 |
|
indicates that multiple such values are expected for each record. |
63 |
|
For example, |
64 |
|
.I \-if3 |
68 |
|
option, no number indicates one line per input record, and numbers |
69 |
|
greater than zero indicate that many characters exactly per record. |
70 |
|
For binary input formts, no number implies one value per record. |
71 |
+ |
For anything other than EOL-separated input, the default tab separator |
72 |
+ |
is reset to the empty string. |
73 |
|
.PP |
74 |
+ |
If a |
75 |
+ |
.I \-in |
76 |
+ |
option is given with a positive integer argument, this will be the |
77 |
+ |
maximum number of records that will be read or produced by |
78 |
+ |
.I rlam. |
79 |
+ |
.PP |
80 |
|
A hyphen ('-') by itself can be used to indicate the standard |
81 |
|
input, and may appear multiple times. |
82 |
+ |
The |
83 |
+ |
.I \-u |
84 |
+ |
option forces output after each record (i.e., one run through inputs). |
85 |
|
.SH EXAMPLE |
86 |
|
To join files output1 and output2, separated by a comma: |
87 |
|
.IP "" .2i |
88 |
< |
rlam -t, output1 output2 |
88 |
> |
rlam \-t, output1 output2 |
89 |
|
.PP |
90 |
|
To join a file with line numbers (starting at 0) and its reverse: |
91 |
|
.IP "" .2i |
92 |
< |
cnt `wc -l < lam.c` | rlam - -t: lam.c -t\| '!tail -r lam.c' |
92 |
> |
cnt `wc \-l < lam.c` | rlam \- \-t: lam.c \-t\| '!tail \-r lam.c' |
93 |
|
.PP |
94 |
|
To join four data files, each having three doubles per record: |
95 |
|
.IP "" .2i |
96 |
< |
rlam -id3 -t file1.dbl file2.dbl file3.dbl file4.dbl > combined.dbl |
96 |
> |
rlam \-id3 file1.dbl file2.dbl file3.dbl file4.dbl > combined.dbl |
97 |
|
.SH AUTHOR |
98 |
|
Greg Ward |
99 |
|
.SH "SEE ALSO" |