From 06643f294ad4e9cc43e43ba4e5a9480e64f906aa Mon Sep 17 00:00:00 2001 From: David Rotermund <54365609+davrot@users.noreply.github.com> Date: Sat, 30 Dec 2023 17:30:13 +0100 Subject: [PATCH] Update README.md Signed-off-by: David Rotermund <54365609+davrot@users.noreply.github.com> --- numpy/merging/README.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/numpy/merging/README.md b/numpy/merging/README.md index 34998c4..a026485 100644 --- a/numpy/merging/README.md +++ b/numpy/merging/README.md @@ -30,6 +30,14 @@ numpy.choose(a, choices, out=None, mode='raise') > * if mode='wrap', values in a (and thus Ba) may be any (signed) integer; modular arithmetic is used to map integers outside the range [0, n-1] back into that range; and then the new array is constructed as above; > * if mode='clip', values in a (and thus Ba) may be any (signed) integer; negative integers are mapped to 0; values greater than n-1 are mapped to n-1; and then the new array is constructed as above. +### Example: + +||| +|---|---| +|chosen_mask == 0| use a| +|chosen_mask == 1| use b| +|chosen_mask == 2| use c| + ```python import numpy as np