TOOLBOX MACROS
The Toolbox menu item in SigmaPlot version 8.0 contains a list of macros that are frequently used. They are much more accessible to the user when located on the main menu. Remember that you can add a macro name to any menu item (see SigmaPlot help) to make other macros easily accessible.
Area Below Curves
This macro computes the area under each curve in a graph. It uses the trapezoidal rule written to allow integration for unequally spaced x values. Results are displayed in the dialog and placed in a worksheet column.
Border Plots
The distribution of data in a graph is determined in the x and y direction and displayed as a histogram or box plot along the top and right borders of the graph. It is typically used on a scatterplot but the macro will convert other graph types to a scatterplot if the user desires.
Insert Graph into Word
Use this macro to insert a SigmaPlot graph into an open Microsoft Word document. You must have both a Word Document and a SigmaPlot notebook open in order to use this macro.
Label Symbols
If text labels are entered into a column of the worksheet, this macro will place the labels on the graph adjacent to the symbols. The labels may be placed a specified distance from the symbols and in a selectable orientation (above, below, left, right, upper-left, upper-right, lower-left, lower-right).
Merge Columns
This macro merges two separate worksheet columns into one single text column. This is useful if you have two text fields that need to be combined into one, or if you have imported data that contains dates in one column and time in another. At least two columns of data must present on your worksheet. The results are automatically placed into the first empty column after the last data column.
Paste To PowerPoint Slide
SigmaPlot graphs are copied to PowerPoint with this macro. You create the appropriate background for your slide presentation, gradient blue, say, and this macro allows you to change the colors of lines and symbols in your graph to white or yellow. You may select the text to be bold and change all line thicknesses. By default the graph is made transparent allowing the background to show through but you may deselect this.
Quick Replot
Plot column pairs can be quickly reassigned using this macro. This is a quick way to observe relationships between variables (columns). The current x,y column pair is displayed and dropdown lists allow you to reselect the column pairs. If there are multiple curves in the plot then these may be reselected also prior to leaving the dialog.
Rank and Percentile
Computes ranks and cumulative percentages for a specified data column. The macro returns the sorted data, an index of the original positions, the ranks, and the cumulative percentages. Specifying a column of percentiles yields the values corresponding to those percentiles.
Survival Curve
A Kaplan-Meier survival curve is created with this macro. Two columns of data are required – sorted survival times and a censor index (0=censored, 1=uncensored). The cumulative survival probabilities are computed and the survival curve displayed. The censored values are indicated on the curve with an uptick symbol. The macro dialog allows entry of graph and axis titles.
Batch Process Excel Files
Multiple Excel worksheets are imported and batch processed. The user selects 1) multiple Excel files using a File Open dialog, 2) one of SigmaPlot’s curve fit functions and 3) the type of graph to be created and the macro imports data from each Excel file, fits the data, creates a graph and saves the results for each data set in individual sections of a SigmaPlot notebook. The range of data imported can be selected. The user interface allows both adding and deleting Excel file names from the list. There is a Single Step Mode that can be used to demonstrate the macro. This is an excellent example for users to study that plan to write their own macros.
Color Transition Values
This macro may be used to introduce color as a third variable in a two dimensional scatterplot graph. The color of a symbol is associated with a column of data with the color ranging from a start color to an end color depending on the magnitude of the data in the column.
Compute 1st Derivative
This macro computes a numerical first derivative of a pair of data columns. It computes the running average of specified adjacent first order derivatives. Both the original data and resulting derivative values can be plotted automatically. The SigmaPlot transform language 'diff' function is used to compute the first order differences in x and y required for the numerical derivative. The data need not be sorted by x. Replicate x values and the associated y values are row-wise deleted to eliminate zero divides.
F-test Comparison of Curves
Two curve fits of functions from the same class can be compared using this macro. An F-test is performed on the residuals from the two fits and a p value is computed to determine if there has been a significant improvement in the fit.
Gaussian Cumulative Distribution
This macro returns the results of a Gaussian Cumulative Distribution function (CDF) for a single column of data, and optionally plots the results with a probability Y axis scale. The error function is approximated with a polynomial approximation.
Piper Plot
Use this macro to create a Piper plot. Make sure the values of your four cations and three anions are entered into seven columns. Then, pick the units the data use. If the units used do not match any of the options (percentages, mg/l, or mmol/l) then you will need to transform your data to one of these units. Next, assign the column for each cation/anion as desired by selecting a worksheet column from the Worksheet columns list, the cation/anion from the Assign to list, and clicking the Assign button. You column assignments are listed under Assigned columns.
Polar and Parametric Equations
This macros curves in either Cartesian or polar coordinate systems. Select Rectangular or Polar as the Coordinate System. Then select Single Equation or Parametric as the Curve Description. Set the range of the independent variable and the number of sampled intervals within that range. Click Plot and a new graph page appears with a rendering of the curve. Render subsequent curves on a new graph page or on the last created graph by selecting Create Graph or Add to Current Graph in under Graphing Options.
 |
|