Connected scatterplots are just a mix between scatterplots and linecharts. It can be made using the plot()
function of matplotlib with the possible parameters:
x
: The horizontal coordinates of the data pointsy
: The vertical coordinates of the data pointsdata
: An object with labelled datalinestyle
: Line style can be one of these {'-', '--', '-.', ':', '', (offset, on-off-seq), ...}marker
: Marker style
If you want to customize them, just check the scatter and line sections of the website!
# libraries
import matplotlib.pyplot as plt
import numpy as np
import pandas as pd
import seaborn as sns
# data
df=pd.DataFrame({'x_axis': range(1,10), 'y_axis': np.random.randn(9)*80+range(1,10) })
# plot
plt.plot( 'x_axis', 'y_axis', data=df, linestyle='-', marker='o')
plt.show()