Search found 14 matches

by hongping
Wed Aug 18, 2004 8:42 pm
Forum: JFreeChart - Stockmarket
Topic: how to create graph in real time for monitoring
Replies: 1
Views: 3995

If you have purchased the developer's guide, there is a dynamic chart example in chapter 9 that monitors the JVM memory usage in real time. In short, you have to set the history count of a TimeSeries that you use in the Chart, and keep adding new points to the TimeSeries. The notification system in ...
by hongping
Wed Aug 18, 2004 5:46 pm
Forum: JFreeChart
Topic: Error occured while deploying on coldfusion application
Replies: 6
Views: 2652

Have you put the jar files for jfreechart into the lib directory of your webapp?
What is your servlet container setup, and how are you deploying the webapp?
by hongping
Mon Aug 16, 2004 6:25 pm
Forum: JFreeChart - Stockmarket
Topic: Converting XYDataset to TimeSeries
Replies: 1
Views: 5251

If you XYDataset has more than one series, then you could extract each series as a TimeSeries and then aggregate them together as a TimeSeriesCollection. I am assuming that the Date is stored as a value representing Time in Milliseconds. You could try the following: XYDataset dataset = yourClass.get...
by hongping
Mon Aug 16, 2004 6:06 pm
Forum: JFreeChart
Topic: Want JDBCCategoryChartDemo.java and JDBCPieChartDemo.java
Replies: 3
Views: 1518

If you have downloaded the jfreechart and extracted it, you could run the following command in the parent directory to search for it:
  • # find -iname "JDBCCategory*"

    ./jfreechart-0.9.20/src/org/jfree/data/JDBCCategoryDataset.java
Hope this helps.
by hongping
Mon Aug 16, 2004 6:01 pm
Forum: JFreeChart
Topic: Y Axis name question
Replies: 3
Views: 1295

I have beeng using the standard factory methods from ChartFactory such createStackedAreaXYChart and createTimeSeriesChart and it seems by default the y axis label is vertical. How are you creating the charts?
by hongping
Mon Aug 16, 2004 5:32 pm
Forum: JFreeChart - Stockmarket
Topic: Easy fix hopefully
Replies: 1
Views: 3776

See
http://www.jfree.org/phpBB2/viewtopic.php?t=9576

Use SimpleDateFormat, and override the domain axis of the plot.
by hongping
Mon Aug 16, 2004 5:31 pm
Forum: JFreeChart - Stockmarket
Topic: How do I change the date format for the axis in TimeSeries ?
Replies: 1
Views: 6618

You could try using java.text.SimpleDateFormat: String dateFormat = "yyyy/MM/dd HH:mm"; Or if you just want the date String dateFormat = "dd"; Then override the dataformat in the horizontal axis: XYPlot plot = chart.getXYPlot(); DateAxis axis = (DateAxis) plot.getDomainAxis(); axis.setDateFormatOver...
by hongping
Mon Aug 16, 2004 5:25 pm
Forum: JFreeChart - Stockmarket
Topic: Percentage y-ticks for yield-curve
Replies: 1
Views: 5108

You could try using

org.jfree.chart.axis.NumberAxis.setNumberFormatOverride

You can pass in a java.text.NumberFormat or java.text.DecimalFormat.

NumberFormat.getPercentInstance will actually give you a format for displaying percentages. Please do look up the javadocs and examples.
by hongping
Mon Aug 16, 2004 5:19 pm
Forum: JFreeChart - Stockmarket
Topic: how to save chart ?
Replies: 1
Views: 3888

Normally applets cannot write to files on the client's computer due to security reasons, but signing the applet may work.

http://java.sun.com/sfaq/#read

Once you have access to write files, you could use ChartUtilities.saveChartAsJPEG or saveChartAsPNG.
by hongping
Mon Aug 16, 2004 5:13 pm
Forum: JFreeChart - Stockmarket
Topic: scalability issues with server side chart generation
Replies: 4
Views: 10188

scalability issues with server side chart generation

Hi, I posted a similar thread on the general forum, but realized that stockmarket charting may actually be more likely to face the issues I am encountering. I am currently developing a web application that displays statistics of computers such as cpu and memory usage. The web application runs on a s...
by hongping
Mon Aug 16, 2004 4:48 pm
Forum: JFreeChart
Topic: server side pre-generation and caching of charts
Replies: 0
Views: 828

server side pre-generation and caching of charts

Hi, I am currently developing a web application that displays statistics of computers such as cpu and memory usage. The web application runs on a server, and provides stats about many other computers by getting the information from a database. Users of the web app can choose to view the stats at dif...
by hongping
Wed Aug 11, 2004 6:06 pm
Forum: JFreeChart
Topic: order of series in the legend.
Replies: 6
Views: 3981

I found out that it can be done using the setRenderingOrder method of the StandardLengend class, which takes in an object of class org.jfree.chart.LegendRenderingOrder and you can use that to specify standard or reverse order of the legend.
by hongping
Tue Aug 10, 2004 6:38 pm
Forum: JFreeChart
Topic: order of series in the legend.
Replies: 6
Views: 3981

order of series in the legend.

Currently when I use the StackedXYAreaChart, the area first series is displayed at the bottom of the chart, and the legend also shows the chart color of the first series on the left most position. Eg. Chart: C B A Legend: A B C Is there a way to make it such that the legned will start showing series...
by hongping
Tue Aug 10, 2004 6:33 pm
Forum: JFreeChart
Topic: StackedXYAreaRenderer + TimeSeriesCollection => Exception
Replies: 9
Views: 6772

You could try using
org.jfree.data.time.TimeTableXYDataset

which implements the XYTable interface.

TimeTableXYDataset allows you to use org.jfree.data.time.RegularTimePeriod, which has Week and Year and other periods as its subclasses.

Hope this helps.