https://github.com/g1eb/wordcloud
⛅️ Wordcloud
https://github.com/g1eb/wordcloud
d3 pandas wordcloud
Last synced: about 2 months ago
JSON representation
⛅️ Wordcloud
- Host: GitHub
- URL: https://github.com/g1eb/wordcloud
- Owner: g1eb
- Created: 2016-11-22T13:31:56.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2017-09-25T13:24:21.000Z (almost 9 years ago)
- Last Synced: 2025-08-03T12:38:36.274Z (11 months ago)
- Topics: d3, pandas, wordcloud
- Language: JavaScript
- Homepage: https://rawgit.com/g1eb/wordcloud/master/
- Size: 66.4 KB
- Stars: 3
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# A quick and dirty wordcloud generator.
You have a large text file and you need a wordcloud? Look no further!
Based on wordcloud layout by Jason Davies, [wordcloud](https://www.jasondavies.com/wordcloud/)
Algorithm due to Jonathan Feinberg, [wordle](http://static.mrfeinberg.com/bv_ch03.pdf)
## Demo
Click here for a live demo.
## Usage
1) Take a text file and run it through `filter.py` script
```
$ ./filter.py -i data.txt -o output.json
```
For this to work you need to install pandas (pip install pandas).
That script will dump aggregated tokens json right in the current directory.
2) Update OUTPUT variable in src/js/cloud.js
```
var OUTPUT = 'output.json';
```
You need to set OUTPUT variable to the location of the new output.json file.
3) Serve that directory and view wordcloud in a browser :)
```
$ python -m SimpleHTTPServer 8000
```
or:
```
$ npm install -g serve
$ serve .
```
## Dependencies
* [d3.js](https://d3js.org/)
* [d3.layout.cloud.js](https://gist.github.com/emeeks/3361332)
* [pandas](http://pandas.pydata.org/)