Yes thanks I understand. 
My Foo function used out of bounds fill elements internally to be able to 
manipulate rectangular arrays of generated indices which are of course ⎕IO 
dependant.
The return result of Foo had removed them. I will not do so and my problem will 
disappear. 
thanks again and respect…

Peter

On 2014-08-10, at 8:28 AM, Juergen Sauermann <[email protected]> 
wrote:

> Hi Peter,
> 
> no there isn't. Fill items and Fill functions occur all over the place in 
> APL2.
> And they are function specific so that ↑ has other fill items (' ' and 0) than
> + (0) and × (1). On the other hand fill items are not at all related ⎕IO.
> 
> You can easily achieve what you are after like this:
> 
>       A←4 5
>       B←3 2⍴42
>       Z←A↑B
>       Z
> 42 42 0 0 0
> 42 42 0 0 0
> 42 42 0 0 0
>  0  0 0 0 0
>       Z + ∼A↑(⍴B)⍴1
> 42 42 1 1 1
> 42 42 1 1 1
> 42 42 1 1 1
>  1  1 1 1 1
> 
> /// Jürgen
> 
> 
> On 08/09/2014 08:15 PM, Peter Teeson wrote:
>> Is there a nice way to set the fill element for arrays?
>> Right now it's 0 for numeric and ' ' for character.
>> 
>> Because my function, that is deliberately ⎕IO agnostic, produces an m by n 
>> array of different length vectors as a result of using 
>> X←(⊂matrix)foo¨matrix. These vectors are certain indices into the original 
>> matrix This is precisely what I want.
>> 
>> However in ⊃X each vector is filled with 0 - which, when ⎕IO is also 0, is 
>> also a legitimate index. And I don't want that. 
>> 
>> I suppose I could set ⎕IO locally but it doesn't appeal to my sense of 
>> elegance - although it would be practical! Sigh!
>> 
>> So it would be nice to allow me to set the fill element to something other 
>> than the default values.
>> 
>> Comments?
>> 
>> respect….
>> 
>> Peter
>> 
>> 
>> 
> 

Reply via email to