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


PHP BarPlot::SetCSIMTargets方法代码示例

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


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

示例1: iterationSummaryAux

 public function iterationSummaryAux($id)
 {
     JpGraph\JpGraph::load();
     JpGraph\JpGraph::module('bar');
     $datay = array(12, 26, 9, 17, 31);
     // Create the graph.
     // One minute timeout for the cached image
     // INLINE_NO means don't stream it back to the browser.
     $graph = new Graph(310, 250, 'auto');
     $graph->SetScale("textlin");
     $graph->img->SetMargin(60, 30, 20, 40);
     $graph->yaxis->SetTitleMargin(45);
     $graph->yaxis->scale->SetGrace(30);
     $graph->SetShadow();
     // Turn the tickmarks
     $graph->xaxis->SetTickSide(SIDE_DOWN);
     $graph->yaxis->SetTickSide(SIDE_LEFT);
     // Create a bar pot
     $bplot = new BarPlot($datay);
     // Create targets for the image maps. One for each column
     $targ = array("bar_clsmex1.php#1", "bar_clsmex1.php#2", "bar_clsmex1.php#3", "bar_clsmex1.php#4", "bar_clsmex1.php#5", "bar_clsmex1.php#6");
     $alts = array("val=%d", "val=%d", "val=%d", "val=%d", "val=%d", "val=%d");
     $bplot->SetCSIMTargets($targ, $alts);
     $bplot->SetFillColor("orange");
     // Use a shadow on the bar graphs (just use the default settings)
     $bplot->SetShadow();
     $bplot->value->SetFormat(" \$ %2.1f", 70);
     $bplot->value->SetFont(FF_ARIAL, FS_NORMAL, 9);
     $bplot->value->SetColor("blue");
     $bplot->value->Show();
     $graph->Add($bplot);
     $graph->title->Set("Image maps barex1");
     $graph->xaxis->title->Set("X-title");
     $graph->yaxis->title->Set("Y-title");
     $graph->title->SetFont(FF_FONT1, FS_BOLD);
     $graph->yaxis->title->SetFont(FF_FONT1, FS_BOLD);
     $graph->xaxis->title->SetFont(FF_FONT1, FS_BOLD);
     // Send back the HTML page which will call this script again
     // to retrieve the image.
     $graph->StrokeCSIM();
 }
开发者ID:josimarjimenez,项目名称:architects,代码行数:41,代码来源:GraphicsController.php

示例2: BarPlot

$graph->yaxis->SetLabelAlign('center','top');

// Create the bar plots with image maps
$b1plot = new BarPlot($data1y);
$b1plot->SetFillColor("orange");
$targ=array("bar_clsmex2.php#1","bar_clsmex2.php#2","bar_clsmex2.php#3",
            "bar_clsmex2.php#4","bar_clsmex2.php#5","bar_clsmex2.php#6");
$alts=array("val=%d","val=%d","val=%d","val=%d","val=%d","val=%d");
$b1plot->SetCSIMTargets($targ,$alts);

$b2plot = new BarPlot($data2y);
$b2plot->SetFillColor("blue");
$targ=array("bar_clsmex2.php#7","bar_clsmex2.php#8","bar_clsmex2.php#9",
            "bar_clsmex2.php#10","bar_clsmex2.php#11","bar_clsmex2.php#12");
$alts=array("val=%d","val=%d","val=%d","val=%d","val=%d","val=%d");
$b2plot->SetCSIMTargets($targ,$alts);

// Create the accumulated bar plot
$abplot = new AccBarPlot(array($b1plot,$b2plot));
$abplot->SetShadow();

// We want to display the value of each bar at the top
$abplot->value->Show();
$abplot->value->SetFont(FF_FONT1,FS_NORMAL);
$abplot->value->SetAlign('left','center');
$abplot->value->SetColor("black","darkred");
$abplot->value->SetFormat('%.1f mkr');

// ...and add it to the graph
$graph->Add($abplot);
开发者ID:rcroxyosox,项目名称:jobtracker,代码行数:30,代码来源:bar_csimex3.php

示例3: Graph

$graph = new Graph(400, 250);
$graph->SetScale('textlin');
$graph->SetMargin(50, 80, 20, 40);
// Create a bar pot
$bplot = new BarPlot($datay);
$n = count($datay);
// Number of bars
global $_wrapperfilename;
// Create targets for the image maps. One for each column
$targ = array();
$alt = array();
$wtarg = array();
for ($i = 0; $i < $n; ++$i) {
    $urlarg = 'clickedon=' . ($i + 1);
    $targ[] = $_wrapperfilename . '?' . $urlarg;
    $alt[] = 'val=%d';
    $wtarg[] = '';
}
$bplot->SetCSIMTargets($targ, $alt, $wtarg);
$graph->Add($bplot);
$graph->title->Set('Multiple Image maps');
$graph->title->SetFont(FF_FONT1, FS_BOLD);
$graph->title->SetCSIMTarget('#45', 'Title for Bar', '_blank');
$graph->yaxis->title->SetFont(FF_FONT1, FS_BOLD);
$graph->yaxis->title->SetCSIMTarget('#55', 'Y-axis title');
$graph->yaxis->title->Set("Y-title");
$graph->xaxis->title->SetFont(FF_FONT1, FS_BOLD);
$graph->xaxis->title->SetCSIMTarget('#55', 'X-axis title');
$graph->xaxis->title->Set("X-title");
// Send back the image when we are called from within the <img> tag
$graph->StrokeCSIMImage();
开发者ID:Lazaro-Gallo,项目名称:psmn,代码行数:31,代码来源:csim_in_html_graph_ex1.php

示例4: array

            $numDatas++;
        }
        if ($currentCategoryId != 'none') {
            $targets[$currentCategoryId][] = "javascript:reachThroughTimespan('" . $beginDates[$currentKey]->getFormatted() . "', '" . $endDates[$currentKey]->getFormatted() . "', '{$currentCategoryId}');";
        } else {
            $targets[$currentCategoryId][] = '';
        }
    }
}
$colorIndex = 0;
$bars = array();
foreach ($labels as $currentCategoryId => $currentLabel) {
    $bar = new BarPlot($data[$currentCategoryId]);
    $bar->SetFillColor($chartColors[$colorIndex % count($chartColors)]);
    $bar->SetLegend($labels[$currentCategoryId]);
    $bar->SetCSIMTargets($targets[$currentCategoryId], $dataNames[$currentCategoryId]);
    $bars[] = $bar;
    $colorIndex++;
}
$groupBar = new GroupBarPlot($bars);
$graph->add($groupBar);
$graph->xaxis->SetTickLabels($tickLabels);
$graph->xaxis->SetFont(FF_VERA, FS_BOLD);
$graph->xaxis->SetColor('black', 'green');
$interval = $numDatas / MAX_LABELS;
if ($interval < 1) {
    $interval = 1;
}
//echo "numDatas: $numDatas; interval: $interval";
$graph->xaxis->SetTextLabelInterval($interval);
$graph->yaxis->SetFont(FF_VERA);
开发者ID:BackupTheBerlios,项目名称:badger-svn,代码行数:31,代码来源:timespan.php


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