Data::Printer::Filter::PDL
version 0.007
use PDL; use Data::Printer; my $pdl = sequence(10,10); p $pdl; __END__ PDL { Data : [ [0 1] [2 3] ] Type : double Shape : [2 2] Nelem : 4 Min : 0 Max : 3 Badflag : No Has Bads : No }
This module provides formatting for PDL data that can be used to quickly see the contents of a PDL variable.
Data::Printer::Filter::PDL - Filter for Data::Printer that handles PDL data.
Modify $PDL::toolongtoprint to control when the contents of piddles with many elements are displayed.
$PDL::toolongtoprint
You will want to configure Data::Printer to use this module by creating a .dataprinter file in your $HOME directory:
{ colored => 1, filters => { -external => [ 'PDL' ], } };
If you are using this module with the plugin Devel::REPL::Plugin::DataPrinter, you may want to add the following to your repl.rc or .perldlrc so that PDL subclass data is displayed correctly in Devel::REPL:
repl.rc
.perldlrc
$_REPL->dataprinter_config({ stringify => { 'PDL::Char' => 0, 'PDL::Complex' => 0, }, });
Report bugs and submit patches to the repository on GitHub.
Data::Printer, PDL, Devel::REPL::Plugin::DataPrinter
Copyright 2013 Zakariyya Mughal.
This program is free software; you can redistribute it and/or modify it under the terms of the Artistic License version 2.0.
Thanks to Joel Berger for the original code that this was based upon.
Zakariyya Mughal <zmughal@cpan.org>
This software is copyright (c) 2013 by Zakariyya Mughal.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
To install Data::Printer::Filter::PDL, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Data::Printer::Filter::PDL
CPAN shell
perl -MCPAN -e shell install Data::Printer::Filter::PDL
For more information on module installation, please visit the detailed CPAN module installation guide.