Skip to content

Commit fafc9aa

Browse files
added a title to example 1
1 parent a98d04f commit fafc9aa

File tree

1 file changed

+5
-1
lines changed
  • content/matplotlib/concepts/pyplot/terms/ylim

1 file changed

+5
-1
lines changed

content/matplotlib/concepts/pyplot/terms/ylim/ylim.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,17 +28,21 @@ Or to get current limits:
2828
bottom, top = pyplot.ylim()
2929
```
3030

31+
**Parameters:**
32+
3133
The `ylim()` function accepts the following parameters:
3234

3335
- `bottom` (optional): A float representing the lower y-axis limit. If not provided, the current lower limit is returned.
3436
- `top` (optional): A float representing the upper y-axis limit. If not provided, the current upper limit is returned.
3537

38+
**Return value:**
39+
3640
The function returns:
3741

3842
- A tuple `(bottom, top)` containing the current y-axis limits if no arguments are provided.
3943
- The new y-axis limits as a tuple if arguments are provided.
4044

41-
## Example
45+
## Example 1: Setting Y-Axis Limits
4246

4347
The following example demonstrates how to use `ylim()` to set y-axis limits:
4448

0 commit comments

Comments
 (0)