score:0

Accepted answer

you can retreive json data using d3 as follows;

d3.json("/path/to/json", function(d) {
    //rendering code
}

and then, inside the callback function (in place of rendering code) you can access the json data using the variable "d".

the following summerizes the general procedure to follow after retreiving the data;

//create a svg
svg = d3.select("selector_to_some_dom_element").append("svg");

//then append text for each data json entry
svg.selectall(".yourclassnamehere")
        .data(d) //received data
        .enter()
        .text(function (d) { //add some text
            //using occurrencefrequency
            return d.occurrencefrequency
        });

you can read more detailed d3 json data management at http://pothibo.com/2013/09/d3-js-how-to-handle-dynamic-json-data/


Related Query

More Query from same tag