Skip to content

Instantly share code, notes, and snippets.

View AlessandraSozzi's full-sized avatar

Alessandra Sozzi AlessandraSozzi

  • IMF
  • Washington, DC
View GitHub Profile
@AlessandraSozzi
AlessandraSozzi / index.html
Last active October 6, 2015 16:53
Combination of Stroke Dash Interpolation and Point-Along-Path
<!DOCTYPE html>
<meta charset="utf-8">
<body>
<style>
path {
fill: none;
stroke: #000;
stroke-width: 3px;
}
circle {
@AlessandraSozzi
AlessandraSozzi / increase.csv
Last active January 21, 2016 11:32
#PragmaConf 2015 Women Participants & Speakers
year value
2013 2
2014 6
2015 19
@AlessandraSozzi
AlessandraSozzi / data.tsv
Last active January 21, 2016 11:37
#PragmaConf 2015 Participants country of origin
first second third
1 0.73 0.47
0 0.27 0.53
@AlessandraSozzi
AlessandraSozzi / circles.json
Last active January 21, 2016 11:41
#PragmaConf 2015 Participants
{"objects":[
{"circle":{"coordinates":[47.4156189,8.5889722]}},
{"circle":{"coordinates":[45.6982642,9.6772698]}},
{"circle":{"coordinates":[45.4654219,9.1859243]}},
{"circle":{"coordinates":[37.5078772,15.0830304]}},
{"circle":{"coordinates":[45.5454787,11.5354214]}},
{"circle":{"coordinates":[46.151241,14.995463]}},
{"circle":{"coordinates":[45.9549755,13.6493044]}},
{"circle":{"coordinates":[43.7695604,11.2558136]}},
{"circle":{"coordinates":[41.9027835,12.4963655]}},
@AlessandraSozzi
AlessandraSozzi / complete.json
Created November 4, 2015 15:29
Mille Miglia 2015
[{"type":"aggregatedCount","time":"Thu May 14 2015 10:15:00 +0000","value":0},{"type":"aggregatedCount","time":"Thu May 14 2015 10:20:00 +0000","value":1},{"type":"aggregatedCount","time":"Thu May 14 2015 10:25:00 +0000","value":1},{"type":"geolocatedTweet","time":"Thu May 14 2015 10:28:48 +0000","coordinates":[45.535274650000005,10.22381405]},{"type":"aggregatedCount","time":"Thu May 14 2015 10:30:00 +0000","value":42},{"type":"geolocatedTweet","time":"Thu May 14 2015 10:30:23 +0000","coordinates":[45.535274650000005,10.22381405]},{"type":"aggregatedCount","time":"Thu May 14 2015 10:35:00 +0000","value":39},{"type":"geolocatedTweet","time":"Thu May 14 2015 10:35:32 +0000","coordinates":[45.535274650000005,10.22381405]},{"type":"aggregatedCount","time":"Thu May 14 2015 10:40:00 +0000","value":68},{"type":"geolocatedTweet","time":"Thu May 14 2015 10:43:43 +0000","coordinates":[45.535274650000005,10.22381405]},{"type":"aggregatedCount","time":"Thu May 14 2015 10:45:00 +0000","value":73},{"type":"aggregatedCount
@AlessandraSozzi
AlessandraSozzi / index.html
Last active August 30, 2016 03:15
Drag Behavior: drag bars in a bar chart
<!DOCTYPE html>
<meta charset="utf-8">
<head>
<style>
.chart div {
font: 10px sans-serif;
background-color: steelblue;
text-align: right;
padding: 3px;
@AlessandraSozzi
AlessandraSozzi / index.html
Last active May 8, 2024 19:26
D3 drag and drop: manually reorder rows and columns of a matrix
<!DOCTYPE html>
<meta charset="utf-8">
<head>
<style>
.background {
fill: #fff;
}
rect {
stroke: #fff;
@AlessandraSozzi
AlessandraSozzi / index.html
Last active December 23, 2015 14:27
Stroke-dasharray animation with arrow orientation
<!DOCTYPE html>
<meta charset="utf-8">
<body>
<style>
path {
fill: none;
stroke: #000;
stroke-width: 3px;
}
circle {
@AlessandraSozzi
AlessandraSozzi / index.html
Last active August 30, 2016 03:13
Relationships among teams
<!DOCTYPE html>
<meta charset="utf-8">
<link href='https://fonts.googleapis.com/css?family=Noto+Sans:400,700' rel='stylesheet' type='text/css'>
<head>
<style>
.background {
fill: #fff;
}
@AlessandraSozzi
AlessandraSozzi / d3.v3.min.js
Last active June 25, 2016 12:19
NYC Taxi Trips
!function(){function n(n){return n&&(n.ownerDocument||n.document||n).documentElement}function t(n){return n&&(n.ownerDocument&&n.ownerDocument.defaultView||n.document&&n||n.defaultView)}function e(n,t){return t>n?-1:n>t?1:n>=t?0:NaN}function r(n){return null===n?NaN:+n}function u(n){return!isNaN(n)}function i(n){return{left:function(t,e,r,u){for(arguments.length<3&&(r=0),arguments.length<4&&(u=t.length);u>r;){var i=r+u>>>1;n(t[i],e)<0?r=i+1:u=i}return r},right:function(t,e,r,u){for(arguments.length<3&&(r=0),arguments.length<4&&(u=t.length);u>r;){var i=r+u>>>1;n(t[i],e)>0?u=i:r=i+1}return r}}}function a(n){return n.length}function o(n){for(var t=1;n*t%1;)t*=10;return t}function l(n,t){for(var e in t)Object.defineProperty(n.prototype,e,{value:t[e],enumerable:!1})}function c(){this._=Object.create(null)}function s(n){return(n+="")===xa||n[0]===ba?ba+n:n}function f(n){return(n+="")[0]===ba?n.slice(1):n}function h(n){return s(n)in this._}function g(n){return(n=s(n))in this._&&delete this._[n]}function p(){var n=[]