Hello,
I just learned how to use PDL. The problem is that my data (matrix) is in
an external file.
How can i change change it into a PDL data structure?
I tried the code below but, the values in $s are still ones.
[code]
use PDL;
use PDL::Matrix;
use PDL::NiceSlice;
use PDL::AutoLoader;
use PDL::IO::Dumper;
my $s = ones(10,10); # There are 10 columns and 10 rows
my $k = 0;
while (my $line = <$fileHandler>)
{
$s(0:9,0:$k) = $line;
$k++;
}
[/code]
Regards and thank you,
Herve
_______________________________________________
Perldl mailing list
[email protected]
http://mailman.jach.hawaii.edu/mailman/listinfo/perldl