1Dbg(3)                User Contributed Perl Documentation               Dbg(3)
2
3
4

NAME

6       PDL::Dbg - functions to support debugging of PDL scripts
7

SYNOPSIS

9              use PDL;
10              use PDL::Dbg;
11
12              $c = $a->slice("5:10,2:30")->px->diagonal(3,4);
13              PDL->px;
14

DESCRIPTION

16       This packages implements a couple of functions that should come in
17       handy when debugging your PDL scripts. They make a lot of sense while
18       you're doing rapid prototyping of new PDL code, let's say inside the
19       perldl shell.
20

FUNCTIONS

22       px
23
24       Print info about a piddle (or all known piddles)
25
26           perldl> PDL->px
27           perldl> $b += $a->clump(2)->px('clumptest')->sumover
28           perldl> $a->px('%C (%A) Type: %T')
29
30       This function prints some information about piddles. It can be invoked
31       as a class method (e.g. "PDL->px" ) or as an instance method (e.g.
32       "$pdl->px($arg)"). If
33
34       invoked as a class method
35         it prints info about all piddles found in the current package
36         (excluding "my" variables). This comes in quite handy when you are
37         not quite sure which pdls you have already defined, what data they
38         hold , etc. "px" is supposed to support inheritance and prints info
39         about all symbols for which an "isa($class)" is true. An optional
40         string argument is interpreted as the package name for which to print
41         symbols:
42
43           perldl> PDL->px('PDL::Mypack')
44
45         The default package is that of the caller.
46
47       invoked as an instance method
48         it prints info about that particular piddle if $PDL::debug is true
49         and returns the pdl object upon completion. It accepts an optional
50         string argument that is simply prepended to the default info if it
51         doesn't contain a "%" character. If, however, the argument contains a
52         "%" then the string is passed to the "info" method to control the
53         format of the printed information. This can be used to achieve cus‐
54         tomized output from "px". See the documentation of "PDL::info" for
55         further details.
56
57       The output of px will be determined by the default formatting string
58       that is passed to the "info" method (unless you pass a string contain‐
59       ing "%" to px when invoking as an instance method, see above). This
60       default string is stored in $PDL::Dbg::Infostr and the default output
61       format can be accordingly changed by setting this variable.  If you do
62       this you should also change the default title string that the class
63       method branch prints at the top of the listing to match your new format
64       string. The default title is stored in the variable $PDL::Dbg::Title.
65
66       For historical reasons "vars" is an alias for "px".
67
68       vars
69
70       Alias for "px"
71

BUGS

73       There are probably some. Please report if you find any. Bug reports
74       should be sent to the PDL mailing list perldl@jachw.hawaii.edu.
75

AUTHOR

77       Copyright(C) 1997 Christian Soeller (c.soeller@auckland.ac.nz).  All
78       rights reserved. There is no warranty. You are allowed to redistribute
79       this software / documentation under certain conditions. For details,
80       see the file COPYING in the PDL distribution. If this file is separated
81       from the PDL distribution, the copyright notice should be included in
82       the file.
83
84
85
86perl v5.8.8                       2002-05-21                            Dbg(3)
Impressum