| GD :: ±×·¡ÇÁ :: µ¥ÀÌÅÍ GD :: GRAPH :: DATA´Â GD :: ±×·¡ÇÁ¿¡ ´ëÇÑ µ¥ÀÌÅÍ ¼¼Æ® ĸ½¶È¸¦ Æ÷ÇÔÇÏ´Â Perl ¸ðµâÀÔ´Ï´Ù. |
Áö±Ý ´Ù¿î·Îµå |
GD :: ±×·¡ÇÁ :: µ¥ÀÌÅÍ ¼øÀ§ ¹× ¿ä¾à
- ƯÇã:
- Perl Artistic License
- °Ô½ÃÀÚ À̸§:
- Martien Verbruggen
- °Ô½ÃÀÚ À¥»çÀÌÆ®:
- http://search.cpan.org/~bwarfield/GDGraph-1.44/Graph/Data.pm
GD :: ±×·¡ÇÁ :: µ¥ÀÌÅÍ Å±×
GD :: ±×·¡ÇÁ :: µ¥ÀÌÅÍ ¼³¸í
GD :: GRAPH :: µ¥ÀÌÅÍ´Â GD :: ±×·¡ÇÁ¿¡ ´ëÇÑ µ¥ÀÌÅÍ ¼¼Æ® ĸ½¶È¸¦ Æ÷ÇÔÇÏ´Â Perl ¸ðµâÀÔ´Ï´Ù. GD :: Graph :: µ¥ÀÌÅÍ´Â GD :: GraphÀÇ µ¥ÀÌÅÍ ¼¼Æ® ĸ½¶È¸¦ Æ÷ÇÔÇÏ´Â Perl ¸ðµâÀÔ´Ï´Ù.ÀÌ ¸ðµâÀº GD :: ±×·¡ÇÁ ¹× Ä£±¸µé¿¡ ÇÊ¿äÇÑ µ¥ÀÌÅÍ ±¸Á¶¸¦ ĸ½¶ÈÇÕ´Ï´Ù. ÀÌ Å¬·¡½ºÀÇ °´Ã¼¿¡´Â X °ª ¸ñ·Ï°ú ÇØ´ç Y °ªÀÇ ¸ñ·ÏÀÌ Æ÷ÇԵ˴ϴÙ. ÀÌ°ÍÀº y °ªÀÌ ¼ýÀÚ ÀÎ °æ¿ì¿¡¸¸ Àǹ̰¡ ÀÖÁö¸¸ ±âº»ÀûÀ¸·Î ¾Æ¹« °Íµµ ÀúÀåÇÒ ¼ö ÀÖ½À´Ï´Ù. Á¤ÀǵÇÁö ¾ÊÀº °ªÀº GD :: ±×·¡ÇÁ¿¡ Ưº°ÇÑ Àǹ̰¡ ÀÖÀ¸¹Ç·Î Stored.ModeÀÇ ¸Þ¼µåÀÇ ¸ÞÀÌÀú°¡ GD :: ±×·¡ÇÁ¿Í ¸ðµâ ÀÚü°¡ ³»ºÎÀûÀ¸·Î »ç¿ëÇϱâÀ§ÇÑ °ÍÀ̸ç À¯¿ëÇÏÁö ¾ÊÀ» °ÍÀÔ´Ï´Ù. ³Ê¿¡°Ô. ¸¹Àº »ç¶÷µéÀÌ ´ç½Å¿¡°Ô À¯¿ëÇÏÁö´Â ¾Ê¾ÆµµµË´Ï´Ù ... ¿¹Á¦ GD :: ±×·¡ÇÁ :: µ¥ÀÌÅÍ; GD :: ±×·¡ÇÁ :: ¹Ù; ³» $ data = gd :: graph :: data-> new (); $ data-> read (file => '/data/sales.dat', delimiter => ','); $ data = $ data-> copy (wriend => ); # µ¥ÀÌÅͺ£À̽º »ç¿ë DBI¸¦ »ç¿ëÇÏ¿© »õ·Î¿î ¼öÄ¡¸¦ Ãß°¡ÇϽʽÿÀ. # µ¥ÀÌÅͺ£À̽º¿¡ ¿¬°áÇÏ´Â °Í°ú °°Àº DBI ÀÛ¾÷, ¸í·É¹® Áغñ ¹× ½ÇÇà (@row = $ sth-> fetchrow_array) {$ data-> add_point (@ row); } ³» $ chart = gd :: graph :: bars-> new (); MY $ GD = $ CHART-> ÇÃ·Ô ($ µ¥ÀÌÅÍ); ¶Ç´Â ·¹°Å½Ã ÄÚµå # ·¹°Å½Ã Äڵ带 ½Å¼ÓÇÏ°Ô º¯°æÇÏ·Á¸éÀÌ @DATA = (, , , ; # ±×¸®°í ¿ì¸®´Â ³» $ data = gd :: graph :: data-> new ()¿¡ ´ëÇÑ ¾à°£ÀÇ Á¶ÀÛÀ»ÇؾßÇÕ´Ï´Ù. $ data-> copy_from (@Data); # ±×¸®°í Áö±ÝÀº ¿øÇÏ´Â »õ·Î¿î ¹°°ÇÀ» ¸ðµÎ ¼öÇàÇϽʽÿÀ. while (@foo = bar_baz ()) {$ data-> add_point (@Foo); } ¿ä±¸ »çÇ× : ¡¤ Perl.
GD :: ±×·¡ÇÁ :: µ¥ÀÌÅÍ °ü·Ã ¼ÒÇÁÆ®¿þ¾î