Hi Puneet: When I get into this situation, I'm usually in the perl
debugger. I make heavy use of 'slice' to see sections of the PDL I'm
interested in. I also find that just knowing the dimensions of a PDL can
tell you a lot.
--Doug
[email protected]
Software Engineer
UCAR - COSMIC, Tel. (303) 497-2611
On Mon, 30 Aug 2010, P Kishor wrote:
On Mon, Aug 30, 2010 at 1:45 PM, Craig DeForest
<[email protected]> wrote:
sub bigstring {
my($pdl, $fmt, $lev) = @_;
$fmt = "%g" unless($fmt);
my $s=" "x$lev;
if($pdl->ndims > 1) {
$s .= join("\n", "[", (map { bigstring($_,$fmt,$lev+1) } dog
$pdl), $s."]");
} elsif($pdl->ndims) {
$s .= "[ " . join(" ",map { sprintf($fmt,$_) } $pdl->list) .
" ]";
} else {
$s = sprintf($fmt,$pdl->at(0));
}
return $s;
}
print bigstring($mybighonkingpdl,"%5g");
lord have mercy... lookee here
https://sourceforge.net/apps/mediawiki/pdl/index.php?title=View_the_data_in_a_piddle_a_la_Data::Dumper
On Aug 30, 2010, at 12:19 PM, P Kishor wrote:
?Show me your diagrams and conceal your piddles, and I shall continue
to be mystified. Show me your piddles, and I won?t usually need your
diagrams; they?ll be obvious.?
? Fred Brooks in the mythical ?The Mythical Man-Month?
Per the docs, because of some problem with ncurses, PDL::IO::Browser
doesn't build. Truth be told, I didn't even try building it. I don't
even know what it does, but when I face something like
"PDL::index: invalid index -2147483648 (valid range 0..255) at..."
or something similar, I wish I could just view my data. Of course, the
PDL program, very kindly, informs me that my piddle is "TOO LONG TO
PRINT." Now, what to do?
Sometimes, I just want to view my piddle, no matter how big. Is
P::I::Browser the answer? Does it build on Mac OS X?
--
Puneet Kishor http://www.punkish.org
Carbon Model http://carbonmodel.org
Charter Member, Open Source Geospatial Foundation http://www.osgeo.org
Science Commons Fellow, http://sciencecommons.org/about/whoweare/kishor
Nelson Institute, UW-Madison http://www.nelson.wisc.edu
-----------------------------------------------------------------------
Assertions are politics; backing up assertions with evidence is science
=======================================================================
_______________________________________________
Perldl mailing list
[email protected]
http://mailman.jach.hawaii.edu/mailman/listinfo/perldl
--
Puneet Kishor http://www.punkish.org
Carbon Model http://carbonmodel.org
Charter Member, Open Source Geospatial Foundation http://www.osgeo.org
Science Commons Fellow, http://sciencecommons.org/about/whoweare/kishor
Nelson Institute, UW-Madison http://www.nelson.wisc.edu
-----------------------------------------------------------------------
Assertions are politics; backing up assertions with evidence is science
=======================================================================
_______________________________________________
Perldl mailing list
[email protected]
http://mailman.jach.hawaii.edu/mailman/listinfo/perldl
_______________________________________________
Perldl mailing list
[email protected]
http://mailman.jach.hawaii.edu/mailman/listinfo/perldl