.\" Automatically generated by Pod::Man 4.14 (Pod::Simple 3.40) .\" .\" Standard preamble: .\" ======================================================================== .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" Set up some character translations and predefined strings. \*(-- will .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left .\" double quote, and \*(R" will give a right double quote. \*(C+ will .\" give a nicer C++. Capital omega is used to do unbreakable dashes and .\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff, .\" nothing in troff, for use with C<>. .tr \(*W- .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p' .ie n \{\ . ds -- \(*W- . ds PI pi . if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch . if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch . ds L" "" . ds R" "" . ds C` "" . ds C' "" 'br\} .el\{\ . ds -- \|\(em\| . ds PI \(*p . ds L" `` . ds R" '' . ds C` . ds C' 'br\} .\" .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" .\" If the F register is >0, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .\" .\" Avoid warning from groff about undefined register 'F'. .de IX .. .nr rF 0 .if \n(.g .if rF .nr rF 1 .if (\n(rF:(\n(.g==0)) \{\ . if \nF \{\ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . if !\nF==2 \{\ . nr % 0 . nr F 2 . \} . \} .\} .rr rF .\" ======================================================================== .\" .IX Title "PDL2 1p" .TH PDL2 1p "2020-11-19" "perl v5.32.0" "User Contributed Perl Documentation" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH "NAME" pdl2 \- Simple shell (version 2) for PDL .SH "SYNOPSIS" .IX Header "SYNOPSIS" Use \s-1PDL\s0 interactively: .PP .Vb 1 \& %> pdl2 \& \& pdl> $x = sequence(10) # or any other perl or PDL command \& \& pdl> print "\e$x = $x\en"; \& $x = [0 1 2 3 4 5 6 7 8 9] .Ve .SH "DESCRIPTION" .IX Header "DESCRIPTION" The \f(CW\*(C`pdl2\*(C'\fR program, also known as the Perldl2 shell, is a second generation version of the original \f(CW\*(C`perldl\*(C'\fR interactive \s-1PDL\s0 shell. It attempts to be backward compatible in usage while providing improved features, better support for Perl syntax, and an more easily extended framework based on the Devel::REPL shell. .PP If you have Devel::REPL version 1.003011 or later, then \f(CW\*(C`pdl2\*(C'\fR will start with full functionality. If Devel::REPL is not installed or found then \f(CW\*(C`pdl2\*(C'\fR will print a warning and run the legacy \f(CW\*(C`perldl\*(C'\fR shell command instead. .PP By default, command lines beginning with the default prompt of either \f(CW\*(C`pdl2\*(C'\fR or \f(CW\*(C`perldl\*(C'\fR (one of 'pdl> ', '\s-1PDL\s0> ', or \&'perldl> ') will have the prefix string and surrounding whitespace stripped. This allows for easy cut-and-paste from sample \s-1PDL\s0 shell sessions or other examples into another \&\s-1PDL\s0 shell session. .SH "FUNCTIONS" .IX Header "FUNCTIONS" .SS "do_print" .IX Subsection "do_print" Toggle print-by-default on and off (default value: off) .PP By default, \f(CW\*(C`pdl2\*(C'\fR does not print the results of operations since the results can be very large (e.g., a small 640x480 \&\s-1RGBA\s0 image is still more than 1_000_000 elements). However, for experimenting and debugging more complex structures, it helps to see the results of \fIevery\fR operation. The \&\f(CW\*(C`do_print\*(C'\fR routine allows you to toggle between the default \&\*(L"quiet\*(R" operation and a full Read, Evaluate, Loop style. .PP .Vb 1 \& pdl> $x = pdl(3,2) \& \& pdl> do_print \& 1 \& pdl> $x = pdl(3,2) \& $PDL1 = [3 2]; \& pdl> do_print \& \& pdl> $x = pdl(3,2) .Ve .SH "VARIABLES" .IX Header "VARIABLES" .ie n .IP "$PDL::toolongtoprint" 4 .el .IP "\f(CW$PDL::toolongtoprint\fR" 4 .IX Item "$PDL::toolongtoprint" The maximal size pdls to print (defaults to 10000 elements). This is not just a \f(CW\*(C`perldl\*(C'\fR or \f(CW\*(C`pdl2\*(C'\fR variable but it is something that is usually needed in an interactive debugging session. .SH "SEE ALSO" .IX Header "SEE ALSO" perldl, Devel::REPL