-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathvegalite_scatterplot.html
More file actions
29 lines (28 loc) · 939 Bytes
/
Copy pathvegalite_scatterplot.html
File metadata and controls
29 lines (28 loc) · 939 Bytes
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
<!DOCTYPE html>
<html>
<head>
<title>Embedding Vega-Lite</title>
<script src="https://cdn.jsdelivr.net/npm/vega@5.21.0"></script>
<script src="https://cdn.jsdelivr.net/npm/vega-lite@5.2.0"></script>
<script src="https://cdn.jsdelivr.net/npm/vega-embed@6.20.2"></script>
</head>
<body>
<div id="tw"></div>
<script type="text/javascript">
var vlspec = {
"$schema": "https://vega.github.io/schema/vega-lite/v5.json",
"data": {"url": "https://raw.githubusercontent.com/aaizemberg/2022/main/tw_edenor.csv" },
"config": {
"circle": {"size" : 50, "color": "steelblue"}
},
"mark": "circle",
"encoding": {
"x": {"field": "Number of Likes", "type": "quantitative", "title":"likes"},
"y": {"field": "Number of Retweets", "type": "quantitative", "title":"RT"},
"tooltip": {"field": "Content", "type": "nominal"}
}
};
vegaEmbed('div#tw', vlspec);
</script>
</body>
</html>