NAME
Data::Tabular::Extra
SYNOPSIS
This object is used by Data::Tabular
to create `extra' columns on a table.
The subroutines in the `extra' section run under this package.
...
extra => {
'bob' => sub {
my $self = shift; # this is a Data::Tabular::Extra object
}
}
...
DESCRIPTION
This object is used to supply tools to the Data::Tabular designer. It also helps to protect the data from that designer.
It is import to know that extra columns are created from left to right. Because of this you can use `extra' columns to create other extra columns. This means that you should order the extra columns in the order that they need to be created in, and not in the the order that they will be shown in the output.
Constructor
METHODS
- get
-
Method to access the data for a column. Given a list of column names this method returns a list of column data. Extra columns are available after they have been generated.
- sum
-
Method to sum a set of columns. Given a list of column names this method returns the sum of those columns. The type of the data returned is the type of the first column.
- average
-
Method to sum a set of columns. Given a list of column names this method returns the sum of those columns. The type of the data returned is column type element, but must conform to the Data::Tabular::Type::Frac constructor.
AUTHOR
"G. Allen Morris III" <gam3@gam3.net>