Skip to content

Commit cd17bdd

Browse files
committed
Site updated at 2019-04-26 16:22:14 UTC
1 parent 8767635 commit cd17bdd

File tree

59 files changed

+4529
-3322
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

59 files changed

+4529
-3322
lines changed

2015/04/09/basic-bar.html

Lines changed: 59 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,60 @@
1+
var gd = document.getElementById('graphDiv');
12
var data = [
2-
{
3-
x: ['giraffes', 'orangutans', 'monkeys'],
4-
y: [20, 14, 23],
5-
type: 'bar'
6-
}
7-
];
8-
9-
Plotly.newPlot('myDiv', data);
3+
{
4+
name: "2018",
5+
type: "waterfall",
6+
orientation: "v",
7+
measure: [
8+
"relative",
9+
"relative",
10+
"total",
11+
"relative",
12+
"relative",
13+
"total"
14+
],
15+
x: [
16+
"Sales",
17+
"Consulting",
18+
"Net revenue",
19+
"Purchases",
20+
"Other expenses",
21+
"Profit before tax"
22+
],
23+
textposition: "outside",
24+
text: [
25+
"+60",
26+
"+80",
27+
"",
28+
"-40",
29+
"-20",
30+
"Total"
31+
],
32+
y: [
33+
60,
34+
80,
35+
0,
36+
-40,
37+
-20,
38+
0
39+
],
40+
connector: {
41+
line: {
42+
color: "rgb(63, 63, 63)"
43+
}
44+
},
45+
}
46+
];
47+
layout = {
48+
title: {
49+
text: "Profit and loss statement 2018"
50+
},
51+
xaxis: {
52+
type: "category"
53+
},
54+
yaxis: {
55+
type: "linear"
56+
},
57+
autosize: true,
58+
showlegend: true
59+
};
60+
Plotly.newPlot(gd, data, layout);
Lines changed: 84 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,84 @@
1+
var gd = document.getElementById('graphDiv');
2+
var data = [
3+
{
4+
name: "2018",
5+
type: "waterfall",
6+
orientation: "h",
7+
measure: [
8+
"relative",
9+
"relative",
10+
"relative",
11+
"relative",
12+
"total",
13+
"relative",
14+
"relative",
15+
"relative",
16+
"relative",
17+
"total",
18+
"relative",
19+
"relative",
20+
"total",
21+
"relative",
22+
"total"
23+
],
24+
y: [
25+
"Sales",
26+
"Consulting",
27+
"Maintenance",
28+
"Other revenue",
29+
"Net revenue",
30+
"Purchases",
31+
"Material expenses",
32+
"Personnel expenses",
33+
"Other expenses",
34+
"Operating profit",
35+
"Investment income",
36+
"Financial income",
37+
"Profit before tax",
38+
"Income tax (15%)",
39+
"Profit after tax"
40+
],
41+
x: [
42+
375,
43+
128,
44+
78,
45+
27,
46+
null,
47+
-327,
48+
-12,
49+
-78,
50+
-12,
51+
null,
52+
32,
53+
89,
54+
null,
55+
-45,
56+
null
57+
],
58+
connector: {
59+
mode: "between",
60+
line: {
61+
width: 4,
62+
color: "rgb(0, 0, 0)",
63+
dash: 0
64+
}
65+
}
66+
}
67+
];
68+
var layout = {title: {
69+
text: "Profit and loss statement 2018<br>waterfall chart displaying positive and negative"
70+
},
71+
yaxis: {
72+
type: "category",
73+
autorange: "reversed"
74+
},
75+
xaxis: {
76+
type: "linear"
77+
},
78+
margin: { l: 150 },
79+
showlegend: true
80+
}
81+
Plotly.newPlot(gd, data, layout);
82+
83+
84+
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
var gd = document.getElementById('graphDiv');
2+
var data = [
3+
{
4+
type: "waterfall",
5+
x: [
6+
["2016", "2017", "2017", "2017", "2017", "2018", "2018", "2018", "2018"],
7+
["initial", "q1", "q2", "q3", "total", "q1", "q2", "q3", "total" ]
8+
],
9+
measure: ["absolute", "relative", "relative", "relative", "total", "relative", "relative", "relative", "total"],
10+
y: [1, 2, 3, -1, null, 1, 2, -4, null],
11+
base: 1000
12+
},
13+
{
14+
type: "waterfall",
15+
x: [
16+
["2016", "2017", "2017", "2017", "2017", "2018", "2018", "2018", "2018"],
17+
["initial", "q1", "q2", "q3", "total", "q1", "q2", "q3", "total" ]
18+
],
19+
measure: ["absolute", "relative", "relative", "relative", "total", "relative", "relative", "relative", "total"],
20+
y: [1.1, 2.2, 3.3, -1.1, null, 1.1, 2.2, -4.4, null],
21+
base: 1000
22+
}
23+
];
24+
var layout = {
25+
waterfallgroupgap : 0.5,
26+
xaxis: {
27+
title: "MULTI-CATEGORY",
28+
tickfont: {size: 16},
29+
ticks: "outside"
30+
}
31+
}
32+
Plotly.newPlot(gd, data, layout);

