Skip to content

LinePlot

ClassChartGuruChartGuru
[Serializable]
public class LinePlot : ChartMark, IChartMark

A vectorized line plot that renders a mathematical function. Swift Charts equivalent: LinePlot(x: “x”, y: .linearFunction(intercept: 0, slope: 1))

Unlike LineMark which requires explicit data points, LinePlot samples a function over a domain to generate a smooth curve.

public override ChartType MarkType { get; }

No description is available for this member.

Returns

ChartGuru.ChartType — No return description is available.

public Func<float, float> Function { get; set; }

The function to plot: y = f(x)

Returns

System.Func{System.Single,System.Single} — No return description is available.

public float DomainMin { get; set; }

Minimum X value for sampling.

Returns

System.Single — No return description is available.

public float DomainMax { get; set; }

Maximum X value for sampling.

Returns

System.Single — No return description is available.

public int SampleCount { get; set; }

Number of sample points to generate. Higher values produce smoother curves.

Returns

System.Int32 — No return description is available.

public InterpolationMethod Interpolation { get; set; }

No description is available for this member.

Returns

ChartGuru.InterpolationMethod — No return description is available.

public float LineWidth { get; set; }

No description is available for this member.

Returns

System.Single — No return description is available.

public bool ShowPoints { get; set; }

No description is available for this member.

Returns

System.Boolean — No return description is available.

public SymbolShape PointSymbol { get; set; }

No description is available for this member.

Returns

ChartGuru.SymbolShape — No return description is available.

public float PointSize { get; set; }

No description is available for this member.

Returns

System.Single — No return description is available.

LinePlot(Func<float, float>, float, float)

Section titled “LinePlot(Func<float, float>, float, float)”
public LinePlot(Func<float, float> function, float domainMin = 0, float domainMax = 1)

Creates a LinePlot with a function and domain.

Parameters

Name Type Description
function System.Func{System.Single,System.Single}
domainMin System.Single
domainMax System.Single

LinearFunction(float, float, float, float)

Section titled “LinearFunction(float, float, float, float)”
public static LinePlot LinearFunction(float intercept, float slope, float domainMin = 0, float domainMax = 1)

Creates a linear function plot: y = slope * x + intercept Swift Charts equivalent: LinePlot(x: “x”, y: .linearFunction(intercept:slope:))

Parameters

Name Type Description
intercept System.Single
slope System.Single
domainMin System.Single
domainMax System.Single

Returns

ChartGuru.LinePlot — No return description is available.

QuadraticFunction(float, float, float, float, float)

Section titled “QuadraticFunction(float, float, float, float, float)”
public static LinePlot QuadraticFunction(float a, float b, float c, float domainMin = 0, float domainMax = 1)

Creates a quadratic function plot: y = ax² + bx + c

Parameters

Name Type Description
a System.Single
b System.Single
c System.Single
domainMin System.Single
domainMax System.Single

Returns

ChartGuru.LinePlot — No return description is available.

SineWave(float, float, float, float, float)

Section titled “SineWave(float, float, float, float, float)”
public static LinePlot SineWave(float amplitude = 1, float frequency = 1, float phase = 0, float domainMin = 0, float domainMax = 6.28)

Creates a sine wave plot.

Parameters

Name Type Description
amplitude System.Single
frequency System.Single
phase System.Single
domainMin System.Single
domainMax System.Single

Returns

ChartGuru.LinePlot — No return description is available.

CosineWave(float, float, float, float, float)

Section titled “CosineWave(float, float, float, float, float)”
public static LinePlot CosineWave(float amplitude = 1, float frequency = 1, float phase = 0, float domainMin = 0, float domainMax = 6.28)

Creates a cosine wave plot.

Parameters

Name Type Description
amplitude System.Single
frequency System.Single
phase System.Single
domainMin System.Single
domainMax System.Single

Returns

ChartGuru.LinePlot — No return description is available.

ExponentialFunction(float, float, float, float)

Section titled “ExponentialFunction(float, float, float, float)”
public static LinePlot ExponentialFunction(float a = 1, float b = 1, float domainMin = 0, float domainMax = 2)

Creates an exponential function plot: y = a * e^(b*x)

Parameters

Name Type Description
a System.Single
b System.Single
domainMin System.Single
domainMax System.Single

Returns

ChartGuru.LinePlot — No return description is available.

LogarithmicFunction(float, float, float, float)

Section titled “LogarithmicFunction(float, float, float, float)”
public static LinePlot LogarithmicFunction(float a = 1, float b = 0, float domainMin = 0.1, float domainMax = 10)

Creates a logarithmic function plot: y = a * ln(x) + b

Parameters

Name Type Description
a System.Single
b System.Single
domainMin System.Single
domainMax System.Single

Returns

ChartGuru.LinePlot — No return description is available.

public IEnumerable<LineMark> GetSampledMarks()

Samples the function and generates LineMark data points.

Returns

System.Collections.Generic.IEnumerable{ChartGuru.LineMark} — No return description is available.

public IEnumerable<DataPoint> GetSampledPoints()

Gets the sampled data points.

Returns

System.Collections.Generic.IEnumerable{ChartGuru.DataPoint} — No return description is available.

public LinePlot Domain(float min, float max)

Sets the Domain (X range) for sampling.

Parameters

Name Type Description
min System.Single
max System.Single

Returns

ChartGuru.LinePlot — No return description is available.

public LinePlot Samples(int count)

Sets the number of sample points.

Parameters

Name Type Description
count System.Int32

Returns

ChartGuru.LinePlot — No return description is available.

public LinePlot InterpolationMethod(InterpolationMethod method)

Sets the interpolation method.

Parameters

Name Type Description
method ChartGuru.InterpolationMethod

Returns

ChartGuru.LinePlot — No return description is available.

public LinePlot LineStyle(float width)

Sets the line width.

Parameters

Name Type Description
width System.Single

Returns

ChartGuru.LinePlot — No return description is available.

public LinePlot ForegroundStyle(Color color)

Sets the foreground color. Swift Charts equivalent: .ForegroundStyle(color)

Parameters

Name Type Description
color UnityEngine.Color

Returns

ChartGuru.LinePlot — No return description is available.

public LinePlot Symbol(SymbolShape shape, float size = 4)

Shows points at each sample.

Parameters

Name Type Description
shape ChartGuru.SymbolShape
size System.Single

Returns

ChartGuru.LinePlot — No return description is available.

public LinePlot Symbol(SymbolStyle style, float size = 4)

Shows stroked-border points at each sample. Swift Charts equivalent: .Symbol(.circle.StrokeBorder(lineWidth: 2)).

Parameters

Name Type Description
style ChartGuru.SymbolStyle
size System.Single

Returns

ChartGuru.LinePlot — No return description is available.

public override (Vector2 source, Vector2 target) GetMorphTargets(ChartType targetType, Rect plotArea)

No description is available for this member.

Parameters

Name Type Description
targetType ChartGuru.ChartType
plotArea UnityEngine.Rect

Returns

System.ValueTuple{UnityEngine.Vector2,UnityEngine.Vector2} — No return description is available.

public override IChartMark Clone()

No description is available for this member.

Returns

ChartGuru.IChartMark — No return description is available.