![]() |
spa |
|
User-defined equations What kind of equations can you enter into Prism? You don't have to use one of the classic built-in equations. You can enter your own equations into Prism, subject to these limitations:
Entering a user-defined equation At the top of the parameters dialog for nonlinear regression (or simulate curve) select "More equations". Then select "Enter your own equation" to bring up the Equation dialog.
You must enter a name for the equation, which will then appear on the list of "more equations" in the nonlinear regression dialog.In entering the equation itself, follow these guidelines (similar to those of the Basic computer language).
Here are three examples of one-line equations:
Below is an example of a longer equation. Because K is on the left of the equals sign, Prism recognizes that it is an intermediate variable rather than a variable to be fit by nonlinear regression. Note two comments, one on a line by itself and the other on the same line with equation code.
Available functions When you enter your equations, you can use any of the functions listed below. Don't use any of those names for your variables. (The variables j and k in the descriptions below can be any variable or expression.)
Using the IF function Prism allows you to introduce some branching logic through use of the If function. The syntax is: IF (conditional expression, value if true, value if false) You can precede a conditional expression with NOT, and can connect two conditional expressions with AND or OR. Examples of conditional expressions:
Note: "<>" means not equal to. "<=" means less than or equal to. ">=" means greater than or equal to. Here is an example.
If X is less than X0, then Y is set equal to the variable Plateau. Otherwise Y is computed as Plateau*exp(-K*X).You may also insert a conditional expression anywhere in an equation, apart from an If function. A conditional expression evaluates as 1.0 if true and 0.0 if false. Example:
When X is less than 4, this evaluates to 1*1 + 0*10=1. When X is greater than 4, this evaluates to 0*1+1*10=10. Defining rules for initial values in nonlinear regression Before it can perform nonlinear regression, Prism must have initial values for each variable in the equation. You can enter initial values at the time you fit curves, but it is helpful to define rules for generating the initial values at the time you enter a new equation. Then Prism will calculate the initial values automatically. If you don't enter rules for initial values, you will need to enter the initial values for every variable, for every data set, every time you fit data. To define rules for initial values for user-defined equations: While entering or editing a user-defined equation, click on the button labeled "Rules for initial values". On the Default Values dialog, enter the rule for finding the initial value of each variable. For each variable in the equation, enter a number in the first column and select a multiplier from the drop-down list in the second column.
All but two choices on the drop-down list are used to multiply or divide the number you entered by a value determined from the range of the data: YMIN, YMAX, YMID, XMIN, XMAX, XMID, XMID/YMID, XMAX-XMIN, or YMAX-YMIN. The abbreviation YMIN is the minimum value of Y; YMAX is the maximum value, and YMID is the average of YMIN and YMAX. For example, if you enter "0.5" in the first column and select "YMAX" in the second column, Prism sets the initial value to half of YMAX (which differs for each data set). The first choice on the drop-down list is "(Initial value, to be fit)". This means that the value you entered will be the initial value for all data sets. The initial value will not depend on the range of the data. The last choice is "(Hold constant)". This sets the parameter to a constant value, that won't be fit by nonlinear regression. You can choose "(Hold constant)" even for parameters such as specific activity or protein concentration that have different values in each experiment. In the Rules for initial value dialog, choose "(Hold constant)" but leave the value blank. Each time the equation is used, Prism will prompt for a constant value before using the equation in nonlinear regression. Creating equation library files When you choose an equation for nonlinear regression (or simulations), Prism lets you import from the equation library. You can add to the library by following these steps:
When you choose to select an equation from a library file, Prism displays a list of all files (and templates) in the Equations folder. When you pick one of those files, it shows a list of all user-defined equations used in the file, along with a thumbnail preview of the first graph linked to each equation. If a help file exists for the selected file, click "Help with this equation file" to open it. |
| All contents copyright © 1999 by GraphPad Software, Inc. All rights reserved. |