DotPlot is a data visualisation tool built on top of D3.js to help non-programmers create interactive data visualisations using easy to use drag and drop interface.
To contribute to this project, you will need the following things properly installed on your computer.
git clone https://github.com/berkmancenter/dotplot.git
this repository- change into the new directory
npm install
bower install
ember server
- Visit your app at http://localhost:4200/create.
- Public View:
http://localhost:4200/project?id=<Your Project Id>
.
- Change into the API directory
cd api/
npm install
node index.js
- Make HTTP requests at
http://locahost:3000/api/<API Endpoint>
Make use of the many generators for code, try ember help generate
for more details
ember test
ember test --server
ember build
(development)ember build --environment production
(production)
Accepts: None
Use: Calls importJSONData
if a valid Project ID is provided.
Accepts: None
Use: Observes showLabel
property and calls showLabels
or removeLabels
.
Accepts: Type of frame (String)
Returns: An array of node objects.
Accepts: Number of choices (Array)
Returns: An array of foci coordinates.
Accepts: None
Action: Calls another action based on the type of frame.
Accepts: None
Action: Creates a new record for a single choice frame and calls d3Init (Run force layout).
Accepts: None
Action: Creates a new record for a multiple choice frame and calls d3Init
(Run force layout).
Accepts: None
Action: Displays createFrame
model if CSV file is loaded.
Accepts: Frame (Object)
Action: Deletes the frame record based on the provided frame object.
Accepts: Element Id (String)
Action: Displays dialog based on the provided id.
Accepts: Element Id (String)
Action: Hides dialog based on the provided id.
Accepts: File (Object)
Action: Calls importJSONData
or importCSVData
based on the file type.
Accepts: File (Object)
Action: Creates new frame records using the data in the provided JSON file.
Accepts: File (Object)
Action: Extracts different columns from the CSV file and creates node objects. Allows to create frames from scratch.
Accepts: Column (Object)
Action: Updates the selectedColumn
(Question) and highlights the selection.
Accepts: Frame (Object)
Action: Updated nodes data, removes the nodes that are not in the data exit()
creates nodes that are not on the SVG enter()
and calls force layout action d3Plot
.
Accepts: Node Selection (Object) and Frame (Object)
Action: Finds all the nodes using nodeId (Including Duplicate Nodes), increases the node radius and calls the nodeInfo
action.
Accepts: Node Selection (Object)
Action: Displays node information DOM Element (Question Answer Sets).
Accepts: None
Action: Hides the node info DOM Element.
Accepts: Frame (Object)
Action: Updates nodes data and runs force layout force.start()
.
Accepts: None
Action: Selects all the labels on the SVG and removes them.
Accepts: Frame (Object) and updatePosition (Boolean)
Action: Updated label data and creates labels 'enter()'.
Accepts: None
Action: Hides editLabel dialog, calls showLabels
action after removeLabels
.
Accepts: Frame (Object)
Action: Iterates over nodes on the SVG and updates the X and Y coordinates of the nodes in the frame object.
Accepts: Change Event (Object)
Action: Sets new gravity value and calls d3Plot
action after removeLabels
action.
Accepts: Change Event (Object)
Action: Sets new charge value and calls d3Plot
action after removeLabels
action.
Accepts: Change Event (Object)
Action: Transitions into new radius value transition()
.
Accepts: Frame (Object)
Action: Updates the nodes data, removes nodes that are not in the data exit()
creates nodes that are not on the SVG enter()
and transitions into the specified node positions.
Accepts: Type of notification [Error, Warning, Info, Success] (String) and Notification Message (String)
Action: Displays a notification at the bottom of the view which automatically disappears after 2200ms.
Accepts: File (Blob) and File Name (String)
Action: Posts the data to /api/project
and displays a notification with Project ID Hash.
Accepts: Type (String)
Action: Iterates over all the frame records and creates a Blob, calls sendToServer
if the type is Publish or else downloads a json file DotPlot.json
.
Dotplot is licensed under the GPL
2017 President and Fellows of Harvard College