Sign in
apache
/
spark-website
/
28656f2c00baf1bc2d26570a16b4f96f9a890723
/
.
/
site
/
docs
/
3.2.2
/
api
/
python
/
reference
/
pyspark.pandas
/
api
/
pyspark-pandas-Series-plot-line-3.py
blob: 60f87163365accd0d0da4e4c2da7d6aa29e1114e [
file
] [
log
] [
blame
]
# The following example shows the relationship between both
# populations.
df
=
ps
.
DataFrame
({
'pig'
:
[
20
,
18
,
489
,
675
,
1776
],
'horse'
:
[
4
,
25
,
281
,
600
,
1900
]},
index
=[
1990
,
1997
,
2003
,
2009
,
2014
])
df
.
plot
.
line
(
x
=
'pig'
,
y
=
'horse'
)
# doctest: +SKIP