Download code/train/JavaScript/0004094_load_chart.js from Variable-role/sajaniemi_variable_dataset_large: direct link, hf CLI and curl.
- Browser
- Download file 755 Bytes
-
https://huggingface.co/datasets/Variable-role/sajaniemi_variable_dataset_large/resolve/main/code/train/JavaScript/0004094_load_chart.js
- Command line
-
hf download hf://datasets/Variable-role/sajaniemi_variable_dataset_large/code/train/JavaScript/0004094_load_chart.js
-
curl -L -o 0004094_load_chart.js https://huggingface.co/datasets/Variable-role/sajaniemi_variable_dataset_large/resolve/main/code/train/JavaScript/0004094_load_chart.js
755 Bytes
| /*vd3.csv("LEP_profiles.csv", function(data) {*/ | |
| //d3.select("#example") | |
| //.datum(data) | |
| //.call(chart); | |
| /*}*/; | |
| //d3.csv("LEP_profiles.csv", draw); | |
| var profile_bar = profile_bar_chart(); | |
| d3.csv("LEP_profiles.csv", function(d) { | |
| return { | |
| lep: d.LEP, | |
| profile: Object.keys(d).slice(1,-1).map(function(var_name) { return( { variable: var_name, value: +d[var_name] } )}) | |
| }; | |
| }, function(error, rows) { | |
| profile_bar(rows); | |
| }); | |
| d3.json("lep_topo.json", function(error, topo) { | |
| draw_map(topo); | |
| }); | |
| d3.csv("LEP_profiles.csv", function(d) { | |
| return { | |
| lep: d.LEP, | |
| total: +d["Total"] | |
| }; | |
| }, function(error, rows) { | |
| var sorted_rows = rows.sort( function(a,b) { return a.total-b.total; } ); | |
| totals_histogram(sorted_rows); | |
| }); | |