sarahzinger / questackular

A chrome extension and web application to help educators make reading more fun for their students.
http://questackular.herokuapp.com/
4 stars 0 forks source link

circle from 'view map' in 'create' D3 error #334

Closed sautille closed 9 years ago

sautille commented 9 years ago

Q type: undefined d3Factory.js:42 shtepz! [Object] d3.min.js:1 Error: Invalid value for attribute r="NaN"

Newms34 commented 9 years ago

Any idea what quest/step this was for? The radius should be pulled from the point value of the given question. The only way I could see this not working is if the question has no point value. We could check to see if the point value for a given step exists:

for (var i = 0; i < pointVals.length; i++) { if (pointVals[i]) { adjSiz.push(((pointVals[i] - min) * 40 / (max - min)) + 20); } else { adjSiz.push(20); //if for whatever reason the step does not have a point //value, default to lowest size(20); } } And yes, 'NaN' IS falsy, so that'd work for our purposes. As far as the qType or Q type, or Qtip, or whatever it is error, we can relatively safely ignore that for now.

sautille commented 9 years ago

I think it might be a problem with my local machine. It works on Heroku.