NAME

Chart::GGPlot::Labeller - Labeller functions for facets

VERSION

version 0.0009

DESCRIPTION

Labeller functions are in charge of formatting the strip labels of facet grids and wraps.

A labeller function has a signature of f(DataFrame $labels), and returns an array ref of labels.

CLASS METHODS

label_context($multi_line=true, $sep=': ')

Returns a labeller object, which is equivalent to label_value() for single factor faceting, and label_both() when multiple factors are involved.

as_labeller($x, $default='value', $multi_line=true)

This transforms objects to labeller functions.

my $appender = sub { $_[0] . '-foo' };
my $labeller = Chart::GGPlot::Labeller->as_labeller($appender);    

labeller(:$_rows=undef, :$_cols=undef, $_multi_line=true, :$_default='value', %params)

SEE ALSO

Chart::GGPlot::Facet

AUTHOR

Stephan Loyd <sloyd@cpan.org>

COPYRIGHT AND LICENSE

This software is copyright (c) 2019 by Stephan Loyd.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.