forked from plotly/plotly.py
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathlines.py
More file actions
90 lines (88 loc) · 3.36 KB
/
lines.py
File metadata and controls
90 lines (88 loc) · 3.36 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
D = dict(
x1=[0, 1, 2, 3, 4, 5],
y1=[10, 20, 50, 80, 100, 200],
x2=[0, 1, 2, 3, 4, 5, 6],
y2=[1, 4, 8, 16, 32, 64, 128]
)
SIMPLE_LINE = {
'data': [{'line': {'color': '#0000FF',
'dash': 'solid',
'opacity': 1,
'width': 1.0},
'type': 'scatter',
'mode': 'lines',
'name': 'simple',
'x': [0.0, 1.0, 2.0, 3.0, 4.0, 5.0],
'y': [10.0, 20.0, 50.0, 80.0, 100.0, 200.0]}],
'layout': {
'autosize': False,
'height': 480,
'margin': {'b': 47, 'l': 80, 'pad': 0, 'r': 63, 't': 47},
'showlegend': False,
'hovermode': 'closest',
'width': 640,
'xaxis': {'anchor': 'y',
'zeroline': False,
'domain': [0.0, 1.0],
'range': (0.0, 5.0),
'showgrid': False},
'yaxis': {'anchor': 'x',
'zeroline': False,
'domain': [0.0, 1.0],
'range': (0.0, 200.0),
'showgrid': False}}}
COMPLICATED_LINE = {
'data': [{'marker': {'color': '#FF0000',
'line': {'color': '#000000', 'width': 0.5},
'opacity': 0.5,
'size': 10,
'symbol': 'dot'},
'type': 'scatter',
'mode': 'markers',
'name': 'one',
'x': [0.0, 1.0, 2.0, 3.0, 4.0, 5.0],
'y': [10.0, 20.0, 50.0, 80.0, 100.0, 200.0]},
{'line': {'color': '#0000FF',
'dash': 'solid',
'opacity': 0.7,
'width': 2},
'type': 'scatter',
'mode': 'lines',
'name': 'two',
'x': [0.0, 1.0, 2.0, 3.0, 4.0, 5.0],
'y': [10.0, 20.0, 50.0, 80.0, 100.0, 200.0]},
{'marker': {'color': '#0000FF',
'line': {'color': '#0000FF', 'width': 2},
'opacity': 0.6,
'size': 10,
'symbol': 'cross'},
'type': 'scatter',
'mode': 'markers',
'name': 'three',
'x': [0.0, 1.0, 2.0, 3.0, 4.0, 5.0, 6.0],
'y': [1.0, 4.0, 8.0, 16.0, 32.0, 64.0, 128.0]},
{'line': {'color': '#FF0000',
'dash': 'dash',
'opacity': 0.8,
'width': 2},
'type': 'scatter',
'mode': 'lines',
'name': 'four',
'x': [0.0, 1.0, 2.0, 3.0, 4.0, 5.0, 6.0],
'y': [1.0, 4.0, 8.0, 16.0, 32.0, 64.0, 128.0]}],
'layout': {'autosize': False,
'height': 480,
'margin': {'b': 47, 'l': 80, 'pad': 0, 'r': 63, 't': 47},
'showlegend': False,
'hovermode': 'closest',
'width': 640,
'xaxis': {'anchor': 'y',
'zeroline': False,
'domain': [0.0, 1.0],
'range': (0.0, 6.0),
'showgrid': False},
'yaxis': {'anchor': 'x',
'zeroline': False,
'domain': [0.0, 1.0],
'range': (0.0, 200.0),
'showgrid': False}}}