Preparing search index...
The search index is not available
ndarray-js
ndarray-js
np
Function np
np
(
template
,
...
variables
)
:
any
Parser and main namespace for the ndarray-js package.
Parameters
template
:
number
|
boolean
|
any
[]
|
TemplateStringsArray
Rest
...
variables
:
any
[]
Returns
any
Index
Binary operators
add
bitwise_
and
bitwise_
or
bitwise_
shift_
left
bitwise_
shift_
right
bitwise_
xor
divide
divide_
int
equal
greater
greater_
equal
less
less_
equal
logical_
and
logical_
or
maximum
minimum
mod
multiply
not_
equal
pow
subtract
Casting and reshaping
array
asarray
fromlist
ravel
reshape
tolist
Constructors
arange
empty
geomspace
linspace
ones
zeros
Elementwise operators
abs
acos
acosh
asin
asinh
atan
atanh
bitwise_
not
ceil
cos
cosh
exp
floor
isfinite
isnan
log
log10
log1p
log2
logical_
not
negative
round
sign
sin
sinh
sqrt
square
tan
tanh
Main
NDArray
modules
Math constants
e
pi
Modules
random
Other
allclose
assign
atan2
isclose
nanquantile
nonzero
quantile
take
where
Reducers
all
any
argmax
argmin
max
mean
min
norm
prod
product
std
sum
var
Transformations
apply_
along_
axis
concatenate
sort
stack
transpose
Binary operators
add
add
:
Wrapper
bitwise_
and
bitwise_
and
:
Wrapper
bitwise_
or
bitwise_
or
:
Wrapper
bitwise_
shift_
left
bitwise_
shift_
left
:
Wrapper
bitwise_
shift_
right
bitwise_
shift_
right
:
Wrapper
bitwise_
xor
bitwise_
xor
:
Wrapper
divide
divide
:
Wrapper
divide_
int
divide_
int
:
Wrapper
equal
equal
:
Wrapper
greater
greater
:
Wrapper
greater_
equal
greater_
equal
:
Wrapper
less
less
:
Wrapper
less_
equal
less_
equal
:
Wrapper
logical_
and
logical_
and
:
Wrapper
logical_
or
logical_
or
:
Wrapper
maximum
maximum
:
Wrapper
minimum
minimum
:
Wrapper
mod
mod
:
Wrapper
multiply
multiply
:
Wrapper
not_
equal
not_
equal
:
Wrapper
pow
pow
:
Wrapper
subtract
subtract
:
Wrapper
Casting and reshaping
array
array
:
(
(
A
)
=>
NDArray
<
any
>
)
Type declaration
(
A
)
:
NDArray
<
any
>
Parameters
A
:
any
Returns
NDArray
<
any
>
asarray
asarray
:
(
<
T
>
(
A
)
=>
NDArray
<
T
>
)
Type declaration
<
T
>
(
A
)
:
NDArray
<
T
>
Type Parameters
T
extends
TypedArrayConstructor
=
any
Parameters
A
:
any
Returns
NDArray
<
T
>
fromlist
fromlist
:
(
(
arr
,
dtype
?
)
=>
NDArray
<
TypedArrayConstructor
>
)
Type declaration
(
arr
,
dtype
?
)
:
NDArray
<
TypedArrayConstructor
>
Parameters
arr
:
any
dtype
:
Float64ArrayConstructor
= Float64Array
Returns
NDArray
<
TypedArrayConstructor
>
ravel
ravel
:
(
(
A
)
=>
NDArray
<
TypedArrayConstructor
>
)
Type declaration
(
A
)
:
NDArray
<
TypedArrayConstructor
>
Parameters
A
:
NDArray
<
Float64ArrayConstructor
>
Returns
NDArray
<
TypedArrayConstructor
>
reshape
reshape
:
(
(
A
,
shape_or_first
,
...
more_shape
)
=>
NDArray
<
TypedArrayConstructor
>
)
Type declaration
(
A
,
shape_or_first
,
...
more_shape
)
:
NDArray
<
TypedArrayConstructor
>
Parameters
A
:
NDArray
<
Float64ArrayConstructor
>
shape_or_first
:
Shape
Rest
...
more_shape
:
number
[]
Returns
NDArray
<
TypedArrayConstructor
>
tolist
tolist
(
template
,
...
variables
)
:
any
Parameters
template
:
number
|
boolean
|
any
[]
|
TemplateStringsArray
Rest
...
variables
:
any
[]
Returns
any
Constructors
arange
arange
:
(
(
arg0
,
arg1
?
)
=>
NDArray
<
TypedArrayConstructor
>
)
Type declaration
(
arg0
,
arg1
?
)
:
NDArray
<
TypedArrayConstructor
>
Parameters
arg0
:
any
arg1
:
any
= null
Returns
NDArray
<
TypedArrayConstructor
>
empty
empty
:
(
(
shape
,
dtype
?
)
=>
NDArray
<
TypedArrayConstructor
>
)
Type declaration
(
shape
,
dtype
?
)
:
NDArray
<
TypedArrayConstructor
>
Parameters
shape
:
Shape
dtype
:
TypedArrayConstructor
= Float64Array
Returns
NDArray
<
TypedArrayConstructor
>
geomspace
geomspace
:
(
(
start
,
stop
,
steps
?
,
endpoint
?
)
=>
NDArray
<
Float64ArrayConstructor
>
|
NDArray
<
TypedArrayConstructor
>
)
Type declaration
(
start
,
stop
,
steps
?
,
endpoint
?
)
:
NDArray
<
Float64ArrayConstructor
>
|
NDArray
<
TypedArrayConstructor
>
Parameters
start
:
number
stop
:
number
steps
:
number
= 50
endpoint
:
boolean
= true
Returns
NDArray
<
Float64ArrayConstructor
>
|
NDArray
<
TypedArrayConstructor
>
linspace
linspace
:
(
(
start
,
stop
,
steps
?
,
endpoint
?
)
=>
NDArray
<
Float64ArrayConstructor
>
)
Type declaration
(
start
,
stop
,
steps
?
,
endpoint
?
)
:
NDArray
<
Float64ArrayConstructor
>
Parameters
start
:
number
stop
:
number
steps
:
number
= 50
endpoint
:
boolean
= true
Returns
NDArray
<
Float64ArrayConstructor
>
ones
ones
:
(
(
shape
,
dtype
?
)
=>
NDArray
<
TypedArrayConstructor
>
)
Type declaration
(
shape
,
dtype
?
)
:
NDArray
<
TypedArrayConstructor
>
Parameters
shape
:
Shape
dtype
:
TypedArrayConstructor
= Float64Array
Returns
NDArray
<
TypedArrayConstructor
>
zeros
zeros
:
(
(
shape
,
dtype
?
)
=>
NDArray
<
TypedArrayConstructor
>
)
Type declaration
(
shape
,
dtype
?
)
:
NDArray
<
TypedArrayConstructor
>
Parameters
shape
:
Shape
dtype
:
TypedArrayConstructor
= Float64Array
Returns
NDArray
<
TypedArrayConstructor
>
Elementwise operators
abs
abs
:
Wrapper
acos
acos
:
Wrapper
acosh
acosh
:
Wrapper
asin
asin
:
Wrapper
asinh
asinh
:
Wrapper
atan
atan
:
Wrapper
atanh
atanh
:
Wrapper
bitwise_
not
bitwise_
not
:
Wrapper
ceil
ceil
:
Wrapper
cos
cos
:
Wrapper
cosh
cosh
:
Wrapper
exp
exp
:
Wrapper
floor
floor
:
Wrapper
isfinite
isfinite
:
Wrapper
isnan
isnan
:
Wrapper
log
log
:
Wrapper
log10
log10
:
Wrapper
log1p
log1p
:
Wrapper
log2
log2
:
Wrapper
logical_
not
logical_
not
:
Wrapper
negative
negative
:
Wrapper
round
round
:
Wrapper
sign
sign
:
Wrapper
sin
sin
:
Wrapper
sinh
sinh
:
Wrapper
sqrt
sqrt
:
Wrapper
square
square
:
Wrapper
tan
tan
:
Wrapper
tanh
tanh
:
Wrapper
Main
NDArray
NDArray
:
typeof
NDArray
Namespace
modules
modules
:
{
   Â
constructors
:
any
;
   Â
grammar
:
any
;
   Â
indexing
:
any
;
   Â
random
:
any
;
   Â
statistics
:
any
;
}
Type declaration
Math constants
e
e
:
number
pi
pi
:
number
Modules
random
random
:
"/mnt/data/documents/projects/ndarray-js/src/modules/random"
Other
allclose
allclose
:
(
(
A
,
B
,
rtol
?
,
atol
?
,
equal_nan
?
)
=>
boolean
)
Type declaration
(
A
,
B
,
rtol
?
,
atol
?
,
equal_nan
?
)
:
boolean
Parameters
A
:
any
B
:
any
rtol
:
number
= 1.e-5
atol
:
number
= 1.e-8
equal_nan
:
boolean
= false
Returns
boolean
assign
assign
:
(
<
T
>
(
a
,
values
,
where
)
=>
NDArray
<
T
>
)
Type declaration
<
T
>
(
a
,
values
,
where
)
:
NDArray
<
T
>
Type Parameters
T
extends
TypedArrayConstructor
Parameters
a
:
NDArray
<
T
>
values
:
NDArray
<
Float64ArrayConstructor
>
where
:
GeneralIndexSpec
[]
Returns
NDArray
<
T
>
atan2
atan2
:
Wrapper
isclose
isclose
:
(
(
A
,
B
,
rtol
?
,
atol
?
,
equal_nan
?
)
=>
NDArray
<
Uint8ArrayConstructor
>
)
Type declaration
(
A
,
B
,
rtol
?
,
atol
?
,
equal_nan
?
)
:
NDArray
<
Uint8ArrayConstructor
>
Parameters
A
:
any
B
:
any
rtol
:
number
= 1.e-5
atol
:
number
= 1.e-8
equal_nan
:
boolean
= false
Returns
NDArray
<
Uint8ArrayConstructor
>
nanquantile
nanquantile
:
Wrapper
nonzero
nonzero
:
(
(
a
)
=>
NDArray
<
Int32ArrayConstructor
>
[]
)
Type declaration
(
a
)
:
NDArray
<
Int32ArrayConstructor
>
[]
Parameters
a
:
NDArray
<
any
>
Returns
NDArray
<
Int32ArrayConstructor
>
[]
quantile
quantile
:
Wrapper
take
take
:
(
(
a
,
indices
,
axis
)
=>
NDArray
<
Float64ArrayConstructor
>
)
Type declaration
(
a
,
indices
,
axis
)
:
NDArray
<
Float64ArrayConstructor
>
Parameters
a
:
NDArray
<
Float64ArrayConstructor
>
indices
:
NDArray
<
Float64ArrayConstructor
>
axis
:
number
Returns
NDArray
<
Float64ArrayConstructor
>
where
where
:
(
(
condition
,
x
,
y
,
out
?
)
=>
NDArray
<
Float64ArrayConstructor
>
)
Type declaration
(
condition
,
x
,
y
,
out
?
)
:
NDArray
<
Float64ArrayConstructor
>
Parameters
condition
:
NDArray
<
Float64ArrayConstructor
>
x
:
NDArray
<
Float64ArrayConstructor
>
y
:
NDArray
<
Float64ArrayConstructor
>
out
:
NDArray
<
Float64ArrayConstructor
>
= null
Returns
NDArray
<
Float64ArrayConstructor
>
Reducers
all
all
:
Wrapper
<
Uint8ArrayConstructor
>
any
any
:
Wrapper
<
Uint8ArrayConstructor
>
argmax
argmax
:
Wrapper
<
Int32ArrayConstructor
>
argmin
argmin
:
Wrapper
<
Int32ArrayConstructor
>
max
max
:
Wrapper
<
Float64ArrayConstructor
>
mean
mean
:
Wrapper
<
Float64ArrayConstructor
>
min
min
:
Wrapper
<
Float64ArrayConstructor
>
norm
norm
:
Wrapper
prod
prod
:
Wrapper
<
Float64ArrayConstructor
>
product
product
:
Wrapper
<
Float64ArrayConstructor
>
std
std
:
Wrapper
sum
sum
:
Wrapper
<
Float64ArrayConstructor
>
var
var
:
Wrapper
Transformations
apply_
along_
axis
apply_
along_
axis
:
(
(
arr
,
axis
,
transform
,
dtype
?
)
=>
ArrayOrConstant
)
Type declaration
(
arr
,
axis
,
transform
,
dtype
?
)
:
ArrayOrConstant
Parameters
arr
:
NDArray
<
any
>
axis
:
number
transform
:
any
dtype
:
TypedArrayConstructor
= Float64Array
Returns
ArrayOrConstant
concatenate
concatenate
:
(
(
arrays
,
axis
?
)
=>
NDArray
<
TypedArrayConstructor
>
)
Type declaration
(
arrays
,
axis
?
)
:
NDArray
<
TypedArrayConstructor
>
Parameters
arrays
:
NDArray
<
any
>
[]
axis
:
number
= null
Returns
NDArray
<
TypedArrayConstructor
>
sort
sort
:
Wrapper
stack
stack
:
(
(
arrays
,
axis
?
)
=>
NDArray
<
TypedArrayConstructor
>
)
Type declaration
(
arrays
,
axis
?
)
:
NDArray
<
TypedArrayConstructor
>
Parameters
arrays
:
NDArray
<
Float64ArrayConstructor
>
[]
axis
:
number
= 0
Returns
NDArray
<
TypedArrayConstructor
>
transpose
transpose
:
(
(
arr
,
axes
?
)
=>
NDArray
<
TypedArrayConstructor
>
)
Type declaration
(
arr
,
axes
?
)
:
NDArray
<
TypedArrayConstructor
>
Parameters
arr
:
NDArray
<
any
>
axes
:
number
[]
= null
Returns
NDArray
<
TypedArrayConstructor
>
Settings
Member Visibility
Protected
Private
Inherited
External
Theme
OS
Light
Dark
On This Page
add
bitwise_
and
bitwise_
or
bitwise_
shift_
left
bitwise_
shift_
right
bitwise_
xor
divide
divide_
int
equal
greater
greater_
equal
less
less_
equal
logical_
and
logical_
or
maximum
minimum
mod
multiply
not_
equal
pow
subtract
array
asarray
fromlist
ravel
reshape
tolist
arange
empty
geomspace
linspace
ones
zeros
abs
acos
acosh
asin
asinh
atan
atanh
bitwise_
not
ceil
cos
cosh
exp
floor
isfinite
isnan
log
log10
log1p
log2
logical_
not
negative
round
sign
sin
sinh
sqrt
square
tan
tanh
NDArray
modules
e
pi
random
allclose
assign
atan2
isclose
nanquantile
nonzero
quantile
take
where
all
any
argmax
argmin
max
mean
min
norm
prod
product
std
sum
var
apply_
along_
axis
concatenate
sort
stack
transpose
ndarray-js
Loading...
Generated using
TypeDoc
Parser and main namespace for the ndarray-js package.