ISG-ICS / cloudberry

Big Data Visualization
http://cloudberry.ics.uci.edu
90 stars 82 forks source link

Popup Window in CountMap of TwitterMap #540

Closed lengyyy closed 6 years ago

lengyyy commented 6 years ago

Overview

It aims to show more information in a popup window when the mouse hover a state, county or city. This extra information may be trend of the tweets count or others.

An example in Tableau:

screen shot 2018-07-03 at 10 28 38 am

Progress

The Libraries for Chart

Requirement

Libraries

Name Link License Pros Cons
angular-chart.js https://github.com/jtblin/angular-chart.js BSD Based on Chart.js, powerful, easy to use Better to be MIT or Apache license
Chart.js https://github.com/chartjs/Chart.js MIT Popular and powerful Not adapted in AngularJS
ngx-charts https://github.com/swimlane/ngx-charts MIT Declarative Charting Framework for Angular2 Not AngularJS
tc-angular-chartjs https://github.com/carlcraig/tc-angular-chartjs MIT/Apache AngularJS directives for Chart.js Not very popular
angular-google-chart https://github.com/angular-google-chart/angular-google-chart MIT AngularJS directive for Google Chart Tools Not very popular

Choose Chart.js

How to add a third party library into Twittermap

I encounter some problem about this topic, so I give the instructions below. Hope it can help others. The document of playframwork may be help.

  1. Visit WebJars, search webjars version of the library you want to use.
  2. Copy the line in "Build Tool" column (the build tool we use is sbt), to "cloudberry/examples/twittermap/project/dependencies.scala".
  3. Turn off the server of twittermap, and restart it. The new library will be downloaded by build tool.
  4. Add the required .js into head tag of "cloudberry/examples/twittermap/web/app/views/twittermap/main.scala.html". If you don't know where the .js located at, check the folder "cloudberry/examples/twittermap/web/target/web/web-moudles/main/webjars/lib"
  5. After that, you can use the library as you want.

To Do List

baiqiushi commented 6 years ago

579