|
Keywords: 3d graphing software, 3d, graphing, software, 3 d, graphing, software
SigmaPlot Macro Sample Code
Some very useful programming procedures have been developed for the macros distributed with SigmaPlot. Some of these code samples and an example macro where each has been used, are described here.
|
Code Sample
|
Macro
|
Function
|
|
Populate Array
|
Batch Process Excel Files
|
Populates array with specific notebook items
|
|
Empty Column
|
Area Below Curves
|
Determines if a worksheet column is empty
|
|
Create Worksheet
|
Frequency Plot
|
Creates worksheet object and opens it
|
|
Find Plots
|
Color Transition Values
|
Creates current page and graph objects; generates list of plots in graph
|
|
First Empty Column
|
Area Below Curves
|
Determine range of worksheet data; find first empty column
|
|
List of Data Columns
|
F-test Comparison of Curves
|
Creates list of columns containing data
|
|
First Empty
|
Power Spectral Density
|
Creates "first empty" column option in dialog box
|
|
Transform
|
F-test Comparison of Curves
|
Creates and runs a transform
|
|
Reports
|
F-test Comparison of Curves
|
Creates and numbers reports
|
|
Column Length
|
F-test Comparison of Curves
|
Returns column length
|
|
Fit Library
|
Batch Process Excel Files
|
Opens and defines a fit library
|
|
Curve Fit
|
Batch Process Excel Files
|
Runs a curve fit
|
|
Select Plot
|
Batch Process Excel Files
|
Selects the current plot
|
|
Call Automated Application
|
Paste to PowerPoint Slide
|
Calls another automated application like PowerPoint or Word
|
|
Column title
|
Rank and Percentile
|
Adds a column title
|
|
P o p u l a te Array Creates an array populated by a specific set of notebook items, in this case, equation names. The item type is specified using the ItemType property where
ItemType = 6 corresponds to a fit item (equation).
Empty Column This subroutine determines if a column is an empty column.
Create Worksheet Creates an object consisting of the current Worksheet.
Find Plots Creates objects consisting of the current Page and Graph, and generates a list of Plots for the Graph.
First Empty Column Determines the data range and defines the first empty column (=LastColumn+1).
List of Data Columns Sorts through columns and creates a list of data columns. The list consists of column numbers or column titles if they exist. Uses object definitions from code
examples above, as well as the empty_col function in the Empty Column description above.
First Empty Creates a "First Empty" column option in a dialog box.
Transform Creates and runs a transform. 9 is the item type for a transform.
Reports Creates and numbers reports.
Column Length Returns column lengths.
Fit Library Opens and defines a Curve Fitting Library.
Curve Fit Example of running a Curve Fit; uses fit library defined above. Modify the various properties to suit your application.
Select Plot Selects the current plot. The plot must be selected to modify its properties.
Call Automated Application Calls another automated application (in this case, PowerPoint). Note that in order to call objects, properties and methods from the other application, you
must also add it as a Reference. Use the Macro References button in the SigmaPlot macro editor.
Column Title Adds a column title to a column in the worksheet.
Back to SigmaPlot Product Uses Page.
|