VectSharp 2.6.1
A light library for C# vector graphics
All Classes Namespaces Functions Variables Enumerations Properties Events Pages
VectSharp.Plots.LogarithmicTrendLine Class Reference

A plot element that draws a logarithmic trendline with equation y = a * Ln(x) + b. More...

Inheritance diagram for VectSharp.Plots.LogarithmicTrendLine:

Public Member Functions

 LogarithmicTrendLine (double slope, double intercept, double minX, double minY, double maxX, double maxY, IContinuousCoordinateSystem coordinateSystem)
 Create a new LogarithmicTrendLine instance, specifying the equation parameters. More...
 
 LogarithmicTrendLine (IReadOnlyList< IReadOnlyList< double > > data, IContinuousCoordinateSystem coordinateSystem, double? fixedIntercept=null)
 Create a new LogarithmicTrendLine instance, determining the equation parameters by running a regression. More...
 
 LogarithmicTrendLine (IReadOnlyList<(double, double)> data, IContinuousCoordinateSystem coordinateSystem, double? fixedIntercept=null)
 Create a new LogarithmicTrendLine instance, determining the equation parameters by running a regression. More...
 
void Plot (Graphics target)
 Draw the plot element on the specified target &#160;Graphics.
Parameters
targetThe Graphics on which to draw.
More...
 
void Plot (Graphics target)
 Draw the plot element on the specified target &#160;Graphics. More...
 

Properties

double Slope [get, set]
 The slope of the trendline (a). More...
 
double Intercept [get, set]
 The intercept of the trendline (b). More...
 
double MinX [get, set]
 The minimum X value for which the trendline is plotted. More...
 
double MinY [get, set]
 The minimum Y value for which the trendline is plotted. More...
 
double MaxX [get, set]
 The maximum X value for which the trendline is plotted. More...
 
double MaxY [get, set]
 The maximum Y value for which the trendline is plotted. More...
 
PlotElementPresentationAttributes PresentationAttributes = new PlotElementPresentationAttributes() { LineDash = new LineDash(5, 5, 0), Stroke = Colour.FromRgb(180, 180, 180) } [get, set]
 Presentation attributes for the trendline. More...
 
string Tag [get, set]
 A tag to identify the trendline in the plot. More...
 
IContinuousCoordinateSystem CoordinateSystem [get, set]
 The coordinate system used to transform the points from data space to plot space. More...
 
- Properties inherited from VectSharp.Plots.IPlotElement
ICoordinateSystem CoordinateSystem [get]
 The coordinate system used to transform the points from data space to plot space. More...
 

Detailed Description

A plot element that draws a logarithmic trendline with equation y = a * Ln(x) + b.

Definition at line 474 of file Trendlines.cs.

Constructor & Destructor Documentation

◆ LogarithmicTrendLine() [1/3]

VectSharp.Plots.LogarithmicTrendLine.LogarithmicTrendLine ( double  slope,
double  intercept,
double  minX,
double  minY,
double  maxX,
double  maxY,
IContinuousCoordinateSystem  coordinateSystem 
)

Create a new LogarithmicTrendLine instance, specifying the equation parameters.

Parameters
slopeThe slope of the trendline (a).
interceptThe intercept of the trendline (b).
minXThe minimum X value for which the trendline is plotted.
minYThe minimum Y value for which the trendline is plotted.
maxXThe maximum X value for which the trendline is plotted.
maxYThe maximum Y value for which the trendline is plotted.
coordinateSystemThe coordinate system used to transform the points from data space to plot space.

Definition at line 532 of file Trendlines.cs.

◆ LogarithmicTrendLine() [2/3]

VectSharp.Plots.LogarithmicTrendLine.LogarithmicTrendLine ( IReadOnlyList< IReadOnlyList< double > >  data,
IContinuousCoordinateSystem  coordinateSystem,
double?  fixedIntercept = null 
)

Create a new LogarithmicTrendLine instance, determining the equation parameters by running a regression.

Parameters
dataThe data that will be used to determine the equation parameters.
coordinateSystemThe coordinate system used to transform the points from data space to plot space.
fixedInterceptIf this is null, the intercept (b) is determined during the regression; otherwise, it is fixed to the specified value.

Definition at line 549 of file Trendlines.cs.

◆ LogarithmicTrendLine() [3/3]

VectSharp.Plots.LogarithmicTrendLine.LogarithmicTrendLine ( IReadOnlyList<(double, double)>  data,
IContinuousCoordinateSystem  coordinateSystem,
double?  fixedIntercept = null 
)

Create a new LogarithmicTrendLine instance, determining the equation parameters by running a regression.

Parameters
dataThe data that will be used to determine the equation parameters.
coordinateSystemThe coordinate system used to transform the points from data space to plot space.
fixedInterceptIf this is null, the intercept (b) is determined during the regression; otherwise, it is fixed to the specified value.

Definition at line 596 of file Trendlines.cs.

Member Function Documentation

◆ Plot()

void VectSharp.Plots.LogarithmicTrendLine.Plot ( Graphics  target)

Draw the plot element on the specified target &#160;Graphics.

Parameters
targetThe Graphics on which to draw.

Implements VectSharp.Plots.IPlotElement.

Definition at line 599 of file Trendlines.cs.

Property Documentation

◆ CoordinateSystem

IContinuousCoordinateSystem VectSharp.Plots.LogarithmicTrendLine.CoordinateSystem
getset

The coordinate system used to transform the points from data space to plot space.

Implements VectSharp.Plots.IPlotElement.

Definition at line 519 of file Trendlines.cs.

◆ Intercept

double VectSharp.Plots.LogarithmicTrendLine.Intercept
getset

The intercept of the trendline (b).

Definition at line 484 of file Trendlines.cs.

◆ MaxX

double VectSharp.Plots.LogarithmicTrendLine.MaxX
getset

The maximum X value for which the trendline is plotted.

Definition at line 499 of file Trendlines.cs.

◆ MaxY

double VectSharp.Plots.LogarithmicTrendLine.MaxY
getset

The maximum Y value for which the trendline is plotted.

Definition at line 504 of file Trendlines.cs.

◆ MinX

double VectSharp.Plots.LogarithmicTrendLine.MinX
getset

The minimum X value for which the trendline is plotted.

Definition at line 489 of file Trendlines.cs.

◆ MinY

double VectSharp.Plots.LogarithmicTrendLine.MinY
getset

The minimum Y value for which the trendline is plotted.

Definition at line 494 of file Trendlines.cs.

◆ PresentationAttributes

PlotElementPresentationAttributes VectSharp.Plots.LogarithmicTrendLine.PresentationAttributes = new PlotElementPresentationAttributes() { LineDash = new LineDash(5, 5, 0), Stroke = Colour.FromRgb(180, 180, 180) }
getset

Presentation attributes for the trendline.

Definition at line 509 of file Trendlines.cs.

◆ Slope

double VectSharp.Plots.LogarithmicTrendLine.Slope
getset

The slope of the trendline (a).

Definition at line 479 of file Trendlines.cs.

◆ Tag

string VectSharp.Plots.LogarithmicTrendLine.Tag
getset

A tag to identify the trendline in the plot.

Definition at line 514 of file Trendlines.cs.


The documentation for this class was generated from the following file: