cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Check out the JMP® Marketplace featured Capability Explorer add-in
Choose Language Hide Translation Bar
jm
jm
Level I

how to plot an equation

Hello,

I'm a new user to JMP and I have a simple question to seek your help.

I would like to ask JMP to plot a graph using an input equation, how do I do that?

The equation is as follows:

(c1-constant1)/(constant2 - constant1) = (constant3 * c2)/(1-(1-constant3)*c2)

where c1 and c2 = column 1 and column 2 respectively.

i.e. I have two columns of experimental data (column 1 and column 2) and ultimately I would like to plot column 1 against column 2 and fit it using the equation above.

Thanks for the help!

1 ACCEPTED SOLUTION

Accepted Solutions
Jeff_Perkinson
Community Manager Community Manager

Re: how to plot an equation

Xan's on the right track for you here.

 

The Nonlinear platform will fit your equation, finding values for your parameters.

 

To start, you'll need to move all your parameters ("constants") as you described them, to one side of your equation. Essentially, you'll solve your equation for either C1 or C2.

 

I solved it for C1 here:

 

c1 = ((constant3 * c2)/(1-(1-constant3)*c2) * (constant2 - constant1)) + constant1


Then, in your existing data table create a column for a new "Predicted C1", using the Parameters option in the upper left of the Formula Editor to create your "constants".

 

7002_JMPScreenSnapz001.png

 Finally, use the Analyze -> Modeling -> Nonlinear menu to get to the Nonlinear platform.

You'll put your "Predicted C1" column in X, Predictor role, and your original C1 column in the Y, Response role.

7003_JMPScreenSnapz002.png

 

Read more about the Nonlinear platform in the online documentation.

-Jeff

View solution in original post

5 REPLIES 5
ron_horne
Super User (Alumni)

Re: how to plot an equation

hi jm,

i would try to put each side of the equation as a new formula column. Then use the profiler and put both columns in the "Y, Prediction formula". Under the Graph menu there are a few different profilers you can choose between according to what gives you a better picture.

ron

XanGregg
Staff

Re: how to plot an equation

To see c1 against c2. Make c1 into a formula column expressed as a function of c2. Then in Graph Builder, put c1 on the Y and c2 on the X and change the element type to the Formula element (second from right). It will plot a smooth curve of the function, not just the data points.

jm
jm
Level I

Re: how to plot an equation

Thanks, that helped!

The plot now shows a curve of the function, together with my data points.

Supposed I can only enter an initial guess for constant 1, how do I ask JMP to start with the initial guess value and continue iterating until the Chi Square does not change for a certain number of iterations or the percent change in the normalized Chi Square is less than the Allowed Error set by me?

Would need the final value of constant, Chi Sq and R value at the end of the curve fit for my data points...

XanGregg
Staff

Re: how to plot an equation

I didn't realize at first that your "constants" aren't really constants! I think you can get what you want if you update your formula to change the constants to "parameters" and then use the Nonlinear platform to find the optimal settings for those parameters.

Jeff_Perkinson
Community Manager Community Manager

Re: how to plot an equation

Xan's on the right track for you here.

 

The Nonlinear platform will fit your equation, finding values for your parameters.

 

To start, you'll need to move all your parameters ("constants") as you described them, to one side of your equation. Essentially, you'll solve your equation for either C1 or C2.

 

I solved it for C1 here:

 

c1 = ((constant3 * c2)/(1-(1-constant3)*c2) * (constant2 - constant1)) + constant1


Then, in your existing data table create a column for a new "Predicted C1", using the Parameters option in the upper left of the Formula Editor to create your "constants".

 

7002_JMPScreenSnapz001.png

 Finally, use the Analyze -> Modeling -> Nonlinear menu to get to the Nonlinear platform.

You'll put your "Predicted C1" column in X, Predictor role, and your original C1 column in the Y, Response role.

7003_JMPScreenSnapz002.png

 

Read more about the Nonlinear platform in the online documentation.

-Jeff