标签:target poi .com ... alt 参数 start mat 点点滴滴
Color | Color Name |
b | blue |
c | cyan |
g | green |
k | black |
m | magenta |
r | red |
w | white |
y | yellow |
Style | Style |
- | solid line |
-- | dashed line |
-. | dash-dot line |
: | dotted line |
. | Point marker |
, | Pixel marker |
o | Circle marker |
v | Triangle down |
^ | Triangle up marker |
< | Triangle left marker |
> | Triangle right marker |
1 | Tripod down marker |
2 | Tripod up marker |
3 | Tripod left marker |
4 | Tripod right marker |
s | Square marker |
p | Pentagon marker |
* | Star marker |
h | Hexagon marker |
H | Rotated hexagon marker |
+ | Plus marker |
x | Cross marker |
D | Diamond marker |
d | Thin diamond marker |
| | Vertical line |
_ | Horizontal line |
import matplotlib.pyplot as plt import numpy as np y = np.arange(1, 3) plt.plot(y, ‘y‘) plt.plot(y+1, ‘m‘) plt.plot(y+2, ‘c‘) plt.show() import matplotlib.pyplot as plt import numpy as np y = np.arange(1, 3) plt.plot(y, ‘--‘, y+1, ‘-.‘, y+2, ‘:‘) plt.show() import matplotlib.pyplot as plt import numpy as np y = np.arange(1, 3, 0.2) plt.plot(y, ‘x‘, y+0.5, ‘o‘, y+1, ‘D‘, y+1.5, ‘^‘, y+2, ‘s‘) plt.show() import matplotlib.pyplot as plt import numpy as np y = np.arange(1, 3, 0.3) plt.plot(y, ‘cx--‘, y+1, ‘mo:‘, y+2, ‘kp-.‘) plt.show() import matplotlib.pyplot as plt import numpy as np y = np.arange(1, 3, 0.3) plt.plot(y, color=‘blue‘, linestyle=‘dashdot‘, linewidth=4, marker=‘o‘, markerfacecolor=‘red‘, markeredgecolor=‘black‘, markeredgewidth=3, markersize=12) plt.show() import matplotlib.pyplot as plt x = [5, 3, 7, 2, 4, 1] plt.plot(x) plt.xticks(range(len(x)), [‘a‘, ‘b‘, ‘c‘, ‘d‘, ‘e‘, ‘f‘]) plt.yticks(range(1, 8, 2)) plt.show() import matplotlib.pyplot as plt import numpy as np y = np.random.randn(1000) plt.hist(y) plt.show() plt.hist(y, 25) plt.show() import matplotlib.pyplot as plt import numpy as np x = np.arange(0, 4, 0.2) y = np.exp(-x) e1 = 0.1 * np.abs(np.random.randn(len(y))) plt.errorbar(x, y, yerr=e1, fmt=‘.-‘) plt.show() e2 = 0.1 * np.abs(np.random.randn(len(y))) plt.errorbar(x, y, yerr=e1, xerr=e2, fmt=‘.-‘, capsize=0) plt.show() plt.errorbar(x, y, yerr=[e1, e2], fmt=‘.-‘) plt.show() import matplotlib.pyplot as plt plt.bar([1, 2, 3], [3, 2, 5]) plt.show() import matplotlib.pyplot as plt import numpy as np data1 = 10*np.random.rand(5) data2 = 10*np.random.rand(5) data3 = 10*np.random.rand(5) e2 = 0.5*np.abs(np.random.randn(len(data2))) locs = np.arange(1, len(data1)+1) width = 0.27 plt.bar(locs+width, data2, yerr=e2, width=width, color=‘red‘) plt.bar(locs+2*width, data3, width=width, color=‘green‘) plt.show()
知识在于点点滴滴的积累,我会在这个路上Go ahead,
适度锻炼,量化指标
考量天气,设定目标
科学锻炼,成就体标
高效科研,实现学标
标签:target poi .com ... alt 参数 start mat 点点滴滴
原文地址:https://www.cnblogs.com/brightyuxl/p/9253623.html