Color in python
Choosing color in matplotlib
Choosing color in seaborn
seaborn中可选择的颜色更多,可在color参数中选择seaborn的颜色,例如:
- plt.plot(x, y, color=seaborn.xkcd_rgb['rose pink'])
Chooing color palettes in seaborn
可以直接使用seaborn中的调色盘,例如:
- plt.plot(x, y, color=seaborn.set_palette('Spectral')
- plt.plot(x, y, color=seaborn.set_palette('viridis')
seaborn具体的palettes 见官方文档: