当前位置: 首页>>代码示例>>PHP>>正文


PHP ScatterPlot::SetImpuls方法代码示例

本文整理汇总了PHP中ScatterPlot::SetImpuls方法的典型用法代码示例。如果您正苦于以下问题:PHP ScatterPlot::SetImpuls方法的具体用法?PHP ScatterPlot::SetImpuls怎么用?PHP ScatterPlot::SetImpuls使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在ScatterPlot的用法示例。


在下文中一共展示了ScatterPlot::SetImpuls方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: Graph

    }
    //===========
    $graph = new Graph(750, 450);
    $graph->img->SetMargin(40, 40, 40, 80);
    $graph->img->SetAntiAliasing();
    $graph->SetScale("textlin");
    $graph->SetShadow();
    $graph->title->Set(strtoupper($pabrik) . "  FFA " . $periode);
    $graph->title->SetFont(FF_DEFAULT, FS_NORMAL, 14);
    $graph->xaxis->SetFont(FF_DEFAULT, FS_NORMAL, 11);
    $graph->xaxis->SetTickLabels($labels);
    $graph->xaxis->SetLabelAngle(45);
    $p1 = new ScatterPlot($datay1);
    $p2 = new ScatterPlot($datay2);
    $p1->SetLegend('CPO');
    $p2->SetLegend('Kernel');
    $graph->legend->Pos(0.02, 0.03);
    $p1->mark->SetType(MARK_SQUARE);
    $p1->SetImpuls();
    $p1->mark->SetFillColor("red");
    $p1->mark->SetWidth(4);
    $p1->SetColor("blue");
    $p2->mark->SetType(MARK_FILLEDCIRCLE);
    $p2->SetImpuls();
    $p2->mark->SetFillColor("orange");
    $p2->mark->SetWidth(4);
    $p2->SetColor("black");
    $p1->SetCenter();
    $graph->Add(array($p1, $p2));
    $graph->Stroke();
}
开发者ID:halimc17,项目名称:magsys,代码行数:31,代码来源:pabrik_slave_grafikProduksiFfa.php

示例2: sprintf

{
    return sprintf("%02.2f", $l);
}
// Setup the basic parameters for the graph
$graph = new Graph(400, 200);
$graph->SetScale("intlin");
$graph->SetShadow();
$graph->SetBox();
$graph->title->Set("Impuls Example 3");
$graph->title->SetFont(FF_FONT1, FS_BOLD);
// Set format callback for labels
$graph->yaxis->SetLabelFormatCallback("mycallback");
// Set X-axis at the minimum value of Y-axis (default will be at 0)
$graph->xaxis->SetPos("min");
// "min" will position the x-axis at the minimum value of the Y-axis
// Extend the margin for the labels on the Y-axis and reverse the direction
// of the ticks on the Y-axis
$graph->yaxis->SetLabelMargin(12);
$graph->xaxis->SetLabelMargin(6);
$graph->yaxis->SetTickSide(SIDE_LEFT);
$graph->xaxis->SetTickSide(SIDE_DOWN);
// Create a new impuls type scatter plot
$sp1 = new ScatterPlot($datay);
$sp1->mark->SetType(MARK_SQUARE);
$sp1->mark->SetFillColor("red");
$sp1->SetImpuls();
$sp1->SetColor("blue");
$sp1->SetWeight(1);
$sp1->mark->SetWidth(3);
$graph->Add($sp1);
$graph->Stroke();
开发者ID:hcvcastro,项目名称:pxp,代码行数:31,代码来源:impulsex3.php

示例3: addPlot

 /**
  * add plot to graph
  * @param string $pType plot types self::PT_*
  * @param array $pOptions plot options
  * @param boolean $pAdd if false, return plot instead of adding to graph
  * @return object plot, if not rendered directly
  */
 public function addPlot($pType = self::PT_LINE, $pOptions = array(), $pAdd = true)
 {
     $file = self::$JPGRAPH_DIR . \DIRECTORY_SEPARATOR . self::$GRAPH_FILES[self::$GRAPH_TYPES[$pType]];
     if (\file_exists($file)) {
         require_once $file;
     }
     if (!(count($this->dataX) > 0)) {
         $this->dataX = false;
     }
     switch ($pType) {
         case self::PT_LINE:
             $plot = new \LinePlot($this->dataY, $this->dataX);
             break;
         case self::PT_AREA:
             $plot = new \LinePlot($this->dataY, $this->dataX);
             if (\array_key_exists('color', $pOptions)) {
                 $plot->SetFillColor($pOptions['color']);
             }
             break;
         case self::PT_BAR:
             $plot = new \BarPlot($this->dataY, $this->dataX);
             break;
         case self::PT_ERROR:
             $plot = new \ErrorPlot($this->dataY, $this->dataY);
             break;
         case self::PT_FIELD:
             $plot = new \FieldPlot($this->dataY, $this->dataX);
             break;
         case self::PT_STOCK:
             $plot = new \StockPlot($this->dataY, $this->dataX);
             break;
         case self::PT_SCATTER:
             $plot = new \ScatterPlot($this->dataY, $this->dataX);
             break;
         case self::PT_BALLOON:
             $plot = new \ScatterPlot($this->dataY, $this->dataX);
             break;
         case self::PT_IMPULS:
             $plot = new \ScatterPlot($this->dataY, $this->dataX);
             $plot->SetImpuls();
             break;
         case self::PT_PIE:
             $this->graph = new \PieGraph(self::$WIDTH, self::$HEIGHT);
             $plot = new \PiePlot($this->data);
             break;
     }
     if ($pAdd) {
         $this->plots[] = $plot;
         $this->graph->Add($plot);
     } else {
         return $plot;
     }
 }
开发者ID:Broncko,项目名称:Savant,代码行数:60,代码来源:CJpGraph.php


注:本文中的ScatterPlot::SetImpuls方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。