This sub-module of thi.ng/geom is dealing with 2d/3d data visualizations using SVG (soon WebGL & others) and is in early stage development. Examples are currently littered throughout the core namespace of this module, linked below….
The aim of this module is to define a largely declarative and output format independent data visualization system. A visualization spec (a hashmap) is used to configure all aspects of the desired output and then passed to a single visualization handler to produce an visualization asset. The sole role of the visualization handler is to translate the spec into a concrete graphics format representation, though this translation is only occurring as the final step and the spec based approach allows creating multiple outputs, re-using visualization recipes and therefore building higher level tooling on top of this basic setup. Everything prior to the final translation is completely format independent and can also be processed further via 3rd party tooling.
Having said this, since this module is still in its infancy, currently only SVG output is implemented as test bed. However, many (if not all) required parts to support other targets are already existing in isolation and once the core API has stabilized will be fairly trivial to add.
ALPHA quality, in active development.
Please see the parent project for further information.
This template uses shared project configuration defined in config.org. Module specific settings are defined below:
This library is only used in the :dev
profile and needed to run the
Github heatmap visualization example.
[tentacles "0.3.0"]
(defproject <<project-name>> "<<conf-version()>>"
:description "thi.ng geometry kit - data visualization module"
:url "<<conf-project-url>>"
:license {:name "Apache Software License"
:url "http://www.apache.org/licenses/LICENSE-2.0"
:distribution :repo}
:scm {:name "git"
:url "<<conf-project-url>>"}
:min-lein-version "2.4.0"
:dependencies [<<dep-clj>>
<<dep-cljs>>
[thi.ng/geom-svg "<<conf-version()>>"]
<<dep-ndarray>>
<<dep-strf>>
<<dep-xerror>>
<<dep-color>>]
:profiles {:dev {:dependencies [<<dep-criterium>>
<<dep-tentacles>>]
:plugins [<<dep-cljsbuild>>
<<dep-cljs-test>>]
:global-vars {*warn-on-reflection* true}
:jvm-opts ^:replace []
:aliases {"cleantest" ["do" "clean," "test," "cljsbuild" "test"]}}}
:cljsbuild {:builds [{:source-paths ["src" "test"]
:id "simple"
:compiler {:output-to "<<cljs-artefact-path>>"
:optimizations :whitespace
:pretty-print true}}]
:test-commands {"unit-tests" ["phantomjs" :runner "<<cljs-artefact-path>>"]}}
:pom-addition [:developers [:developer
[:name "Karsten Schmidt"]
[:url "http://postspectacular.com"]
[:timezone "0"]]])
<!DOCTYPE html>
<html lang="en">
<head>
<title><<lein-coords>> test</title>
</head>
<body>
<script type="text/javascript" src="<<cljs-artefact-path>>"></script>
</body>
</html>
The autogenerated namespace thi.ng.geom.viz.version
contains a single
symbol version
holding the version string defined above:
(use 'thi.ng.geom.viz.version)
(prn version)
; "<<conf-version()>>"
(ns thi.ng.geom.viz.version)
(def version "<<conf-version()>>")
Name | Role | Website |
Karsten Schmidt | initiator & principal developer | postspectacular.com, http://thi.ng |