for ($i = 0; $i < $n; ++$i) { $txtbox[$i] = new Text($txt[$i]); $txtbox[$i]->SetPos($txtlayout[$i][0], $txtlayout[$i][1], 'right'); $txtbox[$i]->SetWordwrap($txtlayout[$i][2]); $txtbox[$i]->SetParagraphAlign($txtlayout[$i][3]); $txtbox[$i]->SetColor($txtlayout[$i][4]); $txtbox[$i]->SetBox($txtlayout[$i][5]); if (count($txtlayout[$i]) > 6) { $txtbox[$i]->SetFont($txtlayout[$i][6], $txtlayout[$i][7], $txtlayout[$i][8]); } } $graph->Add($txtbox); // Create the windrose plot. $wp = new Plot\WindrosePlot($data); // Set background color for plot area $wp->SetColor('lightyellow'); // Add a box around the plot $wp->SetBox(); // Setup the colors for the ranges $wp->SetRangeColors($rangeColors); // Adjust the font and font color for scale labels $wp->scale->SetFont(FF_ARIAL, FS_NORMAL, 9); $wp->scale->SetFontColor('navy'); // Set the diameter and position for plot $wp->SetSize(190); $wp->SetPos(0.35, 0.53); $wp->SetZCircleSize(0.2); // Adjust the font and font color for compass directions $wp->SetFont(FF_ARIAL, FS_NORMAL, 10); $wp->SetFontColor('darkgreen'); // Adjust the margin to the compass directions