summaryrefslogtreecommitdiff
path: root/numpy/core
diff options
context:
space:
mode:
Diffstat (limited to 'numpy/core')
-rw-r--r--numpy/core/_add_newdocs.py3
-rw-r--r--numpy/core/_internal.py8
2 files changed, 7 insertions, 4 deletions
diff --git a/numpy/core/_add_newdocs.py b/numpy/core/_add_newdocs.py
index 538123149..b8f0ee907 100644
--- a/numpy/core/_add_newdocs.py
+++ b/numpy/core/_add_newdocs.py
@@ -5315,7 +5315,7 @@ add_newdoc('numpy.core', 'ufunc', ('outer',
r = empty(len(A),len(B))
for i in range(len(A)):
for j in range(len(B)):
- r[i,j] = op(A[i], B[j]) # op = ufunc in question
+ r[i,j] = op(A[i], B[j]) # op = ufunc in question
Parameters
----------
@@ -5325,6 +5325,7 @@ add_newdoc('numpy.core', 'ufunc', ('outer',
Second array
kwargs : any
Arguments to pass on to the ufunc. Typically `dtype` or `out`.
+ See `ufunc` for a comprehensive overview of all available arguments.
Returns
-------
diff --git a/numpy/core/_internal.py b/numpy/core/_internal.py
index 4eebbaea3..3b0c46467 100644
--- a/numpy/core/_internal.py
+++ b/numpy/core/_internal.py
@@ -843,11 +843,13 @@ def _ufunc_doc_signature_formatter(ufunc):
", order='K'"
", dtype=None"
", subok=True"
- "[, signature"
- ", extobj]"
)
+
+ # NOTE: gufuncs may or may not support the `axis` parameter
if ufunc.signature is None:
- kwargs = ", where=True" + kwargs
+ kwargs = f", where=True{kwargs}[, signature, extobj]"
+ else:
+ kwargs += "[, signature, extobj, axes, axis]"
# join all the parts together
return '{name}({in_args}{out_args}, *{kwargs})'.format(