78
78
@array_function_from_c_func_and_dispatcher (_multiarray_umath .empty_like )
79
79
def empty_like (prototype , dtype = None , order = None , subok = None , shape = None ):
80
80
"""
81
- empty_like(prototype, dtype=None, order='K', subok=True, shape=None)
82
-
83
81
Return a new array with the same shape and type as a given array.
84
82
85
83
Parameters
@@ -146,8 +144,6 @@ def empty_like(prototype, dtype=None, order=None, subok=None, shape=None):
146
144
@array_function_from_c_func_and_dispatcher (_multiarray_umath .concatenate )
147
145
def concatenate (arrays , axis = None , out = None , * , dtype = None , casting = None ):
148
146
"""
149
- concatenate((a1, a2, ...), axis=0, out=None, dtype=None, casting="same_kind")
150
-
151
147
Join a sequence of arrays along an existing axis.
152
148
153
149
Parameters
@@ -247,8 +243,6 @@ def concatenate(arrays, axis=None, out=None, *, dtype=None, casting=None):
247
243
@array_function_from_c_func_and_dispatcher (_multiarray_umath .inner )
248
244
def inner (a , b ):
249
245
"""
250
- inner(a, b, /)
251
-
252
246
Inner product of two arrays.
253
247
254
248
Ordinary inner product of vectors for 1-D arrays (without complex
@@ -339,8 +333,6 @@ def inner(a, b):
339
333
@array_function_from_c_func_and_dispatcher (_multiarray_umath .where )
340
334
def where (condition , x = None , y = None ):
341
335
"""
342
- where(condition, [x, y], /)
343
-
344
336
Return elements chosen from `x` or `y` depending on `condition`.
345
337
346
338
.. note::
@@ -414,8 +406,6 @@ def where(condition, x=None, y=None):
414
406
@array_function_from_c_func_and_dispatcher (_multiarray_umath .lexsort )
415
407
def lexsort (keys , axis = None ):
416
408
"""
417
- lexsort(keys, axis=-1)
418
-
419
409
Perform an indirect stable sort using a sequence of keys.
420
410
421
411
Given multiple sorting keys, which can be interpreted as columns in a
@@ -496,8 +486,6 @@ def lexsort(keys, axis=None):
496
486
@array_function_from_c_func_and_dispatcher (_multiarray_umath .can_cast )
497
487
def can_cast (from_ , to , casting = None ):
498
488
"""
499
- can_cast(from_, to, casting='safe')
500
-
501
489
Returns True if cast between data types can occur according to the
502
490
casting rule. If from is a scalar or array scalar, also returns
503
491
True if the scalar value can be cast without overflow or truncation
@@ -611,8 +599,6 @@ def can_cast(from_, to, casting=None):
611
599
@array_function_from_c_func_and_dispatcher (_multiarray_umath .min_scalar_type )
612
600
def min_scalar_type (a ):
613
601
"""
614
- min_scalar_type(a, /)
615
-
616
602
For scalar ``a``, returns the data type with the smallest size
617
603
and smallest scalar kind which can hold its value. For non-scalar
618
604
array ``a``, returns the vector's dtype unmodified.
@@ -662,8 +648,6 @@ def min_scalar_type(a):
662
648
@array_function_from_c_func_and_dispatcher (_multiarray_umath .result_type )
663
649
def result_type (* arrays_and_dtypes ):
664
650
"""
665
- result_type(*arrays_and_dtypes)
666
-
667
651
Returns the type that results from applying the NumPy
668
652
type promotion rules to the arguments.
669
653
@@ -734,8 +718,6 @@ def result_type(*arrays_and_dtypes):
734
718
@array_function_from_c_func_and_dispatcher (_multiarray_umath .dot )
735
719
def dot (a , b , out = None ):
736
720
"""
737
- dot(a, b, out=None)
738
-
739
721
Dot product of two arrays. Specifically,
740
722
741
723
- If both `a` and `b` are 1-D arrays, it is inner product of vectors
@@ -823,8 +805,6 @@ def dot(a, b, out=None):
823
805
@array_function_from_c_func_and_dispatcher (_multiarray_umath .vdot )
824
806
def vdot (a , b ):
825
807
"""
826
- vdot(a, b, /)
827
-
828
808
Return the dot product of two vectors.
829
809
830
810
The vdot(`a`, `b`) function handles complex numbers differently than
@@ -881,8 +861,6 @@ def vdot(a, b):
881
861
@array_function_from_c_func_and_dispatcher (_multiarray_umath .bincount )
882
862
def bincount (x , weights = None , minlength = None ):
883
863
"""
884
- bincount(x, /, weights=None, minlength=0)
885
-
886
864
Count number of occurrences of each value in array of non-negative ints.
887
865
888
866
The number of bins (of size 1) is one larger than the largest value in
@@ -958,8 +936,6 @@ def bincount(x, weights=None, minlength=None):
958
936
@array_function_from_c_func_and_dispatcher (_multiarray_umath .ravel_multi_index )
959
937
def ravel_multi_index (multi_index , dims , mode = None , order = None ):
960
938
"""
961
- ravel_multi_index(multi_index, dims, mode='raise', order='C')
962
-
963
939
Converts a tuple of index arrays into an array of flat
964
940
indices, applying boundary modes to the multi-index.
965
941
@@ -1019,8 +995,6 @@ def ravel_multi_index(multi_index, dims, mode=None, order=None):
1019
995
@array_function_from_c_func_and_dispatcher (_multiarray_umath .unravel_index )
1020
996
def unravel_index (indices , shape = None , order = None ):
1021
997
"""
1022
- unravel_index(indices, shape, order='C')
1023
-
1024
998
Converts a flat index or array of flat indices into a tuple
1025
999
of coordinate arrays.
1026
1000
@@ -1069,8 +1043,6 @@ def unravel_index(indices, shape=None, order=None):
1069
1043
@array_function_from_c_func_and_dispatcher (_multiarray_umath .copyto )
1070
1044
def copyto (dst , src , casting = None , where = None ):
1071
1045
"""
1072
- copyto(dst, src, casting='same_kind', where=True)
1073
-
1074
1046
Copies values from one array to another, broadcasting as necessary.
1075
1047
1076
1048
Raises a TypeError if the `casting` rule is violated, and if
@@ -1104,8 +1076,6 @@ def copyto(dst, src, casting=None, where=None):
1104
1076
@array_function_from_c_func_and_dispatcher (_multiarray_umath .putmask )
1105
1077
def putmask (a , mask , values ):
1106
1078
"""
1107
- putmask(a, mask, values)
1108
-
1109
1079
Changes elements of an array based on conditional and input values.
1110
1080
1111
1081
Sets ``a.flat[n] = values[n]`` for each n where ``mask.flat[n]==True``.
@@ -1149,8 +1119,6 @@ def putmask(a, mask, values):
1149
1119
@array_function_from_c_func_and_dispatcher (_multiarray_umath .packbits )
1150
1120
def packbits (a , axis = None , bitorder = 'big' ):
1151
1121
"""
1152
- packbits(a, /, axis=None, bitorder='big')
1153
-
1154
1122
Packs the elements of a binary-valued array into bits in a uint8 array.
1155
1123
1156
1124
The result is padded to full bytes by inserting zero bits at the end.
@@ -1207,8 +1175,6 @@ def packbits(a, axis=None, bitorder='big'):
1207
1175
@array_function_from_c_func_and_dispatcher (_multiarray_umath .unpackbits )
1208
1176
def unpackbits (a , axis = None , count = None , bitorder = 'big' ):
1209
1177
"""
1210
- unpackbits(a, /, axis=None, count=None, bitorder='big')
1211
-
1212
1178
Unpacks elements of a uint8 array into a binary-valued output array.
1213
1179
1214
1180
Each element of `a` represents a bit-field that should be unpacked
@@ -1291,8 +1257,6 @@ def unpackbits(a, axis=None, count=None, bitorder='big'):
1291
1257
@array_function_from_c_func_and_dispatcher (_multiarray_umath .shares_memory )
1292
1258
def shares_memory (a , b , max_work = None ):
1293
1259
"""
1294
- shares_memory(a, b, /, max_work=None)
1295
-
1296
1260
Determine if two arrays share memory.
1297
1261
1298
1262
.. warning::
@@ -1366,8 +1330,6 @@ def shares_memory(a, b, max_work=None):
1366
1330
@array_function_from_c_func_and_dispatcher (_multiarray_umath .may_share_memory )
1367
1331
def may_share_memory (a , b , max_work = None ):
1368
1332
"""
1369
- may_share_memory(a, b, /, max_work=None)
1370
-
1371
1333
Determine if two arrays might share memory
1372
1334
1373
1335
A return of True does not necessarily mean that the two arrays
@@ -1407,8 +1369,6 @@ def may_share_memory(a, b, max_work=None):
1407
1369
@array_function_from_c_func_and_dispatcher (_multiarray_umath .is_busday )
1408
1370
def is_busday (dates , weekmask = None , holidays = None , busdaycal = None , out = None ):
1409
1371
"""
1410
- is_busday(dates, weekmask='1111100', holidays=None, busdaycal=None, out=None)
1411
-
1412
1372
Calculates which of the given dates are valid days, and which are not.
1413
1373
1414
1374
.. versionadded:: 1.7.0
@@ -1462,8 +1422,6 @@ def is_busday(dates, weekmask=None, holidays=None, busdaycal=None, out=None):
1462
1422
def busday_offset (dates , offsets , roll = None , weekmask = None , holidays = None ,
1463
1423
busdaycal = None , out = None ):
1464
1424
"""
1465
- busday_offset(dates, offsets, roll='raise', weekmask='1111100', holidays=None, busdaycal=None, out=None)
1466
-
1467
1425
First adjusts the date to fall on a valid day according to
1468
1426
the ``roll`` rule, then applies offsets to the given dates
1469
1427
counted in valid days.
@@ -1556,8 +1514,6 @@ def busday_offset(dates, offsets, roll=None, weekmask=None, holidays=None,
1556
1514
def busday_count (begindates , enddates , weekmask = None , holidays = None ,
1557
1515
busdaycal = None , out = None ):
1558
1516
"""
1559
- busday_count(begindates, enddates, weekmask='1111100', holidays=[], busdaycal=None, out=None)
1560
-
1561
1517
Counts the number of valid days between `begindates` and
1562
1518
`enddates`, not including the day of `enddates`.
1563
1519
@@ -1624,8 +1580,6 @@ def busday_count(begindates, enddates, weekmask=None, holidays=None,
1624
1580
_multiarray_umath .datetime_as_string )
1625
1581
def datetime_as_string (arr , unit = None , timezone = None , casting = None ):
1626
1582
"""
1627
- datetime_as_string(arr, unit=None, timezone='naive', casting='same_kind')
1628
-
1629
1583
Convert an array of datetimes into an array of strings.
1630
1584
1631
1585
Parameters
0 commit comments