2015/04/09/style-waterfall.html

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
var gd = document.getElementById('graphDiv');
2+
var data = [
3+
{
4+
type: "waterfall",
5+
x: [
6+
["2016", "2017", "2017", "2017", "2017", "2018", "2018", "2018", "2018"],
7+
["initial", "q1", "q2", "q3", "total", "q1", "q2", "q3", "total" ]
8+
],
9+
measure: ["absolute", "relative", "relative", "relative", "total", "relative", "relative", "relative", "total"],
10+
y: [10, 20, 30, -10, null, 10, 20, -40, null],
11+
base: 300,
12+
decreasing: { marker: { color: "Maroon" , line:{color : "red", width :2}}},
13+
increasing: { marker: { color: "Teal"} },
14+
totals: { marker: { color: "deep sky blue", line:{color:'blue',width:3}} }
15+
}];
16+
var layout = {title: {
17+
text: "Profit and loss statement"
18+
},
19+
waterfallgap : 0.3,
20+
xaxis: {
21+
title: "",
22+
tickfont: {size: 15},
23+
ticks: "outside"
24+
}
25+
}
26+
Plotly.newPlot(gd, data, layout);

ggplot2/index.html

Lines changed: 24 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -666,6 +666,8 @@ <h1 class="--name">plotly</h1>
666666

667667

668668

669+
670+
669671

670672

671673

@@ -933,6 +935,12 @@ <h1>Plotly ggplot2 Library</h1>
933935

934936

935937

938+
939+
940+
941+
942+
943+
936944

937945

938946

@@ -959,12 +967,6 @@ <h1>Plotly ggplot2 Library</h1>
959967

960968

961969

962-
963-
964-
965-
966-
967-
968970

969971

970972
<li style="background-image: url(https://images.plot.ly/plotly-documentation/thumbnail/bar.jpg);" class="--grid-item">
@@ -999,6 +1001,8 @@ <h1>Plotly ggplot2 Library</h1>
9991001

10001002

10011003

1004+
1005+
10021006

10031007

10041008
<li style="background-image: url(https://images.plot.ly/plotly-documentation/thumbnail/jitter.png);" class="--grid-item">
@@ -1019,8 +1023,6 @@ <h1>Plotly ggplot2 Library</h1>
10191023

10201024

10211025

1022-
1023-
10241026

10251027

10261028
<li style="background-image: url(https://images.plot.ly/plotly-documentation/thumbnail/line_shapes.jpg);" class="--grid-item">
@@ -1221,8 +1223,6 @@ <h1>Plotly ggplot2 Library</h1>
12211223

12221224

12231225

1224-
1225-
12261226

12271227
<li style="background-image: url(https://images.plot.ly/plotly-documentation/thumbnail/geom_ribbon.jpg);" class="--grid-item">
12281228
<a href="/ggplot2/geom_ribbon/">
@@ -1241,16 +1241,18 @@ <h1>Plotly ggplot2 Library</h1>
12411241

12421242

12431243

1244+
1245+
12441246

1245-
<li style="background-image: url(https://images.plot.ly/plotly-documentation/thumbnail/line-plots.jpg);" class="--grid-item">
1246-
<a href="/ggplot2/geom_smooth/">
1247+
<li style="background-image: url(https://images.plot.ly/plotly-documentation/thumbnail/stat_smooth.jpg);" class="--grid-item">
1248+
<a href="/ggplot2/stat_smooth/">
12471249

