This question already has an answer here:
- Plotting line with different colors 2 answers
Let's say I have a Series like this:
testdf = pd.Series([3, 4, 2, 5, 1, 6, 10])
When plotting, this is the result:
testdf.plot()
I want to plot, say, the line up to the first 4 values in blue (default) and the rest of the line in red. How can I do it?
IIUC