absufunc | np.abs documentedsignaturenp.abs(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Calculate the absolute value element-wise. |
absoluteufunc | np.absolute documentedsignaturenp.absolute(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Calculate the absolute value element-wise. |
acosufunc | np.acos documentedsignaturenp.acos(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Trigonometric inverse cosine, element-wise. |
acoshufunc | np.acosh documentedsignaturenp.acosh(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Inverse hyperbolic cosine, element-wise. |
addufunc | np.add documentedsignaturenp.add(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Add arguments element-wise. |
allfunction | np.all documentedsignaturenp.all(a: ArrayLike, opts?: AllAnyOptions | undefined): NDArray
| Test whether all array elements along a given axis evaluate to True. |
allclosefunction | np.allclose documentedsignaturenp.allclose(a: CloseOperand, b: CloseOperand, opts?: IscloseOptions | undefined): boolean
| Returns True if two arrays are element-wise equal within a tolerance. |
amaxfunction | np.amax signaturenp.amax(a: ArrayLike, opts?: Omit<ReduceOptions, "dtype"> | undefined): NDArray
| Return the maximum of an array or maximum along an axis. |
aminfunction | np.amin signaturenp.amin(a: ArrayLike, opts?: Omit<ReduceOptions, "dtype"> | undefined): NDArray
| Return the minimum of an array or minimum along an axis. |
anglefunction | np.angle documentedsignaturenp.angle(z: ArrayLike, deg?: boolean | undefined): NDArray
| Return the angle of the complex argument. |
anyfunction | np.any documentedsignaturenp.any(a: ArrayLike, opts?: AllAnyOptions | undefined): NDArray
| Test whether any array element along a given axis evaluates to True. |
appendfunction | np.append documentedsignaturenp.append(arr: ArrayLike, values: ArrayLike, axis?: number | null | undefined): NDArray
| Append values to the end of an array. |
apply_along_axisfunction | np.applyAlongAxis documentedsignaturenp.applyAlongAxis<A extends unknown[]>(func1d: (lane: NDArray, ...args: A) => ArrayLike, axis: number, arr: ArrayLike, ...args: A): NDArray
| Apply a function to 1-D slices along the given axis. |
apply_over_axesfunction | np.applyOverAxes documentedsignaturenp.applyOverAxes(func: (a: NDArray, axis: number) => ArrayLike, a: ArrayLike, axes: number | readonly number[]): NDArray
| Apply a function repeatedly over multiple axes. |
arangefunction | np.arange documentedsignaturenp.arange(startOrStop: number, stop?: number | undefined, step?: number | undefined, options?: ArrayOptions | undefined): NDArray
| Return evenly spaced values within a given interval. |
arccosufunc | np.arccos documentedsignaturenp.arccos(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Trigonometric inverse cosine, element-wise. |
arccoshufunc | np.arccosh documentedsignaturenp.arccosh(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Inverse hyperbolic cosine, element-wise. |
arcsinufunc | np.arcsin documentedsignaturenp.arcsin(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Inverse sine, element-wise. |
arcsinhufunc | np.arcsinh documentedsignaturenp.arcsinh(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Inverse hyperbolic sine, element-wise. |
arctanufunc | np.arctan documentedsignaturenp.arctan(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Trigonometric inverse tangent, element-wise. |
arctan2ufunc | np.arctan2 documentedsignaturenp.arctan2(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Element-wise arc tangent of x1/x2 choosing the quadrant correctly. |
arctanhufunc | np.arctanh documentedsignaturenp.arctanh(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Inverse hyperbolic tangent, element-wise. |
argmaxfunction | np.argmax documentedsignaturenp.argmax(a: ArrayLike, opts?: ArgReduceOptions | undefined): NDArray
| Returns the indices of the maximum values along an axis. |
argminfunction | np.argmin documentedsignaturenp.argmin(a: ArrayLike, opts?: ArgReduceOptions | undefined): NDArray
| Returns the indices of the minimum values along an axis. |
argpartitionfunction | np.argpartition documentedsignaturenp.argpartition(a: ArrayLike, kth: Kth, opts?: PartitionOptions | undefined): NDArray
| Perform an indirect partition along the given axis using the algorithm specified by the kind keyword. It returns an array of indices of the same shape as a that index data along the given axis in partitioned order. |
argsortfunction | np.argsort documentedsignaturenp.argsort(a: ArrayLike, opts?: SortOptions | undefined): NDArray
| Returns the indices that would sort an array. |
argwherefunction | np.argwhere documentedsignaturenp.argwhere(a: ArrayLike): NDArray
| Find the indices of array elements that are non-zero, grouped by element. |
aroundfunction | np.around documentedsignaturenp.around(a: ArrayLike, decimals?: number | undefined, opts?: RoundOptions | undefined): NDArray
| Round an array to the given number of decimals. |
arrayfunction | np.array documentedsignaturenp.array(data: NDArray | NestedArray, options?: ArrayCopyOptions | undefined): NDArray
| Create an array. |
array_equalfunction | np.arrayEqual documentedsignaturenp.arrayEqual(a1: ArrayLike, a2: ArrayLike, opts?: { equalNan?: boolean | undefined; } | undefined): boolean
| True if two arrays have the same shape and elements, False otherwise. |
array_equivfunction | np.arrayEquiv documentedsignaturenp.arrayEquiv(a1: ArrayLike, a2: ArrayLike): boolean
| Returns True if input arrays are shape consistent and all elements equal. |
array_reprfunction | np.arrayRepr documentedsignaturenp.arrayRepr(a: AnyArray, opts?: ArrayReprOptions | undefined): string
| Return the string representation of an array. |
array_splitfunction | np.arraySplit signaturenp.arraySplit(a: ArrayLike, indicesOrSections: number | NDArray | readonly number[], axis?: number | undefined): NDArray[]
| Split an array into multiple sub-arrays. |
array_strfunction | np.arrayStr documentedsignaturenp.arrayStr(a: AnyArray, opts?: ArrayReprOptions | undefined): string
| Return a string representation of the data in an array. |
array2stringfunction | np.array2string documentedsignaturenp.array2string(a: AnyArray, opts?: Array2StringOptions | undefined): string
| Return a string representation of an array. |
asanyarrayfunction | np.asanyarray documentedsignaturenp.asanyarray(a: ArrayLike, options?: { dtype?: DTypeLike | undefined; } | undefined): NDArray
| Convert the input to an ndarray, but pass ndarray subclasses through. |
asarrayfunction | np.asarray documentedsignaturenp.asarray(data: NDArray | NestedArray, options?: ArrayOptions | undefined): NDArray
| Convert the input to an array. |
asarray_chkfinitefunction | np.asarrayChkfinite documentedsignaturenp.asarrayChkfinite(a: ArrayLike, options?: { dtype?: DTypeLike | undefined; } | undefined): NDArray
| Convert the input to an array, checking for NaNs or Infs. |
ascontiguousarrayfunction | np.ascontiguousarray documentedsignaturenp.ascontiguousarray(a: NDArray | NestedArray, options?: ArrayOptions | undefined): NDArray
| Return a contiguous array (ndim >= 1) in memory (C order). |
asfortranarrayfunction | np.asfortranarray documentedsignaturenp.asfortranarray(a: NDArray | NestedArray, options?: ArrayOptions | undefined): NDArray
| Return an array (ndim >= 1) laid out in Fortran order in memory. |
asinufunc | np.asin documentedsignaturenp.asin(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Inverse sine, element-wise. |
asinhufunc | np.asinh documentedsignaturenp.asinh(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Inverse hyperbolic sine, element-wise. |
astypefunction | np.astype documentedsignaturenp.astype(x: NDArray, dtype: DTypeLike, options?: Pick<AstypeOptions, "copy"> | undefined): NDArray
| Copies an array to a specified data type. |
atanufunc | np.atan documentedsignaturenp.atan(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Trigonometric inverse tangent, element-wise. |
atan2ufunc | np.atan2 documentedsignaturenp.atan2(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Element-wise arc tangent of x1/x2 choosing the quadrant correctly. |
atanhufunc | np.atanh documentedsignaturenp.atanh(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Inverse hyperbolic tangent, element-wise. |
atleast_1dfunction | np.atleast1d documentedsignaturenp.atleast1d(a: ArrayLike): NDArray
np.atleast1d(...arys: ArrayLike[]): NDArray | NDArray[]
| Convert inputs to arrays with at least one dimension. |
atleast_2dfunction | np.atleast2d signaturenp.atleast2d(a: ArrayLike): NDArray
np.atleast2d(...arys: ArrayLike[]): NDArray | NDArray[]
| View inputs as arrays with at least two dimensions. |
atleast_3dfunction | np.atleast3d signaturenp.atleast3d(a: ArrayLike): NDArray
np.atleast3d(...arys: ArrayLike[]): NDArray | NDArray[]
| View inputs as arrays with at least three dimensions. |
averagefunction | np.average documentedsignaturenp.average(a: ArrayLike, opts: AverageOptions & { returned: true; }): [NDArray, NDArray]
np.average(a: ArrayLike, opts?: AverageOptions | undefined): NDArray
| Compute the weighted average along the specified axis. |
bartlettfunction | np.bartlett documentedsignaturenp.bartlett(M: number | bigint | NDArray): NDArray
| Return the Bartlett window. |
base_reprfunction | np.baseRepr documentedsignaturenp.baseRepr(number: IntegerLike, base?: number | undefined, padding?: number | undefined): string
| Return a string representation of a number in the given base system. |
binary_reprfunction | np.binaryRepr documentedsignaturenp.binaryRepr(num: IntegerLike, options?: BinaryReprOptions | undefined): string
| Return the binary representation of the input number as a string. |
bincountfunction | np.bincount documentedsignaturenp.bincount(x: ArrayLike, opts?: BincountOptions | undefined): NDArray
| Count number of occurrences of each value in array of non-negative ints. |
bitwise_andufunc | np.bitwiseAnd documentedsignaturenp.bitwiseAnd(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Compute the bit-wise AND of two arrays element-wise. |
bitwise_countufunc | np.bitwiseCount documentedsignaturenp.bitwiseCount(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Computes the number of 1-bits in the absolute value of x. Analogous to the builtin int.bit_count or popcount in C++. |
bitwise_invertufunc | np.bitwiseInvert signaturenp.bitwiseInvert(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Compute bit-wise inversion, or bit-wise NOT, element-wise. |
bitwise_left_shiftufunc | np.bitwiseLeftShift documentedsignaturenp.bitwiseLeftShift(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Shift the bits of an integer to the left. |
bitwise_notufunc | np.bitwiseNot signaturenp.bitwiseNot(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Compute bit-wise inversion, or bit-wise NOT, element-wise. |
bitwise_orufunc | np.bitwiseOr documentedsignaturenp.bitwiseOr(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Compute the bit-wise OR of two arrays element-wise. |
bitwise_right_shiftufunc | np.bitwiseRightShift documentedsignaturenp.bitwiseRightShift(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Shift the bits of an integer to the right. |
bitwise_xorufunc | np.bitwiseXor documentedsignaturenp.bitwiseXor(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Compute the bit-wise XOR of two arrays element-wise. |
blackmanfunction | np.blackman documentedsignaturenp.blackman(M: number | bigint | NDArray): NDArray
| Return the Blackman window. |
blockfunction | np.block documentedsignaturenp.block(arrays: BlockArg): NDArray
| Assemble an nd-array from nested lists of blocks. |
boolclass | np.bool signaturenp.bool: DType
| Boolean type (True or False), stored as a byte. |
bool_class | np.bool signaturenp.bool: DType
| Boolean type (True or False), stored as a byte. |
broadcast_arraysfunction | np.broadcastArrays documentedsignaturenp.broadcastArrays(...args: ArrayLike[]): NDArray[]
| Broadcast any number of arrays against each other. |
broadcast_shapesfunction | np.broadcastShapes documentedsignaturenp.broadcastShapes(...shapes: (number | Shape)[]): number[]
| Broadcast the input shapes into a single shape. |
broadcast_tofunction | np.broadcastTo documentedsignaturenp.broadcastTo(a: ArrayLike, shape: number | Shape): NDArray
| Broadcast an array to a new shape. |
busday_countfunction | np.busday_count documentedsignaturenp.busday_count(begindates: string | number | bigint | DatetimeArray, enddates: string | number | bigint | DatetimeArray, options?: BusdayCountOptions | undefined): number | number[]
| Counts the number of valid days between begindates and enddates, not including the day of enddates. |
busday_offsetfunction | np.busday_offset documentedsignaturenp.busday_offset(dates: string | number | bigint | DatetimeArray | (string | number | bigint | DatetimeArray)[], offsets: number | number[], options?: BusdayOffsetOptions | undefined): DatetimeArray | DatetimeArray[] | null
| First adjusts the date to fall on a valid day according to the roll rule, then applies offsets to the given dates counted in valid days. |
byteclass | np.byte documentedsignaturenp.byte: DType
| Signed integer type, compatible with C char. |
bytes_class | np.bytes_ documentedsignaturenp.bytes_: "bytes"
| A byte string. |
c_constant | np.c_ documentedsignaturenp.c_(...items: ConcatItem[]): NDArray
| Translates slice objects to concatenation along the second axis. |
can_castfunction | np.canCast documentedsignaturenp.canCast(from: DTypeLike | { readonly dtype: DType; }, to: DTypeLike, casting?: Casting | undefined): boolean
| Returns True if cast between data types can occur according to the casting rule. |
cbrtufunc | np.cbrt documentedsignaturenp.cbrt(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Return the cube-root of an array, element-wise. |
cdoubleclass | np.cdouble documentedsignaturenp.cdouble: DType
| Complex number type composed of two double-precision floating-point numbers, compatible with Python :class:complex. |
ceilufunc | np.ceil documentedsignaturenp.ceil(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Return the ceiling of the input, element-wise. |
choosefunction | np.choose documentedsignaturenp.choose(a: ArrayLike, choices: NDArray | readonly Operand[], opts?: ChooseOptions | undefined): NDArray
| Construct an array from an index array and a list of arrays to choose from. |
clipfunction | np.clip documentedsignaturenp.clip(a: ArrayLike, min?: Bound, max?: Bound, opts?: ClipOptions | undefined): NDArray
| Clip (limit) the values in an array. |
column_stackfunction | np.columnStack documentedsignaturenp.columnStack(arrays: Sequence): NDArray
| Stack 1-D arrays as columns into a 2-D array. |
common_typefunction | np.commonType documentedsignaturenp.commonType(...arrays: (NDArray | NestedArray)[]): DType
| Return a scalar type which is common to the input arrays. |
complex128class | np.complex128 signaturenp.complex128: DType
| Complex number type composed of two double-precision floating-point numbers, compatible with Python :class:complex. |
complex64class | np.complex64 signaturenp.complex64: DType
| Complex number type composed of two single-precision floating-point numbers. |
compressfunction | np.compress documentedsignaturenp.compress(condition: ArrayLike, a: ArrayLike, axis?: number | AxisOptions | null | undefined): NDArray
| Return selected slices of an array along given axis. |
concatfunction | np.concat signaturenp.concat(arrays: Sequence, axis?: number | ConcatenateOptions | null | undefined, options?: JoinOptions | undefined): NDArray
| Join a sequence of arrays along an existing axis. |
concatenatefunction | np.concatenate documentedsignaturenp.concatenate(arrays: Sequence, axis?: number | ConcatenateOptions | null | undefined, options?: JoinOptions | undefined): NDArray
| Join a sequence of arrays along an existing axis. |
conjufunc | np.conj documentedsignaturenp.conj(a: ArrayLike): NDArray
| Return the complex conjugate, element-wise. |
conjugateufunc | np.conjugate documentedsignaturenp.conjugate(a: ArrayLike): NDArray
| Return the complex conjugate, element-wise. |
convolvefunction | np.convolve documentedsignaturenp.convolve(a: ArrayLike, v: ArrayLike, mode?: ConvMode | undefined): NDArray
| Returns the discrete, linear convolution of two one-dimensional sequences. |
copyfunction | np.copy documentedsignaturenp.copy(a: NDArray | NestedArray, options?: { order?: MemoryOrder | null | undefined; } | undefined): NDArray
| Return an array copy of the given object. |
copysignufunc | np.copysign documentedsignaturenp.copysign(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Change the sign of x1 to that of x2, element-wise. |
copytofunction | np.copyto documentedsignaturenp.copyto(dst: NDArray, src: number | bigint | boolean | NDArray | Complex | { readonly re: number; readonly im?: number | undefined; } | readonly NestedArray[], options?: CopytoOptions | undefined): void
| Copies values from one array to another, broadcasting as necessary. |
corrcoeffunction | np.corrcoef documentedsignaturenp.corrcoef(x: ArrayLike, opts?: CorrcoefOptions | undefined): NDArray
| Return Pearson product-moment correlation coefficients. |
correlatefunction | np.correlate documentedsignaturenp.correlate(a: ArrayLike, v: ArrayLike, mode?: ConvMode | undefined): NDArray
| Cross-correlation of two 1-dimensional sequences. |
cosufunc | np.cos documentedsignaturenp.cos(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Cosine element-wise. |
coshufunc | np.cosh documentedsignaturenp.cosh(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Hyperbolic cosine, element-wise. |
count_nonzerofunction | np.countNonzero documentedsignaturenp.countNonzero(a: ArrayLike, opts?: CountNonzeroOptions | undefined): NDArray
| Counts the number of non-zero values in the array a. |
covfunction | np.cov documentedsignaturenp.cov(m: ArrayLike, opts?: CovOptions | undefined): NDArray
| Estimate a covariance matrix, given data and weights. |
crossfunction | np.cross documentedsignaturenp.cross(a: ArrayLike, b: ArrayLike, opts?: CrossOptions | undefined): NDArray
| Return the cross product of two (arrays of) vectors. |
csingleclass | np.csingle documentedsignaturenp.csingle: DType
| Complex number type composed of two single-precision floating-point numbers. |
cumprodfunction | np.cumprod documentedsignaturenp.cumprod(a: NDArray | NestedArray, axis?: number | null | undefined, opts?: { dtype?: DTypeLike | null | undefined; } | undefined): NDArray
| Return the cumulative product of elements along a given axis. |
cumsumfunction | np.cumsum documentedsignaturenp.cumsum(a: NDArray | NestedArray, axis?: number | null | undefined, opts?: { dtype?: DTypeLike | null | undefined; } | undefined): NDArray
| Return the cumulative sum of the elements along a given axis. |
cumulative_prodfunction | np.cumulativeProd documentedsignaturenp.cumulativeProd(x: ArrayLike, opts?: CumulativeOptions | undefined): NDArray
| Return the cumulative product of elements along a given axis. |
cumulative_sumfunction | np.cumulativeSum documentedsignaturenp.cumulativeSum(x: ArrayLike, opts?: CumulativeOptions | undefined): NDArray
| Return the cumulative sum of the elements along a given axis. |
datetime_as_stringfunction | np.datetime_as_string documentedsignaturenp.datetime_as_string(arr: DatetimeArray, options?: string | DatetimeAsStringOptions | undefined): string | string[]
| Convert an array of datetimes into an array of strings. |
datetime64class | np.datetime64 documentedsignaturenp.datetime64(value: DatetimeInput, unit?: string | undefined): DatetimeArray
| If created from a 64-bit integer, it represents an offset from 1970-01-01T00:00:00. If created from string, the string can be in ISO 8601 date or datetime format. |
deg2radufunc | np.deg2rad documentedsignaturenp.deg2rad(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Convert angles from degrees to radians. |
degreesufunc | np.degrees documentedsignaturenp.degrees(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Convert angles from radians to degrees. |
deletefunction | np.delete documentedsignaturenp.delete(arr: ArrayLike, obj: EditIndex, axis?: number | null | undefined): NDArray
| Return a new array with sub-arrays along an axis deleted. For a one dimensional array, this returns those entries not returned by arr[obj]. |
diagfunction | np.diag documentedsignaturenp.diag(v: ArrayInput, k?: number | undefined): NDArray
| Extract a diagonal or construct a diagonal array. |
diag_indicesfunction | np.diagIndices documentedsignaturenp.diagIndices(n: number, ndim?: number | undefined): NDArray[]
| Return the indices to access the main diagonal of an array. |
diag_indices_fromfunction | np.diagIndicesFrom documentedsignaturenp.diagIndicesFrom(arr: NDArray): NDArray[]
| Return the indices to access the main diagonal of an n-dimensional array. |
diagflatfunction | np.diagflat documentedsignaturenp.diagflat(v: ArrayInput, k?: number | undefined): NDArray
| Create a two-dimensional array with the flattened input as a diagonal. |
diagonalfunction | np.diagonal documentedsignaturenp.diagonal(a: ArrayLike, opts?: number | DiagonalOptions | undefined): NDArray
| Return specified diagonals. |
difffunction | np.diff documentedsignaturenp.diff(a: ArrayLike, n?: number | DiffOptions | undefined, axis?: number | undefined): NDArray
| Calculate the n-th discrete difference along the given axis. |
digitizefunction | np.digitize documentedsignaturenp.digitize(x: ArrayLike, bins: ArrayLike, right?: boolean | undefined): NDArray
| Return the indices of the bins to which each value in input array belongs. |
divideufunc | np.divide documentedsignaturenp.divide(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Divide arguments element-wise. |
divmodufunc | np.divmod documentedsignaturenp.divmod(a: Operand, b: Operand, opts?: MultiUfuncOptions | undefined): [NDArray, NDArray]
| Return element-wise quotient and remainder simultaneously. |
dotfunction | np.dot documentedsignaturenp.dot(a: ArrayLike, b: ArrayLike): NDArray
| Dot product of two arrays. Specifically, |
doubleclass | np.double documentedsignaturenp.double: DType
| Double-precision floating-point number type, compatible with Python :class:float and C double. |
dsplitfunction | np.dsplit signaturenp.dsplit(a: ArrayLike, indicesOrSections: number | NDArray | readonly number[]): NDArray[]
| Split array into multiple sub-arrays along the 3rd axis (depth). |
dstackfunction | np.dstack documentedsignaturenp.dstack(arrays: Sequence): NDArray
| Stack arrays in sequence depth wise (along third axis). |
dtypeclass | np.dtype documentedsignaturenp.dtype(like: DTypeLike): DType
| dtype(dtype, align=False, copy=False, **kwargs) -- |
econstant | np.e documentedsignaturenp.e: number
| |
ediff1dfunction | np.ediff1d documentedsignaturenp.ediff1d(a: ArrayLike, opts?: Ediff1dOptions | undefined): NDArray
| The differences between consecutive elements of an array. |
einsumfunction | np.einsum documentedsignaturenp.einsum(subscripts: string, ...operands: (ArrayLike | EinsumOptions)[]): NDArray
np.einsum(...args: (ArrayLike | EinsumOptions | Sublist)[]): NDArray
| Evaluates the Einstein summation convention on the operands. |
einsum_pathfunction | np.einsumPath documentedsignaturenp.einsumPath(subscripts: string, ...operands: (ArrayLike | EinsumOptions)[]): [EinsumPath, string]
np.einsumPath(...args: (ArrayLike | EinsumOptions | Sublist)[]): [EinsumPath, string]
| Evaluates the lowest cost contraction order for an einsum expression by considering the creation of intermediate arrays. |
emptyfunction | np.empty documentedsignaturenp.empty(shape: number | Shape, options?: CreationOptions | undefined): NDArray
| Return a new array of given shape and type, without initializing entries. |
empty_likefunction | np.emptyLike signaturenp.emptyLike(a: NDArray, options?: LikeOptions | undefined): NDArray
| Return a new array with the same shape and type as a given array. |
equalufunc | np.equal documentedsignaturenp.equal(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Return (x1 == x2) element-wise. |
errstateclass | np.errstate documentedsignaturenp.errstate<T>(settings: ErrSettings, fn: () => T): T
| Context manager for floating-point error handling. |
euler_gammaconstant | np.euler_gamma documentedsignaturenp.euler_gamma: number
| |
expufunc | np.exp documentedsignaturenp.exp(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Calculate the exponential of all elements in the input array. |
exp2ufunc | np.exp2 documentedsignaturenp.exp2(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Calculate 2**p for all p in the input array. |
expand_dimsfunction | np.expandDims documentedsignaturenp.expandDims(a: NDArray, axis: number | readonly number[]): NDArray
| Expand the shape of an array. |
expm1ufunc | np.expm1 documentedsignaturenp.expm1(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Calculate exp(x) - 1 for all elements in the array. |
eyefunction | np.eye documentedsignaturenp.eye(n: number, m?: number | undefined, options?: EyeOptions | undefined): NDArray
| Return a 2-D array with ones on the diagonal and zeros elsewhere. |
fabsufunc | np.fabs documentedsignaturenp.fabs(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Compute the absolute values element-wise. |
False_constant | np.False_ documentedsignaturenp.False_: false
| bool(value=False, /) -- |
fill_diagonalfunction | np.fillDiagonal documentedsignaturenp.fillDiagonal(a: NDArray, val: ArrayInput, options?: { wrap?: boolean | undefined; } | undefined): void
| Fill the main diagonal of the given array of any dimensionality. |
finfoclass | np.finfo documentedsignaturenp.finfo(dt: NDArray | DTypeLike): FInfo
| Machine limits for floating point types. |
fixfunction | np.fix documentedsignaturenp.fix(x: ArrayLike, opts?: RoundOptions | undefined): NDArray
| Round to nearest integer towards zero. |
flatnonzerofunction | np.flatnonzero documentedsignaturenp.flatnonzero(a: ArrayLike): NDArray
| Return indices that are non-zero in the flattened version of a. |
flipfunction | np.flip documentedsignaturenp.flip(m: ArrayLike, axis?: Axes | null | undefined): NDArray
| Reverse the order of elements in an array along the given axis. |
fliplrfunction | np.fliplr signaturenp.fliplr(m: ArrayLike): NDArray
| Reverse the order of elements along axis 1 (left/right). |
flipudfunction | np.flipud signaturenp.flipud(m: ArrayLike): NDArray
| Reverse the order of elements along axis 0 (up/down). |
float_powerufunc | np.floatPower documentedsignaturenp.floatPower(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| First array elements raised to powers from second array, element-wise. |
float16class | np.float16 signaturenp.float16: DType
| Half-precision floating-point number type. |
float32class | np.float32 signaturenp.float32: DType
| Single-precision floating-point number type, compatible with C float. |
float64class | np.float64 signaturenp.float64: DType
| Double-precision floating-point number type, compatible with Python :class:float and C double. |
floorufunc | np.floor documentedsignaturenp.floor(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Return the floor of the input, element-wise. |
floor_divideufunc | np.floorDivide documentedsignaturenp.floorDivide(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Return the largest integer smaller or equal to the division of the inputs. It is equivalent to the Python // operator and pairs with the Python % (remainder), function so that a = a % b + b * (a // b) up to roundoff. |
fmaxufunc | np.fmax documentedsignaturenp.fmax(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Element-wise maximum of array elements. |
fminufunc | np.fmin documentedsignaturenp.fmin(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Element-wise minimum of array elements. |
fmodufunc | np.fmod documentedsignaturenp.fmod(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Returns the element-wise remainder of division. |
format_float_positionalfunction | np.formatFloatPositional documentedsignaturenp.formatFloatPositional(x: number | boolean | NDArray, opts?: FormatFloatPositionalOptions | undefined): string
| Format a floating-point scalar as a decimal string in positional notation. |
format_float_scientificfunction | np.formatFloatScientific documentedsignaturenp.formatFloatScientific(x: number | boolean | NDArray, opts?: FormatFloatScientificOptions | undefined): string
| Format a floating-point scalar as a decimal string in scientific notation. |
frexpufunc | np.frexp documentedsignaturenp.frexp(x: ArrayLike, opts?: MultiUfuncOptions | undefined): [NDArray, NDArray]
| Decompose the elements of x into mantissa and twos exponent. |
frombufferfunction | np.frombuffer documentedsignaturenp.frombuffer(buffer: ArrayBufferLike | ArrayBufferView<ArrayBufferLike>, options?: FrombufferOptions | undefined): NDArray
| Interpret a buffer as a 1-dimensional array. |
fromfilefunction | np.fromfile documentedsignaturenp.fromfile(file: string | URL | Uint8Array<ArrayBufferLike>, options?: FromfileOptions | undefined): NDArray
| Construct an array from data in a text or binary file. |
fromfunctionfunction | np.fromfunction documentedsignaturenp.fromfunction<R>(fn: (...coords: NDArray[]) => R, shape: Shape, options?: { dtype?: DTypeLike | undefined; } | undefined): R
| Construct an array by executing a function over each coordinate. |
fromiterfunction | np.fromiter documentedsignaturenp.fromiter(iterable: Iterable<number | bigint | boolean | ComplexLike>, dtype: DTypeLike, count?: number | undefined): NDArray
| Create a new 1-dimensional array from an iterable object. |
fromregexfunction | np.fromregex documentedsignaturenp.fromregex(file: TextSource, regexp: string | RegExp, dtype: FieldList): Record<string, NDArray>
| Construct an array from a text file, using regular expression parsing. |
fromstringfunction | np.fromstring documentedsignaturenp.fromstring(text: string, options?: FromstringOptions | undefined): NDArray
| A new 1-D array initialized from text data in a string. |
fullfunction | np.full documentedsignaturenp.full(shape: number | Shape, fillValue: number | bigint | boolean | ComplexLike, options?: CreationOptions | undefined): NDArray
| Return a new array of given shape and type, filled with fill_value. |
full_likefunction | np.fullLike signaturenp.fullLike(a: NDArray, fillValue: number | bigint | boolean | ComplexLike, options?: LikeOptions | undefined): NDArray
| Return a full array with the same shape and type as a given array. |
gcdufunc | np.gcd documentedsignaturenp.gcd(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Returns the greatest common divisor of |x1| and |x2| |
genfromtxtfunction | np.genfromtxt documentedsignaturenp.genfromtxt(fname: TextSource, options?: GenfromtxtOptions | undefined): NDArray
| Load data from a text file, with missing values handled as specified. |
geomspacefunction | np.geomspace documentedsignaturenp.geomspace(start: ScalarLike, stop: ScalarLike, num?: number | undefined, options?: GeomspaceOptions | undefined): NDArray
| Return numbers spaced evenly on a log scale (a geometric progression). |
get_printoptionsfunction | np.getPrintoptions documentedsignaturenp.getPrintoptions(): PrintOptions
| Return the current print options. |
geterrfunction | np.geterr documentedsignaturenp.geterr(): ErrState
| Get the current way of handling floating-point errors. |
gradientfunction | np.gradient documentedsignaturenp.gradient(f: ArrayLike, ...args: (Spacing | GradientOptions)[]): NDArray | NDArray[]
| Return the gradient of an N-dimensional array. |
greaterufunc | np.greater documentedsignaturenp.greater(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Return the truth value of (x1 > x2) element-wise. |
greater_equalufunc | np.greaterEqual documentedsignaturenp.greaterEqual(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Return the truth value of (x1 >= x2) element-wise. |
halfclass | np.half documentedsignaturenp.half: DType
| Half-precision floating-point number type. |
hammingfunction | np.hamming documentedsignaturenp.hamming(M: number | bigint | NDArray): NDArray
| Return the Hamming window. |
hanningfunction | np.hanning documentedsignaturenp.hanning(M: number | bigint | NDArray): NDArray
| Return the Hanning window. |
heavisideufunc | np.heaviside documentedsignaturenp.heaviside(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Compute the Heaviside step function. |
histogramfunction | np.histogram documentedsignaturenp.histogram(a: ArrayLike, bins?: BinsArg | undefined, opts?: HistogramOptions | undefined): HistogramResult
| Compute the histogram of a dataset. |
histogram_bin_edgesfunction | np.histogramBinEdges documentedsignaturenp.histogramBinEdges(a: ArrayLike, bins?: BinsArg | undefined, opts?: HistogramOptions | undefined): NDArray
| Function to calculate only the edges of the bins used by the histogram function. |
histogram2dfunction | np.histogram2d documentedsignaturenp.histogram2d(x: ArrayLike, y: ArrayLike, bins?: BinsArg | [BinsArg, BinsArg] | undefined, opts?: Omit<Histogram2dOptions, "bins"> | undefined): Histogram2dResult
| Compute the bi-dimensional histogram of two data samples. |
histogramddfunction | np.histogramdd documentedsignaturenp.histogramdd(sample: ArrayLike, bins?: BinsArg | BinsArg[] | undefined, opts?: HistogramddOptions | undefined): HistogramddResult
| Compute the multidimensional histogram of some data. |
hsplitfunction | np.hsplit signaturenp.hsplit(a: ArrayLike, indicesOrSections: number | NDArray | readonly number[]): NDArray[]
| Split an array into multiple sub-arrays horizontally (column-wise). |
hstackfunction | np.hstack documentedsignaturenp.hstack(arrays: Sequence, options?: VHStackOptions | undefined): NDArray
| Stack arrays in sequence horizontally (column wise). |
hypotufunc | np.hypot documentedsignaturenp.hypot(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Given the "legs" of a right triangle, return its hypotenuse. |
i0function | np.i0 documentedsignaturenp.i0(x: ArrayLike): NDArray
| Modified Bessel function of the first kind, order 0. |
identityfunction | np.identity documentedsignaturenp.identity(n: number, options?: ArrayOptions | undefined): NDArray
| Return the identity array. |
iinfoclass | np.iinfo documentedsignaturenp.iinfo(dt: NDArray | DTypeLike): IInfo
| Machine limits for integer types. |
imagfunction | np.imag documentedsignaturenp.imag(a: ArrayLike): NDArray
| Return the imaginary part of the complex argument. |
index_expconstant | np.indexExp documentedsignaturenp.indexExp(...specs: (string | number | boolean | NDArray | readonly [] | readonly [number | null] | readonly [number | null, number | null] | readonly [number | null, number | null, number | null] | null)[]): IndexSpec[]
| A nicer way to build up index tuples for arrays. |
indicesfunction | np.indices documentedsignaturenp.indices(dimensions: readonly number[], options: IndicesOptions & { sparse: true; }): NDArray[]
np.indices(dimensions: readonly number[], options?: IndicesOptions | undefined): NDArray
| Return an array representing the indices of a grid. |
infconstant | np.inf documentedsignaturenp.inf: number
| |
innerfunction | np.inner documentedsignaturenp.inner(a: ArrayLike, b: ArrayLike): NDArray
| Inner product of two arrays. |
insertfunction | np.insert documentedsignaturenp.insert(arr: ArrayLike, obj: EditIndex, values: ArrayLike, axis?: number | null | undefined): NDArray
| Insert values along the given axis before the given indices. |
int_class | np.int_ documentedsignaturenp.int_: DType
| Signed integer type, compatible with C long. |
int16class | np.int16 signaturenp.int16: DType
| Signed integer type, compatible with C short. |
int32class | np.int32 signaturenp.int32: DType
| Signed integer type, compatible with C int. |
int64class | np.int64 signaturenp.int64: DType
| Signed integer type, compatible with C long. |
int8class | np.int8 signaturenp.int8: DType
| Signed integer type, compatible with C char. |
intcclass | np.intc documentedsignaturenp.intc: DType
| Signed integer type, compatible with C int. |
interpfunction | np.interp documentedsignaturenp.interp(x: ArrayLike, xp: ArrayLike, fp: ArrayLike, opts?: InterpOptions | undefined): NDArray
| One-dimensional linear interpolation for monotonically increasing sample points. |
intersect1dfunction | np.intersect1d documentedsignaturenp.intersect1d(a: ArrayLike, b: ArrayLike, opts?: { assumeUnique?: boolean | undefined; returnIndices?: false | undefined; } | undefined): NDArray
np.intersect1d(a: ArrayLike, b: ArrayLike, opts: { assumeUnique?: boolean | undefined; returnIndices: true; }): IntersectResult
| Find the intersection of two arrays. |
intpclass | np.intp documentedsignaturenp.intp: DType
| Signed integer type, compatible with C long. |
invertufunc | np.invert documentedsignaturenp.invert(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Compute bit-wise inversion, or bit-wise NOT, element-wise. |
is_busdayfunction | np.is_busday documentedsignaturenp.is_busday(dates: string | number | bigint | DatetimeArray | (string | number | bigint | DatetimeArray)[], options?: IsBusdayOptions | undefined): boolean | boolean[]
| Calculates which of the given dates are valid days, and which are not. |
isclosefunction | np.isclose documentedsignaturenp.isclose(a: CloseOperand, b: CloseOperand, opts?: IscloseOptions | undefined): NDArray
| Returns a boolean array where two arrays are element-wise equal within a tolerance. |
iscomplexfunction | np.iscomplex documentedsignaturenp.iscomplex(a: ArrayLike): NDArray
| Returns a bool array, where True if input element is complex. |
iscomplexobjfunction | np.iscomplexobj documentedsignaturenp.iscomplexobj(a: ArrayLike): boolean
| Check for a complex type or an array of complex numbers. |
isdtypefunction | np.isdtype documentedsignaturenp.isdtype(dt: DType, kind: string | DType | readonly (string | DType)[]): boolean
| Determine if a provided dtype is of a specified data type kind. |
isfiniteufunc | np.isfinite documentedsignaturenp.isfinite(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Test element-wise for finiteness (not infinity and not Not a Number). |
isfortranfunction | np.isfortran documentedsignaturenp.isfortran(a: NDArray): boolean
| Check if the array is Fortran contiguous but not C contiguous. |
isinfunction | np.isin documentedsignaturenp.isin(element: ArrayLike, testElements: ArrayLike, opts?: IsinOptions | undefined): NDArray
| Calculates element in test_elements, broadcasting over element only. Returns a boolean array of the same shape as element that is True where an element of element is in test_elements and False otherwise. |
isinfufunc | np.isinf documentedsignaturenp.isinf(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Test element-wise for positive or negative infinity. |
isnanufunc | np.isnan documentedsignaturenp.isnan(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Test element-wise for NaN and return result as a boolean array. |
isnatufunc | np.isnat documentedsignaturenp.isnat(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Test element-wise for NaT (not a time) and return result as a boolean array. |
isneginffunction | np.isneginf documentedsignaturenp.isneginf(x: ArrayLike, opts?: { out?: NDArray | null | undefined; } | undefined): NDArray
| Test element-wise for negative infinity, return result as bool array. |
isposinffunction | np.isposinf documentedsignaturenp.isposinf(x: ArrayLike, opts?: { out?: NDArray | null | undefined; } | undefined): NDArray
| Test element-wise for positive infinity, return result as bool array. |
isrealfunction | np.isreal documentedsignaturenp.isreal(a: ArrayLike): NDArray
| Returns a bool array, where True if input element is real. |
isrealobjfunction | np.isrealobj documentedsignaturenp.isrealobj(a: ArrayLike): boolean
| Return True if x is a not complex type or an array of complex numbers. |
isscalarfunction | np.isscalar documentedsignaturenp.isscalar(x: unknown): boolean
| Returns True if the type of element is a scalar type. |
issubdtypefunction | np.issubdtype documentedsignaturenp.issubdtype(a: DTypeLike | AbstractDType, b: DTypeLike | AbstractDType): boolean
| Returns True if first argument is a typecode lower/equal in type hierarchy. |
ix_function | np.ix_ documentedsignaturenp.ix_(...seqs: ArrayInput[]): NDArray[]
| Construct an open mesh from multiple sequences. |
kaiserfunction | np.kaiser documentedsignaturenp.kaiser(M: number | bigint | NDArray, beta: number | NDArray): NDArray
| Return the Kaiser window. |
kronfunction | np.kron documentedsignaturenp.kron(a: ArrayLike, b: ArrayLike): NDArray
| Kronecker product of two arrays. |
lcmufunc | np.lcm documentedsignaturenp.lcm(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Returns the lowest common multiple of |x1| and |x2| |
ldexpufunc | np.ldexp documentedsignaturenp.ldexp(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Returns x1 * 2**x2, element-wise. |
left_shiftufunc | np.leftShift documentedsignaturenp.leftShift(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Shift the bits of an integer to the left. |
lessufunc | np.less documentedsignaturenp.less(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Return the truth value of (x1 < x2) element-wise. |
less_equalufunc | np.lessEqual documentedsignaturenp.lessEqual(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Return the truth value of (x1 <= x2) element-wise. |
lexsortfunction | np.lexsort documentedsignaturenp.lexsort(keys: NDArray | readonly ArrayLike[], opts?: { axis?: number | null | undefined; } | undefined): NDArray
| Perform an indirect stable sort using a sequence of keys. |
linspacefunction | np.linspace documentedsignaturenp.linspace(start: number, stop: number, num?: number | undefined, options?: LinspaceOptions | undefined): NDArray
| Return evenly spaced numbers over a specified interval. |
loadfunction | np.load documentedsignaturenp.load(file: string | URL | BytesLike, options?: LoadOptions | undefined): NDArray | NpzFile
| Load arrays or pickled objects from .npy, .npz or pickled files. |
loadtxtfunction | np.loadtxt documentedsignaturenp.loadtxt(fname: TextSource, options?: LoadtxtOptions | undefined): NDArray
| Load data from a text file. |
logufunc | np.log documentedsignaturenp.log(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Natural logarithm, element-wise. |
log10ufunc | np.log10 documentedsignaturenp.log10(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Return the base 10 logarithm of the input array, element-wise. |
log1pufunc | np.log1p documentedsignaturenp.log1p(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Return the natural logarithm of one plus the input array, element-wise. |
log2ufunc | np.log2 documentedsignaturenp.log2(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Base-2 logarithm of x. |
logaddexpufunc | np.logaddexp documentedsignaturenp.logaddexp(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Logarithm of the sum of exponentiations of the inputs. |
logaddexp2ufunc | np.logaddexp2 documentedsignaturenp.logaddexp2(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Logarithm of the sum of exponentiations of the inputs in base-2. |
logical_andufunc | np.logicalAnd documentedsignaturenp.logicalAnd(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Compute the truth value of x1 AND x2 element-wise. |
logical_notufunc | np.logicalNot documentedsignaturenp.logicalNot(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Compute the truth value of NOT x element-wise. |
logical_orufunc | np.logicalOr documentedsignaturenp.logicalOr(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Compute the truth value of x1 OR x2 element-wise. |
logical_xorufunc | np.logicalXor documentedsignaturenp.logicalXor(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Compute the truth value of x1 XOR x2, element-wise. |
logspacefunction | np.logspace documentedsignaturenp.logspace(start: ScalarLike, stop: ScalarLike, num?: number | undefined, options?: LogspaceOptions | undefined): NDArray
| Return numbers spaced evenly on a log scale. |
longclass | np.long signaturenp.long: DType
| Signed integer type, compatible with C long. |
mask_indicesfunction | np.maskIndices documentedsignaturenp.maskIndices(n: number, maskFunc: (m: NDArray, k: number) => NDArray, k?: number | undefined): NDArray[]
| Return the indices to access (n, n) arrays, given a masking function. |
matmulufunc | np.matmul documentedsignaturenp.matmul(a: ArrayLike, b: ArrayLike): NDArray
| Matrix product of two arrays. |
matrix_transposefunction | np.matrixTranspose signaturenp.matrixTranspose(x: ArrayLike): NDArray
| Transposes a matrix (or a stack of matrices) x. |
matvecufunc | np.matvec documentedsignaturenp.matvec(x1: ArrayLike, x2: ArrayLike): NDArray
| Matrix-vector dot product of two arrays. |
maxfunction | np.max documentedsignaturenp.max(a: ArrayLike, opts?: Omit<ReduceOptions, "dtype"> | undefined): NDArray
| Return the maximum of an array or maximum along an axis. |
maximumufunc | np.maximum documentedsignaturenp.maximum(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Element-wise maximum of array elements. |
may_share_memoryfunction | np.mayShareMemory documentedsignaturenp.mayShareMemory(a: NDArray, b: NDArray): boolean
| Determine if two arrays might share memory |
meanfunction | np.mean documentedsignaturenp.mean(a: ArrayLike, opts?: Omit<ReduceOptions, "initial"> | undefined): NDArray
| Compute the arithmetic mean along the specified axis. |
medianfunction | np.median documentedsignaturenp.median(a: ArrayLike, opts?: MedianOptions | undefined): NDArray
| Compute the median along the specified axis. |
meshgridfunction | np.meshgrid documentedsignaturenp.meshgrid(...args: (ArrayInput | MeshgridOptions)[]): NDArray[]
| Return a tuple of coordinate matrices from coordinate vectors. |
mgridconstant | np.mgrid documentedsignaturenp.mgrid(...slices: GridSlice[]): NDArray
| An instance which returns a dense multi-dimensional "meshgrid". |
minfunction | np.min documentedsignaturenp.min(a: ArrayLike, opts?: Omit<ReduceOptions, "dtype"> | undefined): NDArray
| Return the minimum of an array or minimum along an axis. |
min_scalar_typefunction | np.minScalarType documentedsignaturenp.minScalarType(a: NDArray | JSScalar): DType
| For scalar a, returns the data type with the smallest size and smallest scalar kind which can hold its value. For non-scalar array a, returns the vector's dtype unmodified. |
minimumufunc | np.minimum documentedsignaturenp.minimum(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Element-wise minimum of array elements. |
mintypecodefunction | np.mintypecode documentedsignaturenp.mintypecode(typechars: string | readonly (string | NDArray | NestedArray | DType)[], typeset?: string | undefined, defaultCode?: string | undefined): string
| Return the character for the minimum-size type to which given types can be safely cast. |
modufunc | np.mod documentedsignaturenp.mod(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Returns the element-wise remainder of division. |
modfufunc | np.modf documentedsignaturenp.modf(x: ArrayLike, opts?: MultiUfuncOptions | undefined): [NDArray, NDArray]
| Return the fractional and integral parts of an array, element-wise. |
moveaxisfunction | np.moveAxis documentedsignaturenp.moveAxis(a: NDArray, source: number | readonly number[], destination: number | readonly number[]): NDArray
| Move axes of an array to new positions. |
multiplyufunc | np.multiply documentedsignaturenp.multiply(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Multiply arguments element-wise. |
nanconstant | np.nan documentedsignaturenp.nan: number
| |
nan_to_numfunction | np.nanToNum documentedsignaturenp.nanToNum(x: ArrayLike, opts?: NanToNumOptions | undefined): NDArray
| Replace NaN with zero and infinity with large finite numbers (default behaviour) or with the numbers defined by the user using the nan, posinf and/or neginf keywords. |
nanargmaxfunction | np.nanargmax documentedsignaturenp.nanargmax(a: ArrayLike, opts?: ArgReduceOptions | undefined): NDArray
| Return the indices of the maximum values in the specified axis ignoring NaNs. For all-NaN slices ValueError is raised. Warning: the results cannot be trusted if a slice contains only NaNs and -Infs. |
nanargminfunction | np.nanargmin documentedsignaturenp.nanargmin(a: ArrayLike, opts?: ArgReduceOptions | undefined): NDArray
| Return the indices of the minimum values in the specified axis ignoring NaNs. For all-NaN slices ValueError is raised. Warning: the results cannot be trusted if a slice contains only NaNs and Infs. |
nancumprodfunction | np.nancumprod documentedsignaturenp.nancumprod(a: ArrayLike, opts?: CumsumOptions | undefined): NDArray
| Return the cumulative product of array elements over a given axis treating Not a Numbers (NaNs) as one. The cumulative product does not change when NaNs are encountered and leading NaNs are replaced by ones. |
nancumsumfunction | np.nancumsum documentedsignaturenp.nancumsum(a: ArrayLike, opts?: CumsumOptions | undefined): NDArray
| Return the cumulative sum of array elements over a given axis treating Not a Numbers (NaNs) as zero. The cumulative sum does not change when NaNs are encountered and leading NaNs are replaced by zeros. |
nanmaxfunction | np.nanmax documentedsignaturenp.nanmax(a: ArrayLike, opts?: Omit<ReduceOptions, "dtype"> | undefined): NDArray
| Return the maximum of an array or maximum along an axis, ignoring any NaNs. When all-NaN slices are encountered a RuntimeWarning is raised and NaN is returned for that slice. |
nanmeanfunction | np.nanmean documentedsignaturenp.nanmean(a: ArrayLike, opts?: Omit<ReduceOptions, "initial"> | undefined): NDArray
| Compute the arithmetic mean along the specified axis, ignoring NaNs. |
nanmedianfunction | np.nanmedian documentedsignaturenp.nanmedian(a: ArrayLike, opts?: MedianOptions | undefined): NDArray
| Compute the median along the specified axis, while ignoring NaNs. |
nanminfunction | np.nanmin documentedsignaturenp.nanmin(a: ArrayLike, opts?: Omit<ReduceOptions, "dtype"> | undefined): NDArray
| Return minimum of an array or minimum along an axis, ignoring any NaNs. When all-NaN slices are encountered a RuntimeWarning is raised and Nan is returned for that slice. |
nanpercentilefunction | np.nanpercentile documentedsignaturenp.nanpercentile(a: ArrayLike, q: ArrayLike, opts?: QuantileOptions | undefined): NDArray
| Compute the qth percentile of the data along the specified axis, while ignoring nan values. |
nanprodfunction | np.nanprod documentedsignaturenp.nanprod(a: ArrayLike, opts?: ReduceOptions | undefined): NDArray
| Return the product of array elements over a given axis treating Not a Numbers (NaNs) as ones. |
nanquantilefunction | np.nanquantile documentedsignaturenp.nanquantile(a: ArrayLike, q: ArrayLike, opts?: QuantileOptions | undefined): NDArray
| Compute the qth quantile of the data along the specified axis, while ignoring nan values. Returns the qth quantile(s) of the array elements. |
nanstdfunction | np.nanstd documentedsignaturenp.nanstd(a: ArrayLike, opts?: VarOptions | undefined): NDArray
| Compute the standard deviation along the specified axis, while ignoring NaNs. |
nansumfunction | np.nansum documentedsignaturenp.nansum(a: ArrayLike, opts?: ReduceOptions | undefined): NDArray
| Return the sum of array elements over a given axis treating Not a Numbers (NaNs) as zero. |
nanvarfunction | np.nanvar documentedsignaturenp.nanvar(a: ArrayLike, opts?: VarOptions | undefined): NDArray
| Compute the variance along the specified axis, while ignoring NaNs. |
ndarrayclass | np.NDArray signaturenew np.NDArray(token: typeof internal, handle: NativeNDArray)
| An array object represents a multidimensional, homogeneous array of fixed-size items. An associated data-type object describes the format of each element in the array (its byte-order, how many bytes it occupies in memory, whether it is an integer, a floating point number, or something else, etc.) |
ndenumerateclass | np.ndenumerate documentedsignaturenp.ndenumerate(a: Operand): Generator<[number[], ScalarValue], any, any>
| Multidimensional index iterator. |
ndimfunction | np.ndim documentedsignaturenp.ndim(a: ArrayLike): number
| Return the number of dimensions of an array. |
ndindexclass | np.ndindex documentedsignaturenp.ndindex(...shape: (number | readonly number[])[]): Generator<number[], any, any>
| An N-dimensional iterator object to index arrays. |
negativeufunc | np.negative documentedsignaturenp.negative(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Numerical negation, element-wise. |
newaxisconstant | np.newaxis signaturenp.newaxis: "newaxis"
| |
nextafterufunc | np.nextafter documentedsignaturenp.nextafter(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Return the next floating-point value after x1 towards x2, element-wise. |
nonzerofunction | np.nonzero documentedsignaturenp.nonzero(a: NDArray | NestedArray): NDArray[]
| Return the indices of the elements that are non-zero. |
not_equalufunc | np.notEqual documentedsignaturenp.notEqual(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Return (x1 != x2) element-wise. |
ogridconstant | np.ogrid documentedsignaturenp.ogrid(slice: GridSlice): NDArray
np.ogrid(...slices: GridSlice[]): NDArray[]
| An instance which returns an open multi-dimensional "meshgrid". |
onesfunction | np.ones documentedsignaturenp.ones(shape: number | Shape, options?: CreationOptions | undefined): NDArray
| Return a new array of given shape and type, filled with ones. |
ones_likefunction | np.onesLike signaturenp.onesLike(a: NDArray, options?: LikeOptions | undefined): NDArray
| Return an array of ones with the same shape and type as a given array. |
outerfunction | np.outer documentedsignaturenp.outer(a: ArrayLike, b: ArrayLike): NDArray
| Compute the outer product of two vectors. |
packbitsfunction | np.packbits documentedsignaturenp.packbits(a: ArrayLike, opts?: PackbitsOptions | undefined): NDArray
| Packs the elements of a binary-valued array into bits in a uint8 array. |
padfunction | np.pad documentedsignaturenp.pad(a: ArrayLike, padWidth: PadWidth, mode?: PadMode | PadFunction | undefined, options?: (PadOptions & Record<string, unknown>) | undefined): NDArray
| Pad an array. |
partitionfunction | np.partition documentedsignaturenp.partition(a: ArrayLike, kth: Kth, opts?: PartitionOptions | undefined): NDArray
| Return a partitioned copy of an array. |
percentilefunction | np.percentile documentedsignaturenp.percentile(a: ArrayLike, q: ArrayLike, opts?: QuantileOptions | undefined): NDArray
| Compute the q-th percentile of the data along the specified axis. |
permute_dimsfunction | np.permuteDims signaturenp.permuteDims(a: ArrayLike, axes?: readonly number[] | undefined): NDArray
| Returns an array with axes transposed. |
piconstant | np.pi documentedsignaturenp.pi: number
| |
piecewisefunction | np.piecewise documentedsignaturenp.piecewise(x: ArrayLike, condlist: ArrayLike | readonly ArrayLike[], funclist: readonly PiecewiseFunc[]): NDArray
| Evaluate a piecewise-defined function. |
placefunction | np.place documentedsignaturenp.place(arr: NDArray, mask: ArrayLike, vals: ArrayLike): void
| Change elements of an array based on conditional and input values. |
polyfunction | np.poly documentedsignaturenp.poly(seqOfZeros: ArrayLike): number | NDArray
| Find the coefficients of a polynomial with the given sequence of roots. |
poly1dclass | np.poly1d documentedsignaturenew np.poly1d(cOrR: PolyLike, options?: boolean | Poly1dOptions | undefined)
| A one-dimensional polynomial class. |
polyaddfunction | np.polyadd documentedsignaturenp.polyadd(a1: poly1d, a2: PolyLike): poly1d
np.polyadd(a1: PolyLike, a2: poly1d): poly1d
np.polyadd(a1: ArrayLike, a2: ArrayLike): NDArray
| Find the sum of two polynomials. |
polyderfunction | np.polyder documentedsignaturenp.polyder(p: poly1d, m?: number | undefined): poly1d
np.polyder(p: ArrayLike, m?: number | undefined): NDArray
| Return the derivative of the specified order of a polynomial. |
polydivfunction | np.polydiv documentedsignaturenp.polydiv(u: poly1d, v: PolyLike): [poly1d, poly1d]
np.polydiv(u: PolyLike, v: poly1d): [poly1d, poly1d]
np.polydiv(u: ArrayLike, v: ArrayLike): [NDArray, NDArray]
| Returns the quotient and remainder of polynomial division. |
polyfitfunction | np.polyfit documentedsignaturenp.polyfit(x: ArrayLike, y: ArrayLike, deg: number, options?: PolyfitOptions | undefined): NDArray | (number | NDArray)[]
| Least squares polynomial fit. |
polyintfunction | np.polyint documentedsignaturenp.polyint(p: poly1d, m?: number | undefined, k?: ArrayLike | null | undefined): poly1d
np.polyint(p: ArrayLike, m?: number | undefined, k?: ArrayLike | null | undefined): NDArray
| Return an antiderivative (indefinite integral) of a polynomial. |
polymulfunction | np.polymul documentedsignaturenp.polymul(a1: poly1d, a2: PolyLike): poly1d
np.polymul(a1: PolyLike, a2: poly1d): poly1d
np.polymul(a1: ArrayLike, a2: ArrayLike): NDArray
| Find the product of two polynomials. |
polysubfunction | np.polysub documentedsignaturenp.polysub(a1: poly1d, a2: PolyLike): poly1d
np.polysub(a1: PolyLike, a2: poly1d): poly1d
np.polysub(a1: ArrayLike, a2: ArrayLike): NDArray
| Difference (subtraction) of two polynomials. |
polyvalfunction | np.polyval documentedsignaturenp.polyval(p: PolyLike, x: poly1d): poly1d
np.polyval(p: PolyLike, x: ArrayLike): NDArray
| Evaluate a polynomial at specific values. |
positiveufunc | np.positive documentedsignaturenp.positive(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Numerical positive, element-wise. |
powufunc | np.pow documentedsignaturenp.pow(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| First array elements raised to powers from second array, element-wise. |
powerufunc | np.power documentedsignaturenp.power(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| First array elements raised to powers from second array, element-wise. |
printoptionsfunction | np.printoptions documentedsignaturenp.printoptions<T>(opts: PrintOptionsInput, fn: () => T): T
| Context manager for setting print options. |
prodfunction | np.prod documentedsignaturenp.prod(a: ArrayLike, opts?: ReduceOptions | undefined): NDArray
| Return the product of array elements over a given axis. |
promote_typesfunction | np.promoteTypes documentedsignaturenp.promoteTypes(a: DTypeLike, b: DTypeLike): DType
| Returns the data type with the smallest size and smallest scalar kind to which both type1 and type2 may be safely cast. The returned data type is always considered "canonical", this mainly means that the promoted dtype will always be in native byte order. |
putfunction | np.put documentedsignaturenp.put(a: NDArray, ind: ArrayLike, v: ArrayLike, opts?: PutOptions | undefined): void
| Replaces specified elements of an array with given values. |
put_along_axisfunction | np.putAlongAxis documentedsignaturenp.putAlongAxis(arr: NDArray, indices: ArrayLike, values: ArrayLike, axis: number | null): void
| Put values into the destination array by matching 1d index and data slices. |
putmaskfunction | np.putmask documentedsignaturenp.putmask(a: NDArray, mask: ArrayLike, values: ArrayLike): void
| Changes elements of an array based on conditional and input values. |
quantilefunction | np.quantile documentedsignaturenp.quantile(a: ArrayLike, q: ArrayLike, opts?: QuantileOptions | undefined): NDArray
| Compute the q-th quantile of the data along the specified axis. |
r_constant | np.r_ documentedsignaturenp.r_(...items: ConcatItem[]): NDArray
| Translates slice objects to concatenation along the first axis. |
rad2degufunc | np.rad2deg documentedsignaturenp.rad2deg(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Convert angles from radians to degrees. |
radiansufunc | np.radians documentedsignaturenp.radians(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Convert angles from degrees to radians. |
ravelfunction | np.ravel documentedsignaturenp.ravel(a: NDArray, opts?: OrderOptions | undefined): NDArray
| Return a contiguous flattened array. |
ravel_multi_indexfunction | np.ravelMultiIndex documentedsignaturenp.ravelMultiIndex(multiIndex: readonly ArrayLike[], dims: number | Shape, opts?: RavelMultiIndexOptions | undefined): NDArray
| Converts a tuple of index arrays into an array of flat indices, applying boundary modes to the multi-index. |
realfunction | np.real documentedsignaturenp.real(a: ArrayLike): NDArray
| Return the real part of the complex argument. |
real_if_closefunction | np.realIfClose documentedsignaturenp.realIfClose(x: ArrayLike, tol?: number | undefined): NDArray
| If input is complex with all imaginary parts close to zero, return real parts. |
recarrayclass | np.recarray documentedsignaturenew np.recarray(shape: number | number[], opts?: RecArrayOptions | undefined)
| Construct an ndarray that allows field access using attributes. |
reciprocalufunc | np.reciprocal documentedsignaturenp.reciprocal(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Return the reciprocal of the argument, element-wise. |
remainderufunc | np.remainder documentedsignaturenp.remainder(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Returns the element-wise remainder of division. |
repeatfunction | np.repeat documentedsignaturenp.repeat(a: ArrayLike, repeats: IntList, axis?: number | null | undefined): NDArray
| Repeat each element of an array after themselves |
requirefunction | np.require documentedsignaturenp.require(a: ArrayLike, dtype?: DTypeLike | null | undefined, requirements?: Requirements | null | undefined): NDArray
| Return an ndarray of the provided type that satisfies requirements. |
reshapefunction | np.reshape documentedsignaturenp.reshape(a: NDArray, shape: number | Shape, opts?: OrderOptions | undefined): NDArray
| Returns a reshaped ndarray without changing data. |
resizefunction | np.resize documentedsignaturenp.resize(a: ArrayLike, newShape: number | readonly number[]): NDArray
| Return a new array with the specified shape. |
result_typefunction | np.resultType documentedsignaturenp.resultType(...args: (NDArray | NestedArray | DTypeLike)[]): DType
| Returns the type that results from applying the NumPy :ref:type promotion <arrays.promotion> rules to the arguments. |
right_shiftufunc | np.rightShift documentedsignaturenp.rightShift(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Shift the bits of an integer to the right. |
rintufunc | np.rint documentedsignaturenp.rint(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Round elements of the array to the nearest integer. |
rollfunction | np.roll documentedsignaturenp.roll(a: ArrayLike, shift: Axes, axis?: Axes | null | undefined): NDArray
| Roll array elements along a given axis. |
rollaxisfunction | np.rollaxis documentedsignaturenp.rollaxis(a: ArrayLike, axis: number, start?: number | undefined): NDArray
| Roll the specified axis backwards, until it lies in a given position. |
rootsfunction | np.roots documentedsignaturenp.roots(p: PolyLike): NDArray
| Return the roots of a polynomial with coefficients given in p. |
rot90function | np.rot90 documentedsignaturenp.rot90(m: ArrayLike, k?: number | undefined, axes?: readonly number[] | undefined): NDArray
| Rotate an array by 90 degrees in the plane specified by axes. |
roundfunction | np.round documentedsignaturenp.round(a: ArrayLike, decimals?: number | undefined, opts?: RoundOptions | undefined): NDArray
| Evenly round to the given number of decimals. |
s_constant | np.s_ documentedsignaturenp.s_(spec: string | number | boolean | NDArray | readonly [] | readonly [number | null] | readonly [number | null, number | null] | readonly [number | null, number | null, number | null] | null): IndexSpec
np.s_(...specs: (string | number | boolean | NDArray | readonly [] | readonly [number | null] | readonly [number | null, number | null] | readonly [number | null, number | null, number | null] | null)[]): IndexSpec[]
| A nicer way to build up index tuples for arrays. |
savefunction | np.save documentedsignaturenp.save(file: FileLike, arr: ArrayLike): any
| Save an array to a binary file in NumPy .npy format. |
savetxtfunction | np.savetxt documentedsignaturenp.savetxt(fname: string | URL | null, X: ArrayLike, options?: SavetxtOptions | undefined): string | undefined
| Save an array to a text file. |
savezfunction | np.savez documentedsignaturenp.savez(file: FileLike, ...arrays: (ArrayLike | NamedArrays)[]): any
| Save several arrays into a single file in uncompressed .npz format. |
savez_compressedfunction | np.savezCompressed documentedsignaturenp.savezCompressed(file: FileLike, ...arrays: (ArrayLike | NamedArrays)[]): any
| Save several arrays into a single file in compressed .npz format. |
searchsortedfunction | np.searchsorted documentedsignaturenp.searchsorted(a: ArrayLike, v: number | bigint | boolean | NDArray | Complex | { readonly re: number; readonly im?: number | undefined; } | readonly NestedArray[], opts?: SearchsortedOptions | undefined): NDArray
| Find indices where elements should be inserted to maintain order. |
selectfunction | np.select documentedsignaturenp.select(condlist: readonly ArrayLike[], choicelist: readonly ArrayLike[], opts?: SelectOptions | undefined): NDArray
| Return an array drawn from elements in choicelist, depending on conditions. |
set_printoptionsfunction | np.setPrintoptions documentedsignaturenp.setPrintoptions(opts?: PrintOptionsInput | undefined): void
| Set printing options. |
setdiff1dfunction | np.setdiff1d documentedsignaturenp.setdiff1d(a: ArrayLike, b: ArrayLike, opts?: { assumeUnique?: boolean | undefined; } | undefined): NDArray
| Find the set difference of two arrays. |
seterrfunction | np.seterr documentedsignaturenp.seterr(settings?: ErrSettings | undefined): ErrState
| Set how floating-point errors are handled. |
setxor1dfunction | np.setxor1d documentedsignaturenp.setxor1d(a: ArrayLike, b: ArrayLike, opts?: { assumeUnique?: boolean | undefined; } | undefined): NDArray
| Find the set exclusive-or of two arrays. |
shapefunction | np.shape documentedsignaturenp.shape(a: ArrayLike): number[]
| Return the shape of an array. |
shares_memoryfunction | np.sharesMemory documentedsignaturenp.sharesMemory(a: NDArray, b: NDArray, _opts?: SharesMemoryOptions | undefined): boolean
| Determine if two arrays share memory. |
shortclass | np.short documentedsignaturenp.short: DType
| Signed integer type, compatible with C short. |
signufunc | np.sign documentedsignaturenp.sign(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Returns an element-wise indication of the sign of a number. |
signbitufunc | np.signbit documentedsignaturenp.signbit(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Returns element-wise True where signbit is set (less than zero). |
sinufunc | np.sin documentedsignaturenp.sin(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Trigonometric sine, element-wise. |
sincfunction | np.sinc documentedsignaturenp.sinc(x: ArrayLike): NDArray
| Return the normalized sinc function. |
singleclass | np.single documentedsignaturenp.single: DType
| Single-precision floating-point number type, compatible with C float. |
sinhufunc | np.sinh documentedsignaturenp.sinh(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Hyperbolic sine, element-wise. |
sizefunction | np.size documentedsignaturenp.size(a: ArrayLike, axis?: number | readonly number[] | null | undefined): number
| Return the number of elements along a given axis. |
sortfunction | np.sort documentedsignaturenp.sort(a: ArrayLike, opts?: SortOptions | undefined): NDArray
| Return a sorted copy of an array. |
sort_complexfunction | np.sortComplex documentedsignaturenp.sortComplex(a: ArrayLike): NDArray
| Sort a complex array using the real part first, then the imaginary part. |
spacingufunc | np.spacing documentedsignaturenp.spacing(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Return the distance between x and the nearest adjacent number. |
splitfunction | np.split documentedsignaturenp.split(a: ArrayLike, indicesOrSections: number | NDArray | readonly number[], axis?: number | undefined): NDArray[]
| Split an array into multiple sub-arrays as views into ary. |
sqrtufunc | np.sqrt documentedsignaturenp.sqrt(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Return the non-negative square-root of an array, element-wise. |
squareufunc | np.square documentedsignaturenp.square(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Return the element-wise square of the input. |
squeezefunction | np.squeeze documentedsignaturenp.squeeze(a: NDArray, axis?: number | readonly number[] | undefined): NDArray
| Remove axes of length one from a. |
stackfunction | np.stack documentedsignaturenp.stack(arrays: Sequence, axis?: number | StackOptions | undefined, options?: JoinOptions | undefined): NDArray
| Join a sequence of arrays along a new axis. |
stdfunction | np.std documentedsignaturenp.std(a: ArrayLike, opts?: VarOptions | undefined): NDArray
| Compute the standard deviation along the specified axis. |
str_class | np.str_ documentedsignaturenp.str_: "str"
| A unicode string. |
subtractufunc | np.subtract documentedsignaturenp.subtract(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Subtract arguments, element-wise. |
sumfunction | np.sum documentedsignaturenp.sum(a: ArrayLike, opts?: ReduceOptions | undefined): NDArray
| Sum of array elements over a given axis. |
swapaxesfunction | np.swapAxes documentedsignaturenp.swapAxes(a: NDArray, axis1: number, axis2: number): NDArray
| Interchange two axes of an array. |
takefunction | np.take documentedsignaturenp.take(a: NDArray | NestedArray, indices: NDArray | NestedArray, axis?: number | TakeOptions | null | undefined, opts?: TakeOptions | undefined): NDArray
| Take elements from an array along an axis. |
take_along_axisfunction | np.takeAlongAxis documentedsignaturenp.takeAlongAxis(arr: ArrayLike, indices: ArrayLike, axis?: number | null | undefined): NDArray
| Take values from the input array by matching 1d index and data slices. |
tanufunc | np.tan documentedsignaturenp.tan(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Compute tangent element-wise. |
tanhufunc | np.tanh documentedsignaturenp.tanh(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Hyperbolic tangent, element-wise. |
tensordotfunction | np.tensordot documentedsignaturenp.tensordot(a: ArrayLike, b: ArrayLike, opts?: TensordotOptions | undefined): NDArray
| Compute tensor dot product along specified axes. |
tilefunction | np.tile documentedsignaturenp.tile(a: ArrayLike, reps: IntList): NDArray
| Construct an array by repeating A the number of times given by reps. |
timedelta64class | np.timedelta64 documentedsignaturenp.timedelta64(value: TimedeltaInput, unit?: string | undefined): TimedeltaArray
| A timedelta stored as a 64-bit integer. |
tracefunction | np.trace documentedsignaturenp.trace(a: ArrayLike, opts?: number | TraceOptions | undefined): NDArray
| Return the sum along diagonals of the array. |
transposefunction | np.transpose documentedsignaturenp.transpose(a: NDArray, axes?: readonly number[] | undefined): NDArray
| Returns an array with axes transposed. |
trapezoidfunction | np.trapezoid documentedsignaturenp.trapezoid(y: ArrayLike, opts?: TrapezoidOptions | undefined): NDArray
| Integrate along the given axis using the composite trapezoidal rule. |
trifunction | np.tri documentedsignaturenp.tri(n: number, m?: number | null | undefined, options?: TriOptions | undefined): NDArray
| An array with ones at and below the given diagonal and zeros elsewhere. |
trilfunction | np.tril documentedsignaturenp.tril(m: ArrayInput, k?: number | undefined): NDArray
| Lower triangle of an array. |
tril_indicesfunction | np.trilIndices documentedsignaturenp.trilIndices(n: number, k?: number | undefined, m?: number | null | undefined): NDArray[]
| Return the indices for the lower-triangle of an (n, m) array. |
tril_indices_fromfunction | np.trilIndicesFrom documentedsignaturenp.trilIndicesFrom(arr: NDArray, k?: number | undefined): NDArray[]
| Return the indices for the lower-triangle of arr. |
trim_zerosfunction | np.trimZeros documentedsignaturenp.trimZeros(filt: ArrayLike, trim?: string | undefined, axis?: number | readonly number[] | null | undefined): NDArray
| Remove values along a dimension which are zero along all other. |
triufunction | np.triu documentedsignaturenp.triu(m: ArrayInput, k?: number | undefined): NDArray
| Upper triangle of an array. |
triu_indicesfunction | np.triuIndices documentedsignaturenp.triuIndices(n: number, k?: number | undefined, m?: number | null | undefined): NDArray[]
| Return the indices for the upper-triangle of an (n, m) array. |
triu_indices_fromfunction | np.triuIndicesFrom documentedsignaturenp.triuIndicesFrom(arr: NDArray, k?: number | undefined): NDArray[]
| Return the indices for the upper-triangle of arr. |
True_constant | np.True_ documentedsignaturenp.True_: true
| bool(value=False, /) -- |
true_divideufunc | np.trueDivide documentedsignaturenp.trueDivide(a: Operand, b: Operand, opts?: UfuncOptions | undefined): NDArray
| Divide arguments element-wise. |
truncufunc | np.trunc documentedsignaturenp.trunc(a: ArrayLike, opts?: UfuncOptions | undefined): NDArray
| Return the truncated value of the input, element-wise. |
ubyteclass | np.ubyte documentedsignaturenp.ubyte: DType
| Unsigned integer type, compatible with C unsigned char. |
uintclass | np.uint documentedsignaturenp.uint: DType
| Unsigned signed integer type, 64bit on 64bit systems and 32bit on 32bit systems. |
uint16class | np.uint16 signaturenp.uint16: DType
| Unsigned integer type, compatible with C unsigned short. |
uint32class | np.uint32 signaturenp.uint32: DType
| Unsigned integer type, compatible with C unsigned int. |
uint64class | np.uint64 signaturenp.uint64: DType
| Unsigned signed integer type, 64bit on 64bit systems and 32bit on 32bit systems. |
uint8class | np.uint8 signaturenp.uint8: DType
| Unsigned integer type, compatible with C unsigned char. |
uintcclass | np.uintc documentedsignaturenp.uintc: DType
| Unsigned integer type, compatible with C unsigned int. |
uintpclass | np.uintp documentedsignaturenp.uintp: DType
| Unsigned signed integer type, 64bit on 64bit systems and 32bit on 32bit systems. |
ulongclass | np.ulong documentedsignaturenp.ulong: DType
| Unsigned signed integer type, 64bit on 64bit systems and 32bit on 32bit systems. |
union1dfunction | np.union1d documentedsignaturenp.union1d(a: ArrayLike, b: ArrayLike): NDArray
| Find the union of two arrays. |
uniquefunction | np.unique documentedsignaturenp.unique(a: ArrayLike, opts?: (UniqueOptions & { returnIndex?: false | undefined; returnInverse?: false | undefined; returnCounts?: false | undefined; }) | undefined): NDArray
np.unique(a: ArrayLike, opts: UniqueOptions): UniqueResult
| Find the unique elements of an array. |
unique_allfunction | np.uniqueAll documentedsignaturenp.uniqueAll(x: ArrayLike): UniqueAllResult
| Find the unique elements of an array, and counts, inverse, and indices. |
unique_countsfunction | np.uniqueCounts signaturenp.uniqueCounts(x: ArrayLike): UniqueCountsResult
| Find the unique elements and counts of an input array x. |
unique_inversefunction | np.uniqueInverse signaturenp.uniqueInverse(x: ArrayLike): UniqueInverseResult
| Find the unique elements of x and indices to reconstruct x. |
unique_valuesfunction | np.uniqueValues signaturenp.uniqueValues(x: ArrayLike): NDArray
| Returns the unique elements of an input array x. |
unpackbitsfunction | np.unpackbits documentedsignaturenp.unpackbits(a: ArrayLike, opts?: UnpackbitsOptions | undefined): NDArray
| Unpacks elements of a uint8 array into a binary-valued output array. |
unravel_indexfunction | np.unravelIndex documentedsignaturenp.unravelIndex(indices: ArrayLike, shape: number | Shape, opts?: { order?: MemoryOrder | undefined; } | undefined): NDArray[]
| Converts a flat index or array of flat indices into a tuple of coordinate arrays. |
unstackfunction | np.unstack documentedsignaturenp.unstack(x: ArrayLike, axis?: number | { axis?: number | undefined; } | undefined): NDArray[]
| Split an array into a sequence of arrays along the given axis. |
unwrapfunction | np.unwrap documentedsignaturenp.unwrap(p: ArrayLike, opts?: UnwrapOptions | undefined): NDArray
| Unwrap by taking the complement of large deltas with respect to the period. |
ushortclass | np.ushort documentedsignaturenp.ushort: DType
| Unsigned integer type, compatible with C unsigned short. |
vanderfunction | np.vander documentedsignaturenp.vander(x: ArrayInput, n?: number | null | undefined, options?: { increasing?: boolean | undefined; } | undefined): NDArray
| Generate a Vandermonde matrix. |
varfunction | np.var documentedsignaturenp.var(a: ArrayLike, opts?: VarOptions | undefined): NDArray
| Compute the variance along the specified axis. |
vdotfunction | np.vdot documentedsignaturenp.vdot(a: ArrayLike, b: ArrayLike): NDArray
| Return the dot product of two vectors. |
vecdotufunc | np.vecdot documentedsignaturenp.vecdot(x1: ArrayLike, x2: ArrayLike, opts?: VecdotOptions | undefined): NDArray
| Vector dot product of two arrays. |
vecmatufunc | np.vecmat documentedsignaturenp.vecmat(x1: ArrayLike, x2: ArrayLike): NDArray
| Vector-matrix dot product of two arrays. |
vectorizeclass | np.vectorize documentedsignaturenp.vectorize(fn: (...args: unknown[]) => unknown, opts?: VectorizeOptions | undefined): VectorizedFn
| Returns an object that acts like pyfunc, but takes arrays as input. |
vsplitfunction | np.vsplit signaturenp.vsplit(a: ArrayLike, indicesOrSections: number | NDArray | readonly number[]): NDArray[]
| Split an array into multiple sub-arrays vertically (row-wise). |
vstackfunction | np.vstack documentedsignaturenp.vstack(arrays: Sequence, options?: VHStackOptions | undefined): NDArray
| Stack arrays in sequence vertically (row wise). |
wherefunction | np.where documentedsignaturenp.where(condition: NDArray | NestedArray): NDArray[]
np.where(condition: NDArray | NestedArray, x: NDArray | NestedArray, y: NDArray | NestedArray): NDArray
| Return elements chosen from x or y depending on condition. |
zerosfunction | np.zeros documentedsignaturenp.zeros(shape: number | Shape, options?: CreationOptions | undefined): NDArray
| Return a new array of given shape and type, filled with zeros. |
zeros_likefunction | np.zerosLike documentedsignaturenp.zerosLike(a: NDArray, options?: LikeOptions | undefined): NDArray
| Return an array of zeros with the same shape and type as a given array. |