clean =:  ((((a: #~ {:@$)-.~ ,/)^:(2<#@$))^:_)@:

(# ,.@<)/"1 clean i.4 2


,/ will roll up dimensions.  clean is an adverb that deletes rows that are all 
empty boxes, and will roll up multiple dimensions until there are 2.



________________________________
From: Jimmy Gauvin <[email protected]>
To: [email protected] 
Sent: Monday, December 17, 2018 6:38 PM
Subject: [Jprogramming] Merging output of a function



Hi,


I have a function that produces a 2 column table with a variable number of

lines depending on the input. Applying the function to each row of an input

table returns a three dimensional matrix with padding.


Is there a way to obtain a two-dimensional output without the padding ?


fxy"1 d17f


492 680


493 680


0 0



594 1545


595 1545


596 1545



Thanks,



Jimmy

----------------------------------------------------------------------

For information about J forums see http://www.jsoftware.com/forums.htm
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to