DOC: added examples to DataFrame.var #44162
- [x] closes #44162 by adding two examples to docstring of DataFrame.var
- [x] tests added / passed
- [x] All linting tests passed (pre-commit)

Screenshot of locally built documentation:

![var](https://user-images.githubusercontent.com/58558211/139727701-f6c92ad1-948d-42bd-8989-2d874e3cfa58.PNG)



Thanks @MarcoGorelli for the motivation via cat images.
Apologies for the old commits. Next time I'll create a new branch from scratch. It seems like there is a check that keeps failing `CI > Checks (pull_request) > Typing validation`. I do not understand the error report so I'm not sure what is going wrong. Please see the details of the error report below and advise:

```console
Run ci/code_checks.sh typing
mypy --version
mypy 0.910
Performing static analysis using mypy
pandas/core/frame.py:997: error: Incompatible return value type (got "Optional[str]", expected "str")  [return-value]
Found 1 error in 1 file (checked 1318 source files)
Performing static analysis using mypy DONE
Performing static analysis using pyright
No configuration file found.
pyproject.toml file found at /home/runner/work/pandas/pandas.
Loading pyproject.toml file at /home/runner/work/pandas/pandas/pyproject.toml
Assuming Python platform Linux
Searching for source files
Found 311 source files
0 errors, 0 warnings, 0 infos 
Completed in 48.921sec
Performing static analysis using pyright DONE
Error: Process completed with exit code 1.
``` > It seems like there is a check that keeps failing `CI > Checks (pull_request) > Typing validation`. I do not understand the error report so I'm not sure what is going wrong. Please see the details of the error report below and advise:
> 
> ```
> Run ci/code_checks.sh typing
> mypy --version
> mypy 0.910
> Performing static analysis using mypy
> pandas/core/frame.py:997: error: Incompatible return value type (got "Optional[str]", expected "str")  [return-value]
> Found 1 error in 1 file (checked 1318 source files)
> Performing static analysis using mypy DONE
> Performing static analysis using pyright
> No configuration file found.
> pyproject.toml file found at /home/runner/work/pandas/pandas.
> Loading pyproject.toml file at /home/runner/work/pandas/pandas/pyproject.toml
> Assuming Python platform Linux
> Searching for source files
> Found 311 source files
> 0 errors, 0 warnings, 0 infos 
> Completed in 48.921sec
> Performing static analysis using pyright DONE
> Error: Process completed with exit code 1.
> ```

It's unrelated, and fixed on master, don't worry about it > It's unrelated, and fixed on master, don't worry about it

Ok great. Is there anything else I can do regarding this PR before it can be merged? Looks good to me, I'll just leave it open a bit in case others have comments Good idea, thanks @MarcoGorelli  Thanks, @mroeschke 
Just made the changes you recommended. Thanks @ruankie 