It's not a secret anymore!
The moose likes Websphere and the fly likes Creating graphs in java Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » Websphere
Bookmark "Creating graphs in java" Watch "Creating graphs in java" New topic

Creating graphs in java

sridhar lakka
Ranch Hand

Joined: Jan 02, 2007
Posts: 109
Hi All,
Thanks in advance.
In my task i have to create a line graph,i have two sets of numeric values say speed and distance , and i want draw a graph depending upon the the values.I need this graph generation at dynamic time means depending upon the values set choosen the graph should redraw.
Is it possible to draw a graph without AWT/Applets?
Please give me some example code.

Thanks & Regards
Rama Krishna Ghanta
Ranch Hand

Joined: Nov 20, 2006
Posts: 59
You can go for an Open Source third party tool called JFree Charts. Go to this URL for more info.

Rama Krishna Ghanta

Ulf Dittmer

Joined: Mar 22, 2005
Posts: 42965
Packages like JFreeChart or JChart2D can do this (both are linked here). If this is in a JSP page, then the cewolf tag library might also help.
sridhar lakka
Ranch Hand

Joined: Jan 02, 2007
Posts: 109
Thanks for your reply.
But i have a doubt and tested on UNIX websphere server JFree charts are not working.
Please tell me whether i need to take any extra cautions before working on unix websphere.
I tested Tomcat windows then working fine.

Thanks a lot
I agree. Here's the link:
subject: Creating graphs in java
It's not a secret anymore!