Class ErrorBar
Contents
[
Hide
]ErrorBar class
Represents error bar of data series.
public class ErrorBar : Line
Properties
Name | Description |
---|---|
Amount { get; set; } | Represents amount of error bar. |
BeginArrowLength { get; set; } | Specifies the length of the arrowhead for the begin of a line.(Inherited from Line .) |
BeginArrowWidth { get; set; } | Specifies the width of the arrowhead for the begin of a line.(Inherited from Line .) |
BeginType { get; set; } | Specifies an arrowhead for the begin of a line.(Inherited from Line .) |
CapType { get; set; } | Specifies the ending caps.(Inherited from Line .) |
Color { get; set; } | Represents the Color of the line.(Inherited from Line .) |
CompoundType { get; set; } | Specifies the compound line type(Inherited from Line .) |
DashType { get; set; } | Specifies the dash line type(Inherited from Line .) |
DisplayType { get; set; } | Represents the display type of error bar. |
EndArrowLength { get; set; } | Specifies the length of the arrowhead for the end of a line.(Inherited from Line .) |
EndArrowWidth { get; set; } | Specifies the width of the arrowhead for the end of a line.(Inherited from Line .) |
EndType { get; set; } | Specifies an arrowhead for the end of a line.(Inherited from Line .) |
FormattingType { get; set; } | Gets or sets format type.(Inherited from Line .) |
GradientFill { get; } | Represents gradient fill.(Inherited from Line .) |
IsAuto { get; set; } | Indicates whether this line style is auto assigned.(Inherited from Line .) |
IsAutomaticColor { get; } | Indicates whether the color of line is automatic assigned.(Inherited from Line .) |
IsVisible { get; set; } | Represents whether the line is visible.(Inherited from Line .) |
JoinType { get; set; } | Specifies the joining caps.(Inherited from Line .) |
MinusValue { get; set; } | Represents negative error amount when error bar type is Custom. |
PlusValue { get; set; } | Represents positive error amount when error bar type is Custom. |
ShowMarkerTTop { get; set; } | Indicates if formatting error bars with a T-top. |
Style { get; set; } | Represents the style of the line.(Inherited from Line .) |
ThemeColor { get; set; } | Gets and sets the theme color.(Inherited from Line .) |
Transparency { get; set; } | Returns or sets the degree of transparency of the line as a value from 0.0 (opaque) through 1.0 (clear).(Inherited from Line .) |
Type { get; set; } | Represents error bar amount type. |
Weight { get; set; } | Gets or sets the WeightType of the line.(Inherited from Line .) |
WeightPt { get; set; } | Gets or sets the weight of the line in unit of points.(Inherited from Line .) |
WeightPx { get; set; } | Gets or sets the weight of the line in unit of pixels.(Inherited from Line .) |
Examples
[C#]
Workbook workbook = new Workbook();
Cells cells = workbook.Worksheets[0].Cells;
cells["a1"].PutValue(2);
cells["a2"].PutValue(5);
cells["a3"].PutValue(3);
cells["a4"].PutValue(6);
cells["b1"].PutValue(4);
cells["b2"].PutValue(3);
cells["b3"].PutValue(6);
cells["b4"].PutValue(7);
cells["C1"].PutValue("Q1");
cells["C2"].PutValue("Q2");
cells["C3"].PutValue("Y1");
cells["C4"].PutValue("Y2");
int chartIndex = workbook.Worksheets[0].Charts.Add(ChartType.Column, 11, 0, 27, 10);
Chart chart = workbook.Worksheets[0].Charts[chartIndex];
chart.NSeries.Add("A1:B4", true);
chart.NSeries.CategoryData = "C1:C4";
for(int i = 0; i < chart.NSeries.Count; i ++)
{
Series aseries = chart.NSeries[i];
aseries.YErrorBar.DisplayType = ErrorBarDisplayType.Minus;
aseries.YErrorBar.Type = ErrorBarType.FixedValue;
aseries.YErrorBar.Amount = 5;
}
[Visual Basic]
Dim workbook As Workbook = New Workbook()
Dim cells As Cells = workbook.Worksheets(0).Cells
cells("a1").PutValue(2)
cells("a2").PutValue(5)
cells("a3").PutValue(3)
cells("a4").PutValue(6)
cells("b1").PutValue(4)
cells("b2").PutValue(3)
cells("b3").PutValue(6)
cells("b4").PutValue(7)
cells("C1").PutValue("Q1")
cells("C2").PutValue("Q2")
cells("C3").PutValue("Y1")
cells("C4").PutValue("Y2")
Dim chartIndex As Integer = workbook.Worksheets(0).Charts.Add(ChartType.Column,11,0,27,10)
Dim chart As Chart = workbook.Worksheets(0).Charts(chartIndex)
chart.NSeries.Add("A1:B4", True)
chart.NSeries.CategoryData = "C1:C4"
Dim i As Integer
For i = 0 To chart.NSeries.Count - 1
Dim aseries As ASeries = chart.NSeries(i)
aseries.YErrorBar.DisplayType = ErrorBarDisplayType.Minus
aseries.YErrorBar.Type = ErrorBarType.FixedValue
aseries.YErrorBar.Amount = 5
Next
See Also
- class Line
- namespace Aspose.Cells.Charts
- assembly Aspose.Cells