Finance::YahooChart - Get a chart from Yahoo! Finance


Finance-YahooChart documentation  | view source Contained in the Finance-YahooChart distribution.

Index


NAME

Top

Finance::YahooChart - Get a chart from Yahoo! Finance

SYNOPSIS

Top

  use Finance::YahooChart;
  %img = getchart(symbol => $symbol, size => $size, type => $type,
		  include => $include);
  print "<IMG SRC=$img{'url'} WIDTH=$img{'width'} HEIGHT=$img{'height'}>";

DESCRIPTION

Top

This module gets charts from Yahoo! Finance. The only function in the module is the getchart function, which takes the stock symbol, size of the chart (b for big, s for small), the type of chart (i for intraday, w for week, 3 for 3-month, 1 for 1-year, 2 for 2-year, and 5 for 5-year), and any extra information to include (s for a comparison to the S&P 500, m for a moving average). It returns a hash with the following elements:

  'url' => The URL of the chart
  'width' => The width of the chart
  'height' => The height of the chart

Note that not all combinations are available for all charts.

Big charts are available for all types.

Small charts are only available for i, w, and 1 charts.

Includes are only available for big 3, 1, 2, and 5 charts.

In most cases, if an invalid configuration is passed, $Finance::YahooChart::Error will be set to some kind of error message.

COPYRIGHT

Top

AUTHOR

Top

Dj Padzensky (djpadz@padz.net), PadzNet, Inc.

The Finance::YahooChart home page can be found at http://www.padz.net/~djpadz/YahooChart/


Finance-YahooChart documentation  | view source Contained in the Finance-YahooChart distribution.