decol
A tool to drop or keep columns from a CSV file.
Features
- columns can be specified as 1-based integer indexes or column headers
- multiple indexes or headers can be specified as a comma-separated list
- negative indexes are supported
- index ranges are also supported, e.g. 1:2 for the first two column
Usage
$ decol -h
Usage: decol [OPTIONS] INPUT OUTPUT
A tool to drop or keep columns from a CSV file.
Options:
-c, --columns COLUMNS Comma-separated list of 1-based column indexes
to remove. Negative integers will index from the
end. May use a range, e.g. 1:2 or -3:-2 for
first and second of three columns. Ranges must
always be given in left to right column order
for both positive and negative indexes. Mutually
exclusive with --headers.
-H, --headers HEADERS Comma-separated list of columns to remove by
first-line header. Mutually exclusive with
--columns.
-s, --sep SEPARATOR Column separator. [default: ,]
-o, --output-sep SEPARATOR Output column separator. [default: --sep value]
--keep Keep only the specified columns in the order
specified in --columns or --headers. [default:
False]
--version Show the version and exit.
-h, --help Show this message and exit.
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
decol-1.1.7.tar.gz
(6.7 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file decol-1.1.7.tar.gz.
File metadata
- Download URL: decol-1.1.7.tar.gz
- Upload date:
- Size: 6.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fe90f8a929ae8e560475f0ae9990050679e0e6dd742686f22bf691d955dae925
|
|
| MD5 |
83179c447918d81ed86e050ea3203327
|
|
| BLAKE2b-256 |
0f1fc003fb9e77ab36b510219c05d19b9d896a5321568f4cd113509c1da5f5c3
|
File details
Details for the file decol-1.1.7-py2.py3-none-any.whl.
File metadata
- Download URL: decol-1.1.7-py2.py3-none-any.whl
- Upload date:
- Size: 6.1 kB
- Tags: Python 2, Python 3
- Uploaded using Trusted Publishing? No
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0b41d428a4b6b3ae8282a3e4c130f76c0943e78dbfc1ffc65a68a76b9dcbb65b
|
|
| MD5 |
aee515bed34c54b50ff7bba71c4e9871
|
|
| BLAKE2b-256 |
0fe3e16b1d6649830a42a942eb7f9ec8ccf50b4a3eb947608e0bba4ac3e6fb1a
|