Re: reliability problem with Finance::QuoteHist::Yahoo



On Jul 14, 6:23 pm, Jim Cochrane <allergic-to-s...@no-spam-
allowed.invalid> wrote:
On 2008-07-14, smallpond <smallp...@xxxxxxxx> wrote:





Ted wrote:
I have been able to get this package to work sometimes.  However,
invariably it fails on me part way through my script, after
downloading data for from one to four ticker symbols.  The error is:

Can't use an undefined value as an ARRAY reference at C:/Perl/site/lib/
Finance/QuoteHist/Generic.pm line 863.

I have no information about how an undefined value is being passed
deep into the code of a package I didn't write.  I took a quick look
into Generic.pm and yahoo.pm, but found no enlightenment so far
(there's a lot of code there).

Sometimes it arises when quotes() is executed, and at other times, it
occurs when dividends() is executed.
...

Without even looking at your code my guess is that Yahoo! is not particularly
pleased about providing an ad-sponsored service to web-scrapers.  Part of the
reason that free services change their page format is to block people from
doing this.  Yahoo! changes their page format fairly frequently and I'm willing
to bet that their web programmers have access to CPAN.  If you need 7000 quotes
then its pretty clearly not for your personal portfolio.  Maybe time for your
company to invest in a quote service.

If you have good software, configured to do intensive filtering, data
for 7000 tradables can be easily managable for an individual trader.
On the other hand, if an individual trader needs a reliable and accurate
data feed for automated analysis, a free yahoo service is probably a
poor choice.

It sounds like the package in question is not as robust as it could be,
allowing the user to encounter a run-time undefined value error instead
of producing a good error message.  However, yahoo changing the server's
behavior or data format seems a likely initial cause of the problem.

--- Hide quoted text -

- Show quoted text -

This project is at its beginning, proof of concept, stage. The plan
was to do an initial test using data from yahoo, and then proceed to
buying a datafeed from a commercial source.

We have had another project downloading a paltry 500 stocks daily for
about a year, without change or problem, but it doesn't get the data
for splits and dividends and it is written in PHP which I have never
used. I'd thought, given the original programmer's tedious task of
manually finding new stocks to add to the download, and the
documentaton for these packages, rewriting in perl would be the path
of least pain. But, it looks like I may have to write my own code to
do what this package does, so at least I can get a sensible error
message.

Cheers,

Ted
.



Relevant Pages

  • RE: How to format a VFAT partition
    ... package. ... how can I format a VFAT partition with Linux? ... Do you Yahoo!? ...
    (RedHat)
  • Re: dclusr trick no longer works with the Turbo Explorers
    ... If it's just a matter of downloading a tweak to be able to install ... any package, don't you think it'll affect sales? ...
    (borland.public.delphi.non-technical)
  • Re: Interesting SFSO CD sales statistics
    ... I'll not claim that downloading classical music is antithetical to the ... First is that the CD format may prove more popular with grayheads - ... such as I - due to our difficulties in easing into newer technologies. ... palpability and reality of collecting records is something that will ...
    (rec.music.classical.recordings)
  • reliability problem with Finance::QuoteHist::Yahoo
    ... I have been able to get this package to work sometimes. ... downloading data for from one to four ticker symbols. ... The script I am using is appended below. ... foreach $row ) { ...
    (comp.lang.perl.misc)
  • Re: yum downloadonly
    ... of only downloading a package once ... What I would like is an option to yum, say localrepo, ... yum will look first to see if the package it wants ... it will download and install it, ...
    (Fedora)