Libraries.Interface.Controls.Charts.LineChartWriter Documentation

The LineChartWriter class is part of the set of writers that allow for Charts to save their representation in the form ScalableVectorGraphics. This class will write out all of the necessary text needed to write out an SVG file that will contain the chart.

Example Code

use Libraries.Compute.Statistics.DataFrame
use Libraries.Interface.Controls.Charts.LineChart
use Libraries.Interface.Controls.Charts.LineChartWriter

DataFrame frame
frame:Load("Data.csv")
frame:SetSelectedColumnRange(0,1)
LineChart chart = frame:LineChart()
chart:SetTitle("My Awesome Title")
chart:SetXAxisTitle("Time")
chart:Display()

LineChartWriter writer
output writer:WriteOutChart(chart)

Inherits from: Libraries.Interface.Controls.Charts.ChartWriter, Libraries.Language.Object

Actions Documentation

AddChartArea(Libraries.Data.Formats.ScalableVectorGraphics.ScalableVectorGraphics canvas, Libraries.Interface.Controls.Charts.Chart chart)

AddLegend(Libraries.Data.Formats.ScalableVectorGraphics.ScalableVectorGraphics canvas, Libraries.Interface.Controls.Charts.Chart chart)

AddOrderingList(Libraries.Data.Formats.ScalableVectorGraphics.ScalableVectorGraphics canvas, Libraries.Interface.Controls.Charts.Chart chart)

AddPatternDefinitions(Libraries.Data.Formats.ScalableVectorGraphics.ScalableVectorGraphics canvas, Libraries.Interface.Controls.Charts.Chart chart)

AddRegressionLines(Libraries.Data.Formats.ScalableVectorGraphics.ScalableVectorGraphics canvas, Libraries.Interface.Controls.Charts.Chart chart)

AddXLabels(Libraries.Data.Formats.ScalableVectorGraphics.ScalableVectorGraphics canvas, Libraries.Interface.Controls.Charts.Chart chart)

AddYLabels(Libraries.Data.Formats.ScalableVectorGraphics.ScalableVectorGraphics canvas, Libraries.Interface.Controls.Charts.Chart chart)

Compare(Libraries.Language.Object object)

This action compares two object hash codes and returns an integer. The result is larger if this hash code is larger than the object passed as a parameter, smaller, or equal. In this case, -1 means smaller, 0 means equal, and 1 means larger. This action was changed in Quorum 7 to return an integer, instead of a CompareResult object, because the previous implementation was causing efficiency issues.

Parameters

Return

integer: The Compare result, Smaller, Equal, or Larger.

Example

Object o
Object t
integer result = o:Compare(t) //1 (larger), 0 (equal), or -1 (smaller)

Equals(Libraries.Language.Object object)

This action determines if two objects are equal based on their hash code values.

Parameters

Return

boolean: True if the hash codes are equal and false if they are not equal.

Example

use Libraries.Language.Object
use Libraries.Language.Types.Text
Object o
Text t
boolean result = o:Equals(t)

GetBackground()

This action sets the background.

Return

Libraries.Data.Formats.ScalableVectorGraphics.Rectangle:

GetChartArea()

This action sets the chart area.

Return

Libraries.Data.Formats.ScalableVectorGraphics.Rectangle:

GetChartAreaHeight()

This action sets the height (percentage) of the chart area.

Return

number:

GetChartAreaPositionX()

add the meta-data character set

Return

number:

GetChartAreaPositionY()

Generate SVG elements for each piece of the chart

Return

number:

GetChartAreaWidth()

This action sets the width (percentage) of the chart area.

Return

number:

GetChartHeight()

This action sets the height (pixel) of the chart.

Return

integer:

GetChartInformation()

This action writes out the Chart by grabbing necessary information from the chart and it will then return all of the necessary text needed to write out an SVG file that will contain the chart.

Return

Libraries.Data.Formats.ScalableVectorGraphics.Group:

Example


    use Libraries.Compute.Statistics.DataFrame
    use Libraries.Interface.Controls.Charts.BarChart
    use Libraries.Interface.Controls.Charts.BarChartWriter
    
    DataFrame frame
    frame:Load("Data.csv")
    frame:SetSelectedColumnRange(0,1)
    BarChart chart = frame:BarChart()
    chart:Display()

    BarChartWriter writer
    output writer:WriteOutChart(chart, 1400, 1200)

GetChartTitle()

This action sets the chart title.

Return

Libraries.Data.Formats.ScalableVectorGraphics.Label:

GetChartWidth()

This action sets the width (pixel) of the chart.

Return

integer: