STILTS-TPIPE(1)
β¨ STILTS-TPIPE β the stilts tpipe manual, bestie edition π
okay so hi, welcome to stilts-tpipe(1), a page from the Stilts commands collection, and I am so excited to walk you through it. grab a snack. π
π NAME π
stilts-tpipe β it does pipeline processing on a table. that's the whole vibe. π
π¦ SYNOPSIS π¦
stilts tpipe [ifmt=<in-format>] [istream=true|false] [in=<table>]
[cmd=<cmds>]
[omode=out|meta|stats|count|checksum|cgi|discard|topcat|samp|tosql|gui]
[out=<out-table>] [ofmt=<out-format>]
πΈ DESCRIPTION πΈ
okay so tpipe is the general purpose manipulation queen. it takes one table as input and then does literally whatever you want to it. it's extremely flexible, no cap. here's a taste of the stuff it can do, amongst other things:
- calculate statistics π
- display metadata
- select rows in various ways, including algebraically
- define new columns as algebraic functions of old ones β¨
- delete or rearrange columns
- sort rows
- convert between table formats
β¦and then combine all of those operations. think of it as a supercharged table copying tool. it's giving glow-up. π
the basic operation of tpipe is: it reads an input table, performs zero or more processing steps on it, and then does something with the output. so there are three classes of things you need to tell it when it runs:
Input table location β specified by the in, ifmt and istream parameters. π
Processing steps β you either provide a string giving steps as the value of one or more cmd parameters, or the name of a file containing the steps using the script parameter. the steps you can perform are described in SUN/256. π
Output table destination β what happens to the output table is determined by the value of the omode parameter. by default, omode=out, in which case the table is written to a new table file in a format determined by ofmt. however, you can do other things with the result, such as calculate the per-column statistics (omode=stats), view only the table and column metadata (omode=meta), display it directly in TOPCAT (omode=topcat), etc. see SUN/256 for a more detailed explanation of these ideas. π
all the parameters mentioned above are listed in detail in the next section. obviously. π
β¨ OPTIONS β¨
ifmt=<in-format>β tellstpipewhat format the input table (the one from theinparameter) is in. the known formats are listed in SUN/256. this flag is here for when you already know what format your table is. if it's set to the special value(auto)(which is the default), it'll try to detect the format automatically. heads up though: that can't always be done correctly, and if it can't, the program exits with an error explaining which formats it attempted. π« also, this parameter is ignored for scheme-specified tables.istream=true|falseβ if you set this true, the input table given by theinparameter gets read as a stream. in that case you have to give theifmtparameter. depending on the operations you asked for and the processing mode, this can make the read fail (sometimes the table needs to be read more than once, bestie π). you don't normally need to set this flag β in most cases the data streams automatically if that's the best thing to do. but sometimes it can mean less resource usage when processing large files in certain formats (like VOTable). this parameter is ignored for scheme-specified tables.in=<table>β the location of the input table. it can take one of these forms:- a filename.
- a URL.
- the special value
-, meaning standard input. in that case the input format must be given explicitly using theifmtparameter. note that not all formats can be streamed this way. π - a scheme specification of the form
:<scheme-name>:<scheme-args>. - a system command line with either a
"<"character at the start, or a"|"character at the end ("<syscmd"or"syscmd|"). this executes the given pipeline and reads from its standard output. this will probably only work on unix-like systems. π»
in any case, compressed data in one of the supported compression formats (gzip, Unix compress or bzip2) will be decompressed transparently. π
cmd=<cmds>β specifies processing to be performed on the input table given by theinparameter, before any other processing has taken place. the value is one or more of the filter commands described in SUN/256. if you give more than one, they must be separated by semicolon characters (;). you can repeat this parameter multiple times on the same command line to build up a list of processing steps. the sequence of commands given this way defines the processing pipeline that gets performed on the table. ποΈ
commands can alternatively be supplied in an external file, using the indirection character @. so a value of "@filename" causes the file filename to be read for a list of filter commands to execute. the commands in the file may be separated by newline characters and/or semicolons, and lines which are blank or which start with a # character are ignored. a backslash character '\' at the end of a line joins it with the following line. π§΅
omode=out|meta|stats|count|checksum|cgi|discard|topcat|samp|tosql|guiβ the mode in which the result table will be output. the default mode isout, which means the result gets written as a new table to disk or elsewhere, as determined by theoutandofmtparameters. but there are other possibilities, which correspond to uses a table can be put to other than outputting it β like displaying metadata, calculating statistics, or populating a table in an SQL database. for some values of this parameter, additional parameters (<mode-args>) are required to determine the exact behaviour. π
possible values are:
outmetastatscountchecksumcgidiscardtopcatsamptosqlgui
use the help=omode flag or see SUN/256 for more information.
out=<out-table>β the location of the output table. usually a filename to write to. if it equals the special value-(the default), the output table gets written to standard output. π¨οΈ
this parameter must only be given ifomodehas its default value of"out".
ofmt=<out-format>β specifies the format in which the output table will be written (one of the ones in SUN/256 β matching is case-insensitive and you can use just the first few letters). if it has the special value(auto)(the default), the output filename gets examined to try to guess what sort of file is required, usually by looking at the extension. if it's not obvious from the filename what output format is intended, an error will result. π΅
this parameter must only be given ifomodehas its default value of"out".
π SEE ALSO π
stilts(1)
if the package stilts-doc is installed, the full documentation SUN/256 is available in HTML format: file:///usr/share/doc/stilts/sun256/index.html π
π VERSION π
STILTS version 3.5.4-debian
this is the Debian version of Stilts, which lack the support of some file formats and network protocols. for differences see file:///usr/share/doc/stilts/README.Debian π§
π AUTHOR π
Mark Taylor (Bristol University)
and that's the whole page, bestie!! π«Ά written by Mark Taylor (Bristol University), from Mar 2017, STILTS version 3.5.4-debian β you ate that, go run some pipelines π β¨ππ¦
π¦ where this page comes from
- ubuntu stonking: stilts 3.5.4-1 Β· LGPL-2.1-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms