[DOC]: Documentation updated for codes
- [X] closes #56278(Replace xxxx with the GitHub issue number)
- [ ] [Tests added and passed](https://pandas.pydata.org/pandas-docs/dev/development/contributing_codebase.html#writing-tests) if fixing a bug or adding a new feature


Thanks but since this is very similar to https://github.com/pandas-dev/pandas/pull/56278 I suggest combining your changes in that PR so closing this one