Add badge and fix examples

This commit is contained in:
xtreak 2018-03-22 22:15:45 +05:30
parent c023e2352f
commit aaf84eac36
3 changed files with 8 additions and 4 deletions

View file

@ -1,7 +1,11 @@
# clj-wordcloud [![Build Status](https://travis-ci.org/tirkarthi/clj-wordcloud.svg?branch=master)](https://travis-ci.org/tirkarthi/clj-wordcloud)
# clj-wordcloud [![Clojars Project](https://img.shields.io/clojars/v/xtreak/clj-wordcloud.svg)](https://clojars.org/xtreak/clj-wordcloud) [![Build Status](https://travis-ci.org/tirkarthi/clj-wordcloud.svg?branch=master)](https://travis-ci.org/tirkarthi/clj-wordcloud)
A simple clojure wrapper around kumo to generate wordcloud
## Leiningen
`[xtreak/clj-wordcloud "0.0.1"]`
## Example
Given a map of element and the frequency the following image is generated. More examples/examples.clj.
@ -10,7 +14,7 @@ Given a map of element and the frequency the following image is generated. More
```clojure
(ns examples
(:require '[clj-wordcloud.core :refer :all]))
(:require [clj-wordcloud.core :refer :all]))
(let [frequency-map (zipmap (random-words 100) (shuffle (range 300)))
word-cloud (word-cloud frequency-map
@ -34,7 +38,7 @@ Given a map of element and the frequency the following image is generated. More
```clojure
(ns examples
(:require '[clj-wordcloud.core :refer :all]))
(:require [clj-wordcloud.core :refer :all]))
(let [frequency-map (zipmap (range 100 150) (shuffle (range 300)))
word-cloud (word-cloud frequency-map

Binary file not shown.

Before

Width:  |  Height:  |  Size: 173 KiB

After

Width:  |  Height:  |  Size: 66 KiB

View file

@ -1,5 +1,5 @@
(ns examples
(:require '[clj-wordcloud.core :refer :all]))
(:require [clj-wordcloud.core :refer :all]))
(defn random-words