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
mjoner
Level VI

"Dynamic Reference Line"?

Is there a way to modify a Profiler so that when certain variables are changed, a y-axis reference line is drawn at a specific location?

More specifically I have a Profiler modeling y = f(x,z) where x are control variables and z are variables that are usually noise but which I can control in the right environment. I have a comparison/reference value y' = g(z) and know that the reference will change if certain noise variables increase or decrease.

Right now the only way I can think of to do this is to create a Profiler on (y-y') by making a new formula, but then my end users have to know that the y-variable in this new Profiler is not measuring raw outcome but is rather measuring the delta of y relative to the reference, and I worry that this could be confusing. Are there other options?

1 ACCEPTED SOLUTION

Accepted Solutions
David_Burnham
Super User (Alumni)

Re: "Dynamic Reference Line"?

Not sure this is helpful or not depending on if I understood your question

The Set Script message for the profiler allows you to assign a callback function which is invoked whenever a variable is changed.  Below I set the ref line to be 50 times the value of the "Silica" whenever a variable is changed

dt = Open( "$SAMPLE_DATA/Tiretread.jmp" );

prof = Profiler(

    Y(:Pred Formula HARDNESS),

    SendToReport(

        Dispatch(

            {"Prediction Profiler"},

            "10000",

            ScaleBox,

            {Min( 100 ), Max( 20 ), Inc( 5 ), Minor Ticks( 1 )}

        )

    )

);

prof << Set Script( CallBack() );

CallBack = Function({settings},{Default Local},

   

    silicaValue = Get Silica(settings);

    show(silicaValue);

    rep = prof << Report;

    refLineValue = 50*silicaValue;

    Try(

        rep[AxisBox(1)] << Remove Ref Line(::lastValue)

    );

    rep[AxisBox(1)] << Add Ref Line(refLineValue);

    ::lastValue = refLineValue;

   

);

Get Silica = Function({settings},{Default Local},

   

    For (i=1,i<=NItems(settings),i++,

        item = Char(settings[i]);

        varName = Word(1,item," = ");

        If (varName == "SILICA",

            value = Word(2,item," = ");

        )

    );

    Num(value)

   

)

-Dave

View solution in original post

2 REPLIES 2
David_Burnham
Super User (Alumni)

Re: "Dynamic Reference Line"?

Not sure this is helpful or not depending on if I understood your question

The Set Script message for the profiler allows you to assign a callback function which is invoked whenever a variable is changed.  Below I set the ref line to be 50 times the value of the "Silica" whenever a variable is changed

dt = Open( "$SAMPLE_DATA/Tiretread.jmp" );

prof = Profiler(

    Y(:Pred Formula HARDNESS),

    SendToReport(

        Dispatch(

            {"Prediction Profiler"},

            "10000",

            ScaleBox,

            {Min( 100 ), Max( 20 ), Inc( 5 ), Minor Ticks( 1 )}

        )

    )

);

prof << Set Script( CallBack() );

CallBack = Function({settings},{Default Local},

   

    silicaValue = Get Silica(settings);

    show(silicaValue);

    rep = prof << Report;

    refLineValue = 50*silicaValue;

    Try(

        rep[AxisBox(1)] << Remove Ref Line(::lastValue)

    );

    rep[AxisBox(1)] << Add Ref Line(refLineValue);

    ::lastValue = refLineValue;

   

);

Get Silica = Function({settings},{Default Local},

   

    For (i=1,i<=NItems(settings),i++,

        item = Char(settings[i]);

        varName = Word(1,item," = ");

        If (varName == "SILICA",

            value = Word(2,item," = ");

        )

    );

    Num(value)

   

)

-Dave
orel
Level I

Re: "Dynamic Reference Line"?

hi

 

i have a question about the dynamic issue:

i want to add  a parameter into the profiler that will be calculated from the data that are in the profiler and are changing.

for example - the flow rate is a function of viscosity which is changing according to grinding time. if i could add a formula into the profiler it will calculate the flow dynamically.

can you add the formula into the profiler?

 

thanks

orel