/
var
/
www
/
doncode.com.ua
/
www
/
obmen
/
include
/
jpgraph
/
/var/www/doncode.com.ua/www/obmen/include/jpgraph
mkdir
upload
Name
Size
Mode
Actions
lang/
-
0775
rm
CHANGELOG
89389
0664
edit
dl
rm
flags.dat
982587
0664
edit
dl
rm
flags_thumb35x35.dat
214310
0664
edit
dl
rm
flags_thumb60x60.dat
375469
0664
edit
dl
rm
flags_thumb100x100.dat
687530
0664
edit
dl
rm
gd_image.inc.php
68914
0664
edit
dl
rm
imgdata_balls.inc.php
53731
0664
edit
dl
rm
imgdata_bevels.inc.php
4500
0664
edit
dl
rm
imgdata_diamonds.inc.php
8329
0664
edit
dl
rm
imgdata_pushpins.inc.php
27889
0664
edit
dl
rm
imgdata_squares.inc.php
6733
0664
edit
dl
rm
imgdata_stars.inc.php
6578
0664
edit
dl
rm
jpg-config.inc.php
9243
0664
edit
dl
rm
jpgraph.php
185282
0664
edit
dl
rm
jpgraph_antispam-digits.php
11963
0664
edit
dl
rm
jpgraph_antispam.php
39948
0664
edit
dl
rm
jpgraph_bar.php
30740
0664
edit
dl
rm
jpgraph_canvas.php
3071
0664
edit
dl
rm
jpgraph_canvtools.php
14000
0664
edit
dl
rm
jpgraph_date.php
16501
0664
edit
dl
rm
jpgraph_errhandler.inc.php
7518
0664
edit
dl
rm
jpgraph_error.php
4360
0664
edit
dl
rm
jpgraph_flags.php
12801
0664
edit
dl
rm
jpgraph_gantt.php
130736
0664
edit
dl
rm
jpgraph_gb2312.php
120006
0664
edit
dl
rm
jpgraph_gradient.php
12975
0664
edit
dl
rm
jpgraph_iconplot.php
5333
0664
edit
dl
rm
jpgraph_imgtrans.php
7319
0664
edit
dl
rm
jpgraph_led.php
10655
0664
edit
dl
rm
jpgraph_line.php
17806
0664
edit
dl
rm
jpgraph_log.php
8542
0664
edit
dl
rm
jpgraph_mgraph.php
11890
0664
edit
dl
rm
jpgraph_pie.php
40020
0664
edit
dl
rm
jpgraph_pie3d.php
25728
0664
edit
dl
rm
jpgraph_plotband.php
18461
0664
edit
dl
rm
jpgraph_plotmark.inc.php
14262
0664
edit
dl
rm
jpgraph_polar.php
23007
0664
edit
dl
rm
jpgraph_radar.php
19682
0664
edit
dl
rm
jpgraph_regstat.php
5668
0664
edit
dl
rm
jpgraph_scatter.php
6603
0664
edit
dl
rm
jpgraph_stock.php
5060
0664
edit
dl
rm
jpgraph_ttf.inc.php
10971
0664
edit
dl
rm
jpgraph_utils.inc.php
15633
0664
edit
dl
rm
Edit:
/var/www/doncode.com.ua/www/obmen/include/jpgraph/jpgraph_error.php
(4360B)
<?php /*======================================================================= // File: JPGRAPH_ERROR.PHP // Description: Error plot extension for JpGraph // Created: 2001-01-08 // Ver: $Id: jpgraph_error.php 782 2006-10-08 08:09:02Z ljp $ // // Copyright (c) Aditus Consulting. All rights reserved. //======================================================================== */ //=================================================== // CLASS ErrorPlot // Description: Error plot with min/max value for // each datapoint //=================================================== class ErrorPlot extends Plot { var $errwidth=2; //--------------- // CONSTRUCTOR function ErrorPlot(&$datay,$datax=false) { $this->Plot($datay,$datax); $this->numpoints /= 2; } //--------------- // PUBLIC METHODS // Gets called before any axis are stroked function PreStrokeAdjust(&$graph) { if( $this->center ) { $a=0.5; $b=0.5; ++$this->numpoints; } else { $a=0; $b=0; } $graph->xaxis->scale->ticks->SetXLabelOffset($a); $graph->SetTextScaleOff($b); //$graph->xaxis->scale->ticks->SupressMinorTickMarks(); } // Method description function Stroke(&$img,&$xscale,&$yscale) { $numpoints=count($this->coords[0])/2; $img->SetColor($this->color); $img->SetLineWeight($this->weight); if( isset($this->coords[1]) ) { if( count($this->coords[1])!=$numpoints ) JpGraphError::RaiseL(2003,count($this->coords[1]),$numpoints); //("Number of X and Y points are not equal. Number of X-points:".count($this->coords[1])." Number of Y-points:$numpoints"); else $exist_x = true; } else $exist_x = false; for( $i=0; $i<$numpoints; ++$i) { if( $exist_x ) $x=$this->coords[1][$i]; else $x=$i; if( !is_numeric($x) || !is_numeric($this->coords[0][$i*2]) || !is_numeric($this->coords[0][$i*2+1]) ) { continue; } $xt = $xscale->Translate($x); $yt1 = $yscale->Translate($this->coords[0][$i*2]); $yt2 = $yscale->Translate($this->coords[0][$i*2+1]); $img->Line($xt,$yt1,$xt,$yt2); $img->Line($xt-$this->errwidth,$yt1,$xt+$this->errwidth,$yt1); $img->Line($xt-$this->errwidth,$yt2,$xt+$this->errwidth,$yt2); } return true; } } // Class //=================================================== // CLASS ErrorLinePlot // Description: Combine a line and error plot // THIS IS A DEPRECATED PLOT TYPE JUST KEPT FOR // BACKWARD COMPATIBILITY //=================================================== class ErrorLinePlot extends ErrorPlot { var $line=null; //--------------- // CONSTRUCTOR function ErrorLinePlot(&$datay,$datax=false) { $this->ErrorPlot($datay,$datax); // Calculate line coordinates as the average of the error limits $n = count($datay); for($i=0; $i < $n; $i+=2 ) { $ly[]=($datay[$i]+$datay[$i+1])/2; } $this->line=new LinePlot($ly,$datax); } //--------------- // PUBLIC METHODS function Legend(&$graph) { if( $this->legend != "" ) $graph->legend->Add($this->legend,$this->color); $this->line->Legend($graph); } function Stroke(&$img,&$xscale,&$yscale) { parent::Stroke($img,$xscale,$yscale); $this->line->Stroke($img,$xscale,$yscale); } } // Class //=================================================== // CLASS LineErrorPlot // Description: Combine a line and error plot //=================================================== class LineErrorPlot extends ErrorPlot { var $line=null; //--------------- // CONSTRUCTOR // Data is (val, errdeltamin, errdeltamax) function LineErrorPlot(&$datay,$datax=false) { $ly=array(); $ey=array(); $n = count($datay); if( $n % 3 != 0 ) { JpGraphError::RaiseL(4002); //('Error in input data to LineErrorPlot. Number of data points must be a multiple of 3'); } for($i=0; $i < $n; $i+=3 ) { $ly[]=$datay[$i]; $ey[]=$datay[$i]+$datay[$i+1]; $ey[]=$datay[$i]+$datay[$i+2]; } $this->ErrorPlot($ey,$datax); $this->line=new LinePlot($ly,$datax); } //--------------- // PUBLIC METHODS function Legend(&$graph) { if( $this->legend != "" ) $graph->legend->Add($this->legend,$this->color); $this->line->Legend($graph); } function Stroke(&$img,&$xscale,&$yscale) { parent::Stroke($img,$xscale,$yscale); $this->line->Stroke($img,$xscale,$yscale); } } // Class /* EOF */ ?>
Save
cmd:
run