datautils - data manipulation

  • row2tab
    • row2tab - transform rows data into table data
  • nrm
    • nrm - normalize data
  • col
    • col - print columns from data
  • win
    • win - make time-windows on data
  • dat
    • dat - data processor
  • nomenclature
    • nom2pl - nomenclature to perl code convertor

18Nov201233kBrow2tab-0.1.tar.bz2
21Sep20085kBnomenclature.0.2.arch.tar.bz2
20Sep20085kBnomenclature.0.2.tar.bz2
8Aug20085kBdat.0.2.tar.bz2
8Aug20083kBcol.0.2.tar.bz2
8Aug20085kBwin.0.2.tar.bz2
8Aug20085kBnrm.0.2.tar.bz2
12Jun20084kBnomenclature.0.1.tar.bz2
8Oct20032kBcol.0.1.tar.bz2
8Oct20034kBdat.0.1.tar.bz2
9Mar20015kBnrm.0.1.tar.bz2
8Mar20015kBwin.0.1.tar.bz2

row2tab: row2tab -h

Name

row2tab - transform rows data into table data

Usage

rowdata [OPTIONS] FILE [SPECS] ...

Description

The row2tab reads the FILE where every row represents single data field and transform them into table according to requested structure.

Specs

The SPECS arguments let the row2tab know whether given field is numerical or text. After given number of fields is read, row2tab will start with next line in tab with the first spec. Known specs are:

n
Numerical field.
t
Text field.
mt
Multiline text field, spanning lines until first nontext field or empty line.

Options

-e
Don't skip empty lines.
-w
Don't remove leading/trailing whitespaces from lines.
-p
Plain text fields without multiwhites inside.
-sleep
Sleep for 50 miliseconds after every input line.
-h
This help.
-d
Debug messages.

Debug

Debug messages can be switched on/off by strains. Available strains are: arg, input.

-d STRAIN[,STRAIN...]
Debug only specified strains.
-d -STRAIN
Prefix the strain with "-" to avoid it.

Example

The file:

1
2 xy 2 12 oe

will be transformed by "row2tab file n n t" into:

1 2 xy
2 12 oe

Version

row2tab.0.1 © R.Jaksa 2012, GPLv3


nrm: nrm -h

Name

nrm - normalize data

Usage

nrm [OPTIONS] [FILE1 SPECS] [FILE2 SPECS] ...

Specs

filename [OPTIONS] CON1 [CON2] [CON3] ...

Description

The nrm changes (normalizes) values in specified columns in specified files. Column/row numbering starts with 1 (not with 0).

Options

-h
This help.
-v
Verbose mode.
-o FILE
Output file (default: STDOUT).
-dlo VAL
Delimiter for output (default: " ").
-dli VAL
Delimiter for input (default: "[ \t\n]+").
-nlo VAL
Newline delimiter in output (default: "\n").
-th VAL
Hard text-field size limit (default: "NONE").
-ts VAL
Soft text-field size limit (default: "NONE").
-d VAL
Default value for empty input fields (default: "NONE").
-r VAL
Default value for rounding of normalization (default: "3").
-n
Line numbering.
-m
Column numbering (matrix like together with -n).
-nr
Line numbering (real lines in src file).
-t
Transpose rows to columns (in the output).
-tc
Colorize text fields.
-bw
Black & white output, no colors.

Constrains

3
Include column 3 in original state.
2-4
Columns 2,3,4.
2:n
Normalize column 2.
2-6:n
Normalize columns 2,3,4,5,6.
5:n[-1,1]
Normalize to interval <-1,1>.
5:n[1,3][0,2]
Set min/max value for normalization to 0/2.
6-8:b
Binarize columns 6,7,8.
4:b[6]
Binarize to 6 bits.
h[ - ]
Include column with the value " - ".

Install

  1. Correct the #!/bin/perl path in the 1st line of nrm file to point to your perl binary.
  2. Copy the nrm file into some your .../bin directory.

Version

nrm.0.2 © R.Jaksa 2001, GPLv3


col: col -hh

Name

col - print columns from data

Usage

col [OPTIONS] [FILE1 SPECS] [FILE2 SPECS] ...

Specs

filename [OPTIONS] CON1 [CON2] [CON3] ...

Description

The col prints specified columns from specified files. First column number is 1 (not 0).

Options

-h
This help.
-v
Verbose mode.
-o FILE
Output file (default: STDOUT).
-e VAL
Default value for empty input fields (default: "0").
-do VAL
Delimiter for output (default: " ").
-th VAL
Hard text-field size limit (default: "NONE").
-ts VAL
Soft text-field size limit (default: "NONE").

