Fellow Monks:
I'm attempting to use the
Chart::Plot::Annotated module to implement a graph with annotated data points. Obviously if all was going well I wouldn't be asking for your help!!
I can't get the darn thing to run!! The module as it sits on CPAN errors out with the following when trying to use it:
Bareword "Chart::Plot::Annotated::_DataPt" not allowed while "strict s
+ubs" in use at Annotated.pm line 14.
BEGIN not safe after errors--compilation aborted at Annotated.pm line
+131.
And I believe it has something to do with the implementation of the following code:
package Chart::Plot::Annotated;
use 5.006;
use strict;
use warnings;
use Carp;
our $VERSION = '0.01';
##################################################################
# define this class:
use base 'Chart::Plot';
use Class::MethodMaker
# the extra data well put into the Chart::Plot object
object_list => [ Chart::Plot::Annotated::_DataPt => '_AnnoData' ],
# formatting internals
get_set => [ qw [ _anno_xOffset _anno_yOffset _anno_font _anno_color
+ ] ],
# error-reporting
get_set => [ '_problem' ];
I've attempted to repair the module. I encapsulated the problematic "bareword" in single quotes which allowed it to run cleanly at first, but upon attempting to instantiate a new object using it it returns the following error:
Can't locate object method "new" via package "Chart::Plot::Annotated::_DataPt" (perhaps you forgot to load "Chart::Plot::Annotated::_DataPt"?) at /usr/local/lib/perl5/site_perl/5.8.6/Chart/Plot/Annotated.pm line 48.
I've attempted a few other things to try to fix it but to no avail. I don't have the necessary knowledge of this level of OO programming and subclasses to understand is wrong!!!
Can someone please help??
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.