<commit_before>var wid = 500,
	heig = 400,
	centerWidM;

var rootQue,forceQue,linksQue,nodesQue;
var factorBoard, visMake, factorCirclesEnter ;
var navSvgQ ;
var maxSize = 7, maxSizeFactor =22;
var  navCirclesQ;	
var checkedArray;
		
  	  				
function makeInit() {

	//Reserve the space for the visualization	
	visMake = d3.select("#makeViz").append("svg:svg")
			.attr("class", "alignCenter questionsViz")
			.attr("width", wid)
			.attr("height", 250);
			
 	//Align the visualization to the twitter bootstap div containing it
 	if($("#makeViz").width()){ centerWM = $("#makeViz").width()/2; }
	
	//Initialize Background Circles of Factors
	factorBoard= [	{ "id":"VisionGoals",
  	  				  "x": 3*centerWM/4,
  	  				  "y": heig/6+ heig/2
  	  				},
  	  				{ "id":"Group",
  	  				  "x": centerWM/2,
  	  				  "y": heig/3 + heig/2

  	  				},
  	  				{ "id":"PersonalResources",
  	  				  "x": 3*centerWM/2,
  	  				  "y": 3*heig/8+ heig/2

  	  				},
  	  				{ "id":"Partnerships",
  	  				  "x": 5*centerWM/4,
   	  				  "y": 5*heig/24+ heig/2

  	  				},
  	  				{ "id":"ExternalCommunications",
  	  				  "x": centerWM,
   	  				  "y": 3*heig/7+ heig/2

  	  				}];	
	
 	var factorCircles = visMake.selectAll("g.node")
  	  		.attr("class", "factorBoard")
  	  		.data(factorBoard);
  	  				   	
  	 navSvgQ = d3.select("#textNavigationQ").append("svg")
    				   .attr("width", $("#textNavigationQ").width())
  					   .attr("height", 20)
  					   .attr("class", "alignCenter");		   

  	  		
  	 factorCirclesEnter = 	factorCircles.enter().append("svg:g")
  	  				.attr("class", "node")
  	  				.append("svg:circle")
  	  				.attr("class", function(d){ return d.id+" circleBoard";})
  	  				.attr("r", 32)
  	  				.attr("cx", function(d,i ) { return  d.x})
  	  				.attr("cy",  function(d,i ) { return d.y})
  	  				.attr("fill", function(d) { return colorCode[d.id];})
  	  				.attr("opacity", "0.3");
  	  		
 		
	//  read the spreadsheet:
	Tabletop({
      	      key: "https://docs.google.com/spreadsheet/pub?key=0AiVJjmNPOjDmdEdNMy1RVVozM3ZvQUlKaEJtbFNESWc&output=html",
     	       callback: showInfo,
      	       simpleSheet: true,
      	       proxy: 'https://s3.amazonaws.com/flatware-live',
      	       debug : true
      });
    
    
      function showInfo (data, tablet) {     
    	  rootQue = makeToJsonQuestions(data);
      	  updateQuestions();<commit_msg>Update Description & comments<commit_after>/* ===================================================
 * artovamodel-vis makeYourOwn.js
 * artovamodel.fi/visual-eng --> self-reflection questions
 * ===================================================
 * FourCoffees 2013
 *
 * Licensed under the MIT License
 * using d3.js, tabletop.js, jquery.js
 * ========================================================== */

/*
Reads questions from a google spreadsheet and visualises
the user's repsonses with a point system.
The visualisign happens by changing the area of  the 
correpsonding circle.
*/


var wid = 500,
	heig = 400,
	centerWidM;

var rootQue,forceQue,linksQue,nodesQue;
var factorBoard, visMake, factorCirclesEnter ;
var navSvgQ ;
var maxSize = 7, maxSizeFactor =22;
var  navCirclesQ;	
var checkedArray;
		
  	  				
function makeInit() {

	//Reserve the space for the visualization	
	visMake = d3.select("#makeViz").append("svg:svg")
			.attr("class", "alignCenter questionsViz")
			.attr("width", wid)
			.attr("height", 250);
			
 	//Align the visualization to the twitter bootstap div containing it
 	if($("#makeViz").width()){ centerWM = $("#makeViz").width()/2; }
	
	//Initialize Background Circles of Factors
	factorBoard= [	{ "id":"VisionGoals",
  	  				  "x": 3*centerWM/4,
  	  				  "y": heig/6+ heig/2
  	  				},
  	  				{ "id":"Group",
  	  				  "x": centerWM/2,
  	  				  "y": heig/3 + heig/2

  	  				},
  	  				{ "id":"PersonalResources",
  	  				  "x": 3*centerWM/2,
  	  				  "y": 3*heig/8+ heig/2

  	  				},
  	  				{ "id":"Partnerships",
  	  				  "x": 5*centerWM/4,
   	  				  "y": 5*heig/24+ heig/2

  	  				},
  	  				{ "id":"ExternalCommunications",
  	  				  "x": centerWM,
   	  				  "y": 3*heig/7+ heig/2

  	  				}];	
	
 	var factorCircles = visMake.selectAll("g.node")
  	  		.attr("class", "factorBoard")
  	  		.data(factorBoard);
  	  				   	
  	 navSvgQ = d3.select("#textNavigationQ").append("svg")
    				   .attr("width", $("#textNavigationQ").width())
  					   .attr("height", 20)
  					   .attr("class", "alignCenter");		   

  	  		
  	 factorCirclesEnter = 	factorCircles.enter().append("svg:g")
  	  				.attr("class", "node")
  	  				.append("svg:circle")
  	  				.attr("class", function(d){ return d.id+" circleBoard";})
  	  				.attr("r", 32)
  	  				.attr("cx", function(d,i ) { return  d.x})
  	  				.attr("cy",  function(d,i ) { return d.y})
  	  				.attr("fill", function(d) { return colorCode[d.id];})
  	  				.attr("opacity", "0.3");
  	  		
 		
	//  read the spreadsheet:
	Tabletop({
      	      key: "XXXX", //Add google spreasheet with questions & point system here
     	       callback: showInfo,
      	       simpleSheet: true,
      	       proxy: 'https://s3.amazonaws.com/flatware-live',
      	       debug : true
      });
    
    
      function showInfo (data, tablet) {     
    	  rootQue = makeToJsonQuestions(data);
      	  updateQuestions();
{'fraction_non_alphanumeric': 0.18452935694315004, 'fraction_numerical': 0.017520969245107175, 'mean_word_length': 2.2501514233797697, 'pattern_counts': {'":': 30, '<': 3, '<?xml version=': 0, '>': 4, 'https://': 3, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6239896', 'n_tokens_mistral': 2305, 'n_tokens_neox': 2002, 'n_words': 352}