Package for multidimensional arrays and common array programming language algorithms.
NDArray withAll: 9 iota "Step 1"
:> reshape: #(3 3) "Step 2"
:> + 10 "Step 3"
:> reduce: #+ "Step 4"
:> asArray "Step 5"
Each step of the above code creates the following:
"Step 1:"
1 2 3 4 5 6 7 8 9
"Step 2"
1 2 3
4 5 6
7 8 9
"Step 3"
11 12 13
14 15 16
17 18 19
"Step 4"
36 45 54
"Step 5"
36 45 54 "Array (no longer NDArray)"
collect:
outerProduct:with:
reduce:
reduceFirst:
scan:
triangleProduct:
triangleProduct2:
upperProduct:
upperProduct2:
windowed:reduce:
abs
ceiling
exp
factorial
floor
invFactorial
not
reciprocal
roll
sign
%
*
/
+
-
**
<
<=
>
>=
=
(to be removed)eq:
min:
max:
all
any
asString
first
enlist
indices
ints
invIota
invWhere
isEmpty
last
max
maxs
min
mins
mix
negated
product
ravel
reverse
size
sort
split
sum
sums
transpose
unique
where
(seeindices
)
drop:
filter:
filterPred:
gather:
intersection:
matches:
memberOf:
notMatches:
partition:
reshape:
rotate:
take:
without:
Smalltalk | Bird | Combinator | |
---|---|---|---|
✔️ | and:with:atop: |
blackbird | B1 |
✔️ | and:with:backHook: |
||
and:with:fork:and: |
golden eagle | ||
✔️ | and:with:hook: |
dove | D |
✔️ | and:with:over: |
psi | Psi |
dupWith: |
warbler | W | |
dupWith:atop: |
|||
✔️ | dupWith:backHook: |
||
dupWith:fork:and: |
phoenix | S' | |
✔️ | dupWith:hook: |
starling | S |
dupWith:over: |
|||
flip:with: |
cardinal | C | |
✔️ | with:atop: |
bluebird | B |
✔️ means it has a symbol spelling below ⬇️
Binary Symbol | M/D | Combinator | Bird | APL Name | BQN Name | J / I* Name |
---|---|---|---|---|---|---|
<-> |
Dyadic | D & _ | Dove & ___ | ___ & beside | before & after | hook & backHook* |
<*> |
Monadic | S & _ | Starling & ___ | before & after | hook & backHook* | |
<|> |
Dyadic | B1 & Psi | Blackbird & Psi | atop & over | atop & over | atop & over |