Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 787e4d2

Browse files
authored
DOC Add interval notation for include_boundaries in documentation check_scalar (#21955)
1 parent fb34236 commit 787e4d2

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

sklearn/utils/validation.py

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1385,11 +1385,14 @@ def check_scalar(
13851385
Whether the interval defined by `min_val` and `max_val` should include
13861386
the boundaries. Possible choices are:
13871387
1388-
- `"left"`: only `min_val` is included in the valid interval;
1389-
- `"right"`: only `max_val` is included in the valid interval;
1390-
- `"both"`: `min_val` and `max_val` are included in the valid interval;
1388+
- `"left"`: only `min_val` is included in the valid interval.
1389+
It is equivalent to the interval `[ min_val, max_val )`.
1390+
- `"right"`: only `max_val` is included in the valid interval.
1391+
It is equivalent to the interval `( min_val, max_val ]`.
1392+
- `"both"`: `min_val` and `max_val` are included in the valid interval.
1393+
It is equivalent to the interval `[ min_val, max_val ]`.
13911394
- `"neither"`: neither `min_val` nor `max_val` are included in the
1392-
valid interval.
1395+
valid interval. It is equivalent to the interval `( min_val, max_val )`.
13931396
13941397
Returns
13951398
-------

0 commit comments

Comments
 (0)