Giter Site home page Giter Site logo

chart's Introduction

Chart.java

Maven Central badge Javadocs License

Chart.java enables integration with the excellent Chart.js library from within a Java application.

Usage example

In Java:

BarDataset dataset = new BarDataset()
		.setLabel("sample chart")
		.setData(65, 59, 80, 81, 56, 55, 40)
		.addBackgroundColors(Color.RED, Color.GREEN, Color.BLUE, Color.YELLOW, Color.ORANGE, Color.GRAY, Color.BLACK)
		.setBorderWidth(2);

BarData data = new BarData()
		.addLabels("Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday", "Sunday")
		.addDataset(dataset);

return new BarChart(data).toJson();

In JavaScript:

var ctx = document.getElementById('canvasId');
new Chart(ctx, json);

Compatibility

Chart.js Chart.java
1.x 0.9.x
2.x 2.x

Test

See example charts by running the included unit tests:

mvn clean compile test

Javadoc

Browse this project's javadoc at javadoc.io.

Maven Central

Include this project directly from Maven Central

<dependency>
	<groupId>be.ceau</groupId>
	<artifactId>chart</artifactId>
	<version>2.6.0</version>
</dependency>

Download

Downloads for this project at Maven Central.

Other resources

The docs for Chart.js are a helpful source of info on what's possible and how to achieve it.

GnuPG public key

Verify signature files with my GnuPG public key.

License

Chart.java is licensed under the Apache 2.0 license.

chart's People

Contributors

benmccann avatar davidklebanoff avatar mdewilde avatar sschneller avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.