Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
a d3 pack
{
"name":"SAIT",
"children": [
{
"name":"A",
"children": [
{"name":"DOS",
"children": [
{"name":"CalCentral student portal","size":600}
]
},
{
"name":"FASO",
"children": [
{"name":"ProSAM","size":1100},
{"name":"MyFinAid","size":800},
{"name":"ImageNow","size":700},
{"name":"DSAS","size":700}
]
},
{
"name":"OR",
"children": [
{"name":"Enrollments","size":1500},
{"name":"Registration","size":1500},
{"name":"Registration Blocking","size":1500},
{"name":"Records","size":1300},
{"name":"Classroom Scheduling","size":1200},
{"name":"Course Approval","size":1200},
{"name":"Fees","size":1100},
{"name":"DARWin","size":100},
{"name":"DARS Web","size":100},
{"name":"DARS - U.Select","size":100},
{"name":"DARS - U.Direct","size":100},
{"name":"DARS - U.Achieve","size":900},
{"name":"Summer Session","size":800},
{"name":"Fall Program for Freshman","size":700},
{"name":"Census","size":600}
]
},
{
"name":"OUA",
"children": [
{"name":"OUAE","size":1500},
{"name":"Foxpro/Navigator","size":100},
{"name":"UGA","size":100},
{"name":"Transfer Course System (TCS)","size":900},
{"name":"mBA","size":600}
]
},
{
"name":"RSSP",
"children": [
{"name":"CARS interface","size":800},
{"name":"CS Gold","size":600},
{"name":"CalConnects Reg Process","size":600}
]
}
]
},
{
"name":"B",
"children": [
{"name":"Career Center",
"children": [
{"name":"Callisto/NaceLink Authentication Module","size":400}
]
},
{
"name":"DOS",
"children": [
{"name":"Student Org system (current)","size":300},
{"name":"Advocate Conduct System","size":300},
{"name":"OSCAR","size":300},
{"name":"CalMuse","size":200},
{"name":"FMPro - Old conduct cases","size":200}
]
},
{
"name":"FASO",
"children": [
{"name":"CTS","size":300},
{"name":"SIMS","size":300},
{"name":"WSMS","size":300},
{"name":"AWCS","size":200}
]
},
{
"name":"OR",
"children": [
{"name":"DARS Help","size":500},
{"name":"DARS Migration Scripts","size":500},
{"name":"SLR Tracker","size":400},
{"name":"Online Room Request Form","size":400},
{"name":"Law Records System","size":400},
{"name":"Point of Sale","size":300},
{"name":"Official Academic Calendar Website","size":300}
]
},
{
"name":"RSSP",
"children": [
{"name":"Payroll","size":500},
{"name":"Bandwidth related tools","size":500},
{"name":"C1C Webapp","size":400},
{"name":"Cashiering","size":400},
{"name":"Micros","size":400},
{"name":"NSS","size":400},
{"name":"StarRez","size":400},
{"name":"HOP","size":400},
{"name":"SQL Server","size":400},
{"name":"WPPS","size":400},
{"name":"OSCAR","size":300},
{"name":"Cal Catering (CaterTrax)","size":300},
{"name":"CONMAN","size":300},
{"name":"Reserve","size":300},
{"name":"StarRez Client-Server","size":300},
{"name":"UV-VB code","size":300},
{"name":"PandaCon","size":300},
{"name":"HGL","size":200}
]
}
]
},
{
"name":"C",
"children": [
{"name":"Career Center",
"children": [
{"name":"Career Destination Survey Reports.","size":100}
]
},
{
"name":"DOS",
"children": [
{"name":"Public Service Program Management","size":100},
{"name":"Volunteer Match","size":100}
]
},
{
"name":"OR",
"children": [
{"name":"My Residency","size":100},
{"name":"Registrar CMS","size":100}
]
},
{
"name":"OUA",
"children": [
{"name":"OUA","name":"Hobsons EMT Connect","size":100}
]
},
{
"name":"RSSP",
"children": [
{"name":"ECEP Online Application","size":100},
{"name":"FoodPro - nutrition module","size":100},
{"name":"Online Hiring","size":100},
{"name":"OSD Events Database","size":100},
{"name":"Pharos","size":100},
{"name":"ResHall","size":100},
{"name":"TMA (iServiceDesk)","size":100},
{"name":"Cable TV","size":100},
{"name":"PostgreSQL","size":100},
{"name":"Emp4","size":100},
{"name":"NAC","size":100},
{"name":"Parse Contracts","size":100},
{"name":"Cal Dining","size":100},
{"name":"Cal Housing","size":100},
{"name":"Conference Services","size":100},
{"name":"Housing site","size":100},
{"name":"it.housing.berkeley.edu","size":100}
]
}
]
},
{
"name":"D",
"children": [
{"name":"Career Center",
"children": [
{"name":"Online Appointment Management System (Mini, 30-minute and 45-minute).","size":50},
{"name":"Letter Service System","size":50},
{"name":"Job Fair Attendance Reports","size":50},
{"name":"Externships System","size":50},
{"name":"Employer Visibility Services","size":50},
{"name":"Alumni Advance Enrollment","size":50},
{"name":"Questions & Answers Center","size":50}
]
},
{
"name":"DOS",
"children": [
{"name":"Student Org system (new)","size":50},
{"name":"Tracker","size":50},
{"name":"Help Desk","size":50},
{"name":"Cal2Action","size":50},
{"name":"People Locator","size":50},
{"name":"Student Opportunity Panel fund","size":50},
{"name":"RSVP","size":50},
{"name":"Workstudy tracking","size":50},
{"name":"FMPro - Events Tracking","size":50},
{"name":"FMPro - old Greek data","size":50},
{"name":"CEP / CEO","size":50},
{"name":"SA CMS/web site","size":50},
{"name":"InvolveMe","size":50},
{"name":"CADS reporting","size":50},
{"name":"Risk Management/Event Insurance","size":50}
]
},
{
"name":"FASO",
"children": [
{"name":"Emergency Loan","size":50},
{"name":"RCRSVP","size":50},
{"name":"S3","size":50}
]
},
{
"name":"OR",
"children": [
{"name":"Classroom Tracker","size":50},
{"name":"Student Group Reservations","size":50},
{"name":"Help Desk","size":50}
]
},
{
"name":"OUA",
"children": [
{"name":"Hyperion (campus)","size":50},
{"name":"SQL Server DB","size":50},
{"name":"Infomatica","size":50}
]
},
{
"name":"RSSP",
"children": [
{"name":"Cal Rentals App","size":50},
{"name":"Crystal Reports","size":50},
{"name":"EMS Systems","size":50},
{"name":"FoodPro","size":50},
{"name":"Host Access","size":50},
{"name":"ImageNow","size":50},
{"name":"NoHo","size":50},
{"name":"SM Readers","size":50},
{"name":"TMA","size":50},
{"name":"TrainMan","size":50},
{"name":"App Keys Management","size":50},
{"name":"APPV","size":50},
{"name":"ASC Account Provisioning","size":50},
{"name":"BigFix","size":50},
{"name":"Bugzilla","size":50},
{"name":"IP Tool - lite","size":50},
{"name":"IT Asset Tracking","size":50},
{"name":"ITProject","size":50},
{"name":"ITSM","size":50},
{"name":"MCCA","size":50},
{"name":"Nagios","size":50},
{"name":"PushTool","size":50},
{"name":"RSSP Domain PWD Changer","size":50},
{"name":"RT","size":50},
{"name":"Symantec","size":50},
{"name":"TWIKI","size":50},
{"name":"VMWare","size":50},
{"name":"Zabbix","size":50},
{"name":"Devices","size":50},
{"name":"Internals","size":50},
{"name":"SCUNC (2.0)","size":50}
]
}
]
}
]
}
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="content-type" content="text/html;charset=utf-8">
<title>d3.js ~ Circle Packing</title>
<script type="text/javascript" src="http://mbostock.github.com/d3/d3.js?2.6.0"></script>
<script type="text/javascript" src="http://mbostock.github.com/d3/d3.time.js?2.6.0"></script>
<style type="text/css">
circle {
fill: rgb(31, 119, 180);
fill-opacity: .25;
stroke: rgb(31, 119, 180);
stroke-width: 1px;
}
.leaf circle {
fill: #ff7f0e;
fill-opacity: 1;
}
text {
font: 10px sans-serif;
}
</style>
</head>
<body>
<div class='gallery' id='chart'> </div>
<script src='http://mbostock.github.com/d3/d3.layout.js?2.6.0' type='text/javascript'> </script><script src='pack.js' type='text/javascript'> </script>
</body>
</html>
var w = 960,
h = 500,
format = d3.format(",d");
var pack = d3.layout.pack()
.size([w - 4, h - 4])
.value(function(d) { return d.size; });
var vis = d3.select("#chart").append("svg:svg")
.attr("width", w)
.attr("height", h)
.attr("class", "pack")
.append("svg:g")
.attr("transform", "translate(2, 2)");
d3.json("data.json", function(json) {
var node = vis.data([json]).selectAll("g.node")
.data(pack.nodes)
.enter().append("svg:g")
.attr("class", function(d) { return d.children ? "node" : "leaf node"; })
.attr("transform", function(d) { return "translate(" + d.x + "," + d.y + ")"; });
node.append("svg:title")
.text(function(d) { return d.name + (d.children ? "" : ": " + format(d.size)); });
node.append("svg:circle")
.attr("r", function(d) { return d.r; });
node.filter(function(d) { return !d.children; }).append("svg:text")
.attr("text-anchor", "middle")
.attr("dy", ".3em")
.text(function(d) { return d.name.substring(0, d.r / 3); });
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.