Inline Analytics

  Display of answer distribution graphics inline on the problem page
  for instructors.

  Problem types supported for graphics:
    - MultipleChoiceResponse
    - ChoiceResponse

  Problem types supported for line item display:
    - OptionResponse
    - NumericalResponse
    - StringResponse
    - FormulaResponse
    via setting

Internal review only for now.
Couldn't this function have used some helper functions?  It does a lot of stuff.  It's better to compose something out of smaller functions for understanding.  For instance, the network stuff could have been separated out from the data munging.  Easier to test, also.