Subscribe Bookmark RSS Feed

How can I fit a second order exponential decay to my data?

pbouzi0

Community Member

Joined:

Sep 25, 2015

How can I fit a second order exponential decay to my data?

2 REPLIES
David_Burnham

Super User

Joined:

Jul 13, 2011

The short answer is you use the Nonlinear platform: Analyze>Modeling>Nonlinear

Nonlinear Regression with Custom Models

Nonlinear Regression with Built-In Models

-Dave
dlee0416

Community Trekker

Joined:

Jun 11, 2014

Here is what I use to fit a Stretched Exponential, make a plot to  look for anomolies and fit using the Non-Linear platform.

Fade=Current Data Table():

Fade << New Column( "Stretched Exponential",

    Numeric,

    Continuous,

    Formula( Parameter( {a = 1, b = -0.01, c = 0.2}, a * Exp( b * :Hours ^ c ) ) )

);

biv=Fade << Bivariate(

    Y( :Std Output1 ),

    X( :Hours ),

    SendToReport(

        Dispatch(

            {},

            "2",

            ScaleBox,

            {Min( 0.65 ), Max( 1.05 ), Inc( 0.05 ), Minor Ticks( 1 ),

            Label Row Nesting( 1 ), Label Row( Show Major Grid( 1 ) )}

        ),

        Dispatch(

            {},

            "Bivar Plot",

            FrameBox,

            {Frame Size( 375, 279 ), Row Legend(

                Exp No,

                Color( 1 ),

                Color Theme( "JMP Default" ),

                Marker( 0 ),

                Marker Theme( "" ),

                Continuous Scale( 0 ),

                Reverse Scale( 0 ),

                Excluded Rows( 0 )

            )}

        )

    )

);

biv<<Journal;

f=Fade<<Nonlinear(

    Y( :Name("Std Output1") ),

    X( :Name( "Stretched Exponential" ) ),

    Iteration Limit( 100000 ),

    Unthreaded( 1 ),

    Newton,

    Finish,

    By( :Device ID ),

    Custom Inverse Prediction( Response( 0.7 ),

    Term Value( Hours( . ) ) )

);

f_rep = f <<report;

rep=Report( f[1] )[Outline Box (6)][Table Box(1)] << Make Combined Data Table;

rep<<Current Data Table<<Set Name("Combined T70 Predictions");

rep=Current Data Table();

rep<<New Column("Exp No", character, formula(Substr(  :Device ID , 1, 10 )));

Hope this helps. Please let me know if you need anything further.

Dave