roark has asked for the wisdom of the Perl Monks concerning the following question:
Hello all,
Being new to PDL, I was wondering how can I replace non-existant values with 0, while reading them.
Suppose I have the following tab seperated text file (a.txt):
1 0 0.1000 0.1000 0.8000
1 0 0.1000 0.1000 0.2750 0.5250
2 0 0.1000 0.1000 0.8000
then I use the following perl function:
I was wondering if there is any way to do that. Thanks in advance!
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: PDL rcols : Replacing missing values with 0
by Eily (Monsignor) on Aug 16, 2013 at 23:36 UTC | |
|
Re: PDL rcols : Replacing missing values with 0
by aitap (Curate) on Aug 18, 2013 at 11:36 UTC | |
by roark (Initiate) on Aug 18, 2013 at 17:52 UTC | |
|
Re: PDL rcols : Replacing missing values with 0
by etj (Priest) on May 22, 2022 at 01:15 UTC |