aboutsummaryrefslogtreecommitdiff
path: root/vendor/voclient/doc/votcnv.man
blob: 1a17fbeedb16cb10f400ccefdb3856a6f782b9a8 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
." @(#)votcnv.1 1.0 Feb-2013 MJF
.TH VOTCNV 1 "Feb 2013" "VOClient Package"
.SH NAME
votcnv \- Convert from VOTable to another format

.SH SYNOPSIS
\fBvotcnv\fP [\fI-opts\fP] votable.xml

.SH OPTIONS
The \fIvotcnv\fP task accepts the following options:
.TP 6
.B \-h, --help
Print a help summary to the terminal and exit.  No processing is done 
following this flag.
.TP 6
.B \-f \fIFMT\fP, --fmt \fIFMT\fP
Convert the VOTable to the format specified by \fIFMT\fP.  Allowed
formats are described below.
.TP 6
.B \-i \fINUM\fP, --indent \fINUM\fP
Indent each level of XML output by \fINUM\fP spaces.
.TP 6
.B \-n, --noheader
Suppress writing any header information.  This flag only applies to formats
other than FITS and VOTable.
.TP 6
.B \-o \fINAME\fP, --output \fINAME\fP
Write the result to the file \fINAME\fP.

.SH DESCRIPTION
The \fIvotcnv\fP task is used to convert a VOTable XML document to a
different format, or to rewrite a VOTable using (or removing) indention.
Creating a new VOTable document will fix any compliance issues since the
task will loosly read a VOTable on input but will always write an XML
file that complies with the VOTable specification.

The \fI\-f\fP (or \fI\--fmt\fP) flag is used to specify the new format using
one of the names listed below.   

.in 15
.I vot		
A new VOTable
.in 15
.I asv		
ASCII-separated (i.e. whitespace) values.
.in 15
.I bsv		
Bar-separated values.
.in 15
.I csv		
Comma-separated values
.in 15
.I tsv		
Tab-separated values
.in 15
.I html		
Standalone HTML document (entire table)
.in 15
.I shtml	
Single HTML table
.in 15
.I fits		
FITS bintable
.in 15
.I ascii	
ASV alias
.in 15
.I xml		
VOTable alias
.in 15
.I raw		
VOTable alias

.in 7
For formats such as CSV that normally 
include column headers, the \fI\-n\fP (or \fI\--noheader\fP) flag may be used
to suppress this header.  The FITS file produced will be an MEF containing
a bintable extension for each VOTable "<TABLE>" element.  Column types and
names in this case come from the VOTable "<FIELD>" attributes.

If no input file is specified the VOTable will be read from the stdin,
results will be written to stdout unless the \fI\-o\fP (or \fI\--output\fP)
names an output file.  The task will only process a single VOTable and may
not be used to convert multiple files in a single call.

.SH RETURN STATUS
On exit the \fBvotcnv\fP task will return a zero indicating success, or a 
one indicating an error.

.SH EXAMPLES
.TP 4
1) Convert a VOTable to a CSV file:

.nf
  % votcnv --fmt=csv test.xml
.fi
.TP 4
2) Rewrite a VOTable with readable indention:

.nf
  % votcnv -f vot -i 2 test.xml
.fi
.TP 4
3) Remove indention from a VOTable:

.nf
  % votcnv -f vot -i 0 test.xml
.fi
.SH BUGS
No known bugs with this release.
.SH Revision History
Feb 2013 - First public release
.SH Author
Michael Fitzpatrick (fitz@noao.edu), Feb 2013
.SH "SEE ALSO"
votget, votinfo, votpos, votsort, votstat