See also

The col is obsoleted by the dat.

Install

  1. Correct the #!/bin/perl path in the 1st line of col file to point to your perl binary.
  2. Copy the col file into some your .../bin directory.

Version

col.0.2 © R.Jaksa 2003, GPLv3


win: win -h

Name

win - make time-windows on data

Usage

win [OPTIONS] [FILE1 SPECS] [FILE2 SPECS] ...

Specs

filename [OPTIONS] CON1 [CON2] [CON3] ...

Description

The win makes time-windows of specified size on specified values in specified files. Column/row numbering starts with 1 (not with 0).

Options

-h
This help.
-v
Verbose mode.
-o FILE
Output file (default: STDOUT).
-dlo VAL
Delimiter for output (default: " ").
-wlo VAL
In-window delimiter for output (default: " ").
-dli VAL
Delimiter for input (default: "[ \t\n]+").
-nlo VAL
Newline delimiter in output (default: "\n").
-th VAL
Hard text-field size limit (default: "NONE").
-ts VAL
Soft text-field size limit (default: "NONE").
-d VAL
Default value for empty input fields (default: "NONE").
-r VAL
Default value for rounding of normalization (default: "8").
-pl VAL
Only include last VAL patterns (rows) (default: "NONE").
-n
Line numbering.
-m
Column numbering (matrix like together with -n).
-nr
Line numbering (real lines in src file).
-t
Transpose rows to columns (in the output).
-tc
Colorize text fields.
-bw
Black & white output, no colors.

Constrains

3
Include column 3 (no time window).
2-4
Columns 2,3,4.
2:w[3]
Time window of depth 3 on column 2.
2-6:w
Windows on columns 2,3,4,5,6.
5:w[6:2]
Depth 6, but only every 2nd sample.
3:w[1,2,5]
Samples t-1,t-2,t-5; column 3.
h[-#-]
Include column with value '-#-'.

Install

  1. Correct the #!/bin/perl path in the 1st line of win file to point to your perl binary.
  2. Copy the win file into some your .../bin directory.

Version

win.0.2 © R.Jaksa 2001, GPLv3


dat: dat -h

Name

dat - data processor

Usage

dat [OPTIONS] [FILE1 SPECS] [FILE2 SPECS] ...

Specs

filename [OPTIONS] CON1 [CON2] [CON3] ...

Description

The dat prints specified columns and/or rows from specified files. Column/row numbering starts with 1 (instead of 0). When formatting the data, the dot considers constrains CON1 CON2 CON3... Row constraints are in the "or" relation. Column constrains are in the "or" relation too. Row to column constrains are in the "and" relation.

Options

-h
This help.
-v
Verbose mode.
-o FILE
Output file (default: STDOUT).
-dlo VAL
Delimiter for output (default: " ").
-dli VAL
Delimiter for input (default: "[ \t\n]+").
-nlo VAL
Newline delimiter in output (default: "\n").
-th VAL
Hard text-field size limit (default: "NONE").
-ts VAL
Soft text-field size limit (default: "NONE").
-d VAL
Default value for empty input fields (default: "NONE").
-n
Line numbering.
-m
Column numbering (matrix like together with -n).
-nr
Line numbering (real lines in src file).
-t
Transpose rows to columns (in the output).
-tc
Colorize text fields.
-bw
Black & white output, no colors.

Constrains

21
Column number 21.
2-6
Column numbers 2,3,4,5,6.
r4
Row number 4.
r6-8
Row numbers 6,7,8.
6:2.5
All rows containing value 2.5 in the column 6.
8:3-7
All rows containing values from interval <3,7> in column 8.
7:d
All rows (1st ones) with different values in column 7.
7:dn
Like 7:d, but accept only numeric values.

Install

  1. Correct the #!/bin/perl path in the 1st line of dat file to point to your perl binary.
  2. Copy the dat file into some your .../bin directory.

Version

dat.0.2 © R.Jaksa 2003, GPLv3


nomenclature: nom2pl -h

Name

nom2pl - nomenclature to perl code convertor

Usage

nom2pl [OPTIONS] DOMAINS

Description

Converts nomenclature database into perl code.

Domains

Spaces separated list of nomenclatures domains to be included in the resulting perl code.

Options

-h
This help.
-d
Debug.
-d2
Debug level 2.
-o
FILE Write output into FILE.

Version

nomenclature-0.2 © R.Jaksa 2008, GPLv3



18.11.2012