12481250

1249-
<!--<a href="ggplot2/geom_smooth/">-->
1250-
<div class="--item-meta"><span>geom_smooth</span></div>
1251+
<!--<a href="ggplot2/stat_smooth/">-->
1252+
<div class="--item-meta"><span>stat_smooth</span></div>
12511253
<div class="--item-image">
12521254
<span>View Tutorial</span>
1253-
<img src="https://images.plot.ly/plotly-documentation/thumbnail/line-plots.jpg" alt="geom_smooth">
1255+
<img src="https://images.plot.ly/plotly-documentation/thumbnail/stat_smooth.jpg" alt="stat_smooth">
12541256
</div>
12551257
</a>
12561258

@@ -1260,15 +1262,15 @@ <h1>Plotly ggplot2 Library</h1>
12601262

12611263

12621264

1263-
<li style="background-image: url(https://images.plot.ly/plotly-documentation/thumbnail/stat_smooth.jpg);" class="--grid-item">
1264-
<a href="/ggplot2/stat_smooth/">
1265+
<li style="background-image: url(https://images.plot.ly/plotly-documentation/thumbnail/line-plots.jpg);" class="--grid-item">
1266+
<a href="/ggplot2/geom_smooth/">
12651267

12661268

1267-
<!--<a href="ggplot2/stat_smooth/">-->
1268-
<div class="--item-meta"><span>stat_smooth</span></div>
1269+
<!--<a href="ggplot2/geom_smooth/">-->
1270+
<div class="--item-meta"><span>geom_smooth</span></div>
12691271
<div class="--item-image">
12701272
<span>View Tutorial</span>
1271-
<img src="https://images.plot.ly/plotly-documentation/thumbnail/stat_smooth.jpg" alt="stat_smooth">
1273+
<img src="https://images.plot.ly/plotly-documentation/thumbnail/line-plots.jpg" alt="geom_smooth">
12721274
</div>
12731275
</a>
12741276

@@ -1367,8 +1369,6 @@ <h1>Plotly ggplot2 Library</h1>
13671369

13681370

13691371

1370-
1371-
13721372

13731373
<li style="background-image: url(https://images.plot.ly/plotly-documentation/thumbnail/apple_stock_animation.gif);" class="--grid-item">
13741374
<a href="/ggplot2/cumulative-animations/">
@@ -1413,6 +1413,8 @@ <h1>Plotly ggplot2 Library</h1>
14131413

14141414

14151415

1416+
1417+
14161418

14171419

14181420

javascript-graphing-library/bar-charts/index.html

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,10 @@
22
<html lang="en-US">
33
<meta charset="utf-8">
44
<title>Redirecting&hellip;</title>
5-
<link rel="canonical" href="https://plot.ly/javascript/bar-charts/">
6-
<script>location="https://plot.ly/javascript/bar-charts/"</script>
7-
<meta http-equiv="refresh" content="0; url=https://plot.ly/javascript/bar-charts/">
5+
<link rel="canonical" href="https://plot.ly/javascript/waterfall-charts/">
6+
<script>location="https://plot.ly/javascript/waterfall-charts/"</script>
7+
<meta http-equiv="refresh" content="0; url=https://plot.ly/javascript/waterfall-charts/">
88
<meta name="robots" content="noindex">
99
<h1>Redirecting&hellip;</h1>
10-
<a href="https://plot.ly/javascript/bar-charts/">Click here if you are not redirected.</a>
10+
<a href="https://plot.ly/javascript/waterfall-charts/">Click here if you are not redirected.</a>
1111
</html>

javascript/3d-charts/index.html

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1643,6 +1643,18 @@ <h1 class="--name">plotly</h1>
16431643

16441644

16451645

1646+
1647+
1648+
1649+
1650+
1651+
1652+
1653+
1654+
1655+
1656+
1657+
16461658

16471659

16481660

@@ -1898,6 +1910,8 @@ <h1 class="--name">plotly</h1>
18981910

18991911

19001912

1913+
1914+
19011915

19021916

19031917

0 commit comments

Comments
 (0)