Using D3.xml to plot a tree layout

In d3.js, I have seen the use of d3.JSON to use a JSON for building a tree layout.
I have also worked with csv files, to first convert those in JSON by using d3.csv and d3.nest.
But,while taking a XML data dource using d3.xml, can anyone suggest how to proceed for making a tree layout without converting xml data to JSON first?

  • Using an ordinal scale ('d3.scale.ordinal') for the x-axis in a bar chart
  • Put markers to a map generated with topoJSON and d3.js
  • Uncaught SyntaxError: Unexpected token =
  • How to pack text inside svg rect
  • Change selected nodes style, d3.js collapsible indented tree
  • Multiple force-layout graphs with d3 in seperate svg/div's
  • D3 - get current time and subtract by 2 hours
  • d3 Zoomable Treemap from CSV
  • D3 javascript Difference between foreach and each
  • d3.js stacked bar chart with positive and negative values
  • Custom context menu in d3 and svg
  • How to cancel scheduled transition in d3?
  • One Solution collect form web for “Using D3.xml to plot a tree layout”

    You can use d3.xml (https://github.com/mbostock/d3/wiki/Requests#wiki-d3_xml) and then parse the content using javascript

    Resource on Javascript xml parsing:

    http://www.hiteshagrawal.com/javascript/javascript-parsing-xml-in-javascript.