WAPlots.CreatePlot: Difference between revisions

From ReliaWiki
Jump to navigation Jump to search
No edit summary
Line 1: Line 1:
{{Template:APIClass|WAPlots Class|WAPlots}}
{{Template:APIClass|WAPlots Class|WAPlots}}
Create the plot based on the WeibullDataSet and/or the ALTADataSets entered into the WAPlots.


== Declaration  ==
== Declaration  ==


{{APIPrefix|Function}}
{{APIName|CreatePlot(}}
{{APIName|CreatePlot(}}
{{APIPrefix|ByVal}}
{{APIPrefix|ByVal}}
{{APIName|PlotType}}
{{APIName|PlotType}}
{{APIPrefix|As}}
{{APIPrefix|As}}
{{APIName|WAPlotType,}}
{{APIName|[[WAPlotType]],}}
{{APIPrefix|Optional ByVal}}
{{APIPrefix|Optional ByVal}}
{{APIName|UserSettings}}
{{APIName|UserSettings}}
{{APIPrefix|As}}
{{APIPrefix|As}}
{{APIName|WAPlotSettings}}
{{APIName|[[WAPlotSettings]]}}
=
=
{{APIPrefix|Nothing}}
{{APIPrefix|Nothing}}
Line 26: Line 27:
=
=
{{APIName|800)}}
{{APIName|800)}}
{{APIPrefix|As Object}}


{{APIComment|Creates a bitmap containing the plot image.}}
{{APIComment|Creates a bitmap containing the plot image.}}
== Parameters ==
'''PlotType'''
Set the type of plot desired, of the [[WAPlotType]] enum.
'''UserSettings'''
Sets the plot settings via an instance of the [[WAPlotSettings]] class.
'''Width'''
Set the width, in pixels, of the finished plot.
'''Height'''
Set the height, in pixels, of the finished plot.
== Usage Example ==
{{APIComment|Create a new Weibull/ALTA Plot instance.}}
        Dim WeibullALTAPlot As New WAPlots
{{APIComment|Declare a WeibullDataSet. See [[New WeibullDataSet]] for additional details.}}
        Dim WDS as New WeibullDataSet
{{APIComment|Add values to the raw data. See [[WeibullDataSet.AddFailure]] for additional details.}}
        WDS.AddFailure(1, 1)
        WDS.AddFailure(2, 1)
        WDS.AddFailure(3, 1)
{{APIComment|Add the WeibullDataSet to the WAPlots.}}
        WeibullALTAPlot.AddDataset(WDS)
{{APIComment|Create the WAPlot.}}
        WeibullALTAPlot.CreatePlot

Revision as of 17:00, 13 September 2013



Create the plot based on the WeibullDataSet and/or the ALTADataSets entered into the WAPlots.

Declaration

CreatePlot( ByVal PlotType As WAPlotType, Optional ByVal UserSettings As WAPlotSettings = Nothing , Optional ByVal Width As Integer = 1150, Optional ByVal Height As Integer = 800)

Creates a bitmap containing the plot image.

Parameters

PlotType Set the type of plot desired, of the WAPlotType enum.

UserSettings Sets the plot settings via an instance of the WAPlotSettings class.

Width Set the width, in pixels, of the finished plot.

Height Set the height, in pixels, of the finished plot.

Usage Example

Create a new Weibull/ALTA Plot instance.

       Dim WeibullALTAPlot As New WAPlots

Declare a WeibullDataSet. See New WeibullDataSet for additional details.

       Dim WDS as New WeibullDataSet

Add values to the raw data. See WeibullDataSet.AddFailure for additional details.

       WDS.AddFailure(1, 1)
       WDS.AddFailure(2, 1)
       WDS.AddFailure(3, 1)

Add the WeibullDataSet to the WAPlots.

       WeibullALTAPlot.AddDataset(WDS)

Create the WAPlot.

       WeibullALTAPlot.CreatePlot