Yahoo stock chart like pic

Discussion about JFreeChart related to stockmarket charts.
Locked
homecurr
Posts: 4
Joined: Tue Apr 20, 2004 4:52 am

Yahoo stock chart like pic

Post by homecurr » Tue Apr 20, 2004 5:00 am

Hi

I want to generate the same chart as Yahoo Finance uses for stock quote. JFreeChart works pretty well. I have just one problem. The margin around the chart is to large and it takes too much of my web page space. How can I change it? The font of the title looks like bold, how can I make it plain?

here is my code:

Thanks,

John

private JFreeChart createTimesChart(String zip, String range) {
XYDataset dataset = createDataset();
JFreeChart chart = ChartFactory.createTimeSeriesChart(
zip,
"",
"",
dataset,
false,
false,
false
);
// chart.setBackgroundPaint(Color.white);
chart.setAntiAlias(true);
return chart;
}

devipriya
Posts: 4
Joined: Mon May 22, 2006 4:53 am

Same requirement.

Post by devipriya » Mon May 22, 2006 7:47 am

Dear John ,
I know this thread is quite old.
But am shooting this message with the confidence that u will look into it soon. John, I am just 6 months experienced and i have the same requirement. I have to draw a dynamic graph (the same graph displayed in finance.yahoo.com) based on changing statistical values. The graph should change in a periodic interval of time say for every 10 minutes but without using refresh option . My inputs will be from Excel, i have to read the values and update in the database or directly retrieve it in a jsp page where i should also incorporate this grpah functionality .
Can u please help me out? Can u please provide me with any sample application and ur code ? It is very urgent. And i am blank without any idea of how to achieve this .
Keeping my fingers crossed.
Thanks in advance.

riteshrav
Posts: 1
Joined: Fri Aug 04, 2006 12:16 pm

Post your code

Post by riteshrav » Fri Aug 04, 2006 12:19 pm

Dear priya,

I have done one application as same as what you have posted here, you just post your code. I will try to solve this problem.

isabella
Posts: 1
Joined: Mon Aug 14, 2006 7:42 am

Re: Post your code

Post by isabella » Thu Aug 24, 2006 11:57 am

Dear shrav,
I have the similar problem with Priya, i have to draw a timeseries chart.The chart have to get the value and time from the database,how can i generate this?
Thanks a lot.

Karthicks
Posts: 20
Joined: Wed Mar 26, 2003 1:29 pm
Location: Chennai , India

Post by Karthicks » Sat Sep 23, 2006 11:19 am

To read data from Excel. You can use any parser search for any parser. I think you can use open office API to parse Excel data. In open office there is option to run open office as server. via remote API you can parse the data.

Then dump the data in DB. and do it.


S.Karthick

Taqua
JFreeReport Project Leader
Posts: 698
Joined: Fri Mar 14, 2003 3:34 pm
Contact:

Post by Taqua » Sat Sep 23, 2006 7:55 pm

Reading Excel-Data can be done using Jakarta POI - its less effort than having to use OpenOffice (their UNO-Stuff is no fun either ..).

If the data is already in a database, things are much easier: Use JDBC to query the data, iterate over the resultset to build your TimeSeries, and display the chart ..

Locked