Behavior Control
This control is developed by:
AvatarDJ Sures
Created
Updated
Help Index

Graphy

How To Download and Use This Control

  1. Make sure you have the latest version of EZ-Builder installed.
  2. Select Download This Control button below to download the file.
  3. Double click the downloaded file to open it.
  4. The installer will automatically add this control to EZ-Builder.
Download This Control

This is the graphy control for creating graphs and plotting data using the ControlCommand() commands.

For example, this code will graph the servo positions of the Six Hexapod...

Code:

ControlCommand("Graphy", RemoveAllSeries)

:loop

$pos = getservo(d0)
ControlCommand("Graphy", AddData, "Servo D0", $pos)

$pos = getservo(d1)
ControlCommand("Graphy", AddData, "Servo D1", $pos)

$pos = getservo(d4)
ControlCommand("Graphy", AddData, "Servo D4", $pos)


sleep(250)

goto(loop)



User-inserted image



Add Data

Code:


ControlCommand("Graphy", AddData, SeriesName, YData)

Example: ControlCommand("Graphy", AddData, "Test Data", $value)

Adds data to the series name. If the series name doesn't exist, a series will be created with the specified name.







Add New Series

Code:


ControlCommand("Graphy", AddSeries, SeriesName, type)

Example: ControlCommand("Graphy", AddSeries, "Test Data", "line")

Adds a series to the chart with the specified name. The series chart type must be one of: Point, FastPoint, Bubble, Line, Spline, StepLine, FastLine, Bar, StackedBar, StackedBar100, Column, StackedColumn, StackedColumn100, Area, SplineArea, StackedArea, StackedArea100, Pie, Doughnut, Stock, Candlestick, Range, SplineRange, RangeBar, RangeColumn, Radar, Polar, ErrorBar, BoxPlot, Renko, ThreeLineBreak, Kagi, PointAndFigure, Funnel, Pyramid. Some types may return an error because they require only 1 series in the chart.







Change Series Type

Code:


ControlCommand("Graphy", ChangeSeriesType, SeriesName, type)

Example: ControlCommand("Graphy", ChangeSeriesType, "Test Data", "line")

Changes the series type of the chart with the specified name. The series chart type must be one of: Point, FastPoint, Bubble, Line, Spline, StepLine, FastLine, Bar, StackedBar, StackedBar100, Column, StackedColumn, StackedColumn100, Area, SplineArea, StackedArea, StackedArea100, Pie, Doughnut, Stock, Candlestick, Range, SplineRange, RangeBar, RangeColumn, Radar, Polar, ErrorBar, BoxPlot, Renko, ThreeLineBreak, Kagi, PointAndFigure, Funnel, Pyramid. Some types may return an error because they require only 1 series in the chart.







Reset All Chart Data

Code:


ControlCommand("Graphy", RemoveAllSeries)

Example: ControlCommand("Graphy", RemoveAllSeries)

Resets all the chart data for all series.







Remove Series Data

Code:


ControlCommand("Graphy", RemoveSeries, SeriesName)

Example: ControlCommand("Graphy", RemoveSeries, "Test Data")

Resets all the chart data for the specified series only.







Show Legend

Code:


ControlCommand("Graphy", ShowLegend, true/false)

Example: ControlCommand("Graphy", ShowLegend, true/false)

Enables/disables the legend. Use this if you require more screen real-estate by removing the legend.