For Programmers: Free Programming Magazines  


Home > Archive > PERL Miscellaneous > September 2005 > pdl and arrays containing strings









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author pdl and arrays containing strings
ked

2005-09-28, 8:06 am

This one really puzzles me.

How do I convcert a traditional perl array @filelist into a PDL piddle
on which I can index by using the PDL::NiceSlice module. Creating
piddles and NiceSlice works great for everything about piddles of
numbers, but when it comes to text I'm stuck.

print @filelist[0]; returns someting like

/home/user/data/some_datafile.dat


$newfilelist = pdl @filelist;

print $newfilelist(0:2); returns only

[0 0 0]

What am I missing?

Ked

A. Sinan Unur

2005-09-28, 8:06 am

"ked" <ked@nilu.no> wrote in news:1127905199.054144.14730
@g47g2000cwa.googlegroups.com:

> How do I convcert a traditional perl array @filelist into a PDL piddle
> on which I can index by using the PDL::NiceSlice module. Creating
> piddles and NiceSlice works great for everything about piddles of
> numbers, but when it comes to text I'm stuck.


....

> What am I missing?


DESCRIPTION

PDL is the Perl Data Language, a perl extension that is designed for
scientific and bulk numeric data processing and display.

Sinan
--
A. Sinan Unur <1usa@llenroc.ude.invalid>
(reverse each component and remove .invalid for email address)

comp.lang.perl.misc guidelines on the WWW:
http://mail.augustmail.com/~tadmc/c...guidelines.html
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com