cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
  • Don’t miss your chance to experience Discovery Summit Europe at our best available rate! Early bird registration through 31 Oct.
  • Graph Builder Toolbar streamlines interactive graphing. Creates shortcuts on Report and GraphBuilder Helpers toolbars. Download and install the extension.
  • JMP will suspend normal business operations for our Rest and Recharge Day on Friday, October 2, 2026.
    Regular business hours will resume on Monday, October 5, 2026.

Discussions

Solve problems, and share tips and tricks with other JMP users.
Choose Language Hide Translation Bar
gutloja
Level III

Help with Kernel Smoother output

[Kernel smoother - output in column]

Hello All,

I am running a kernel smoother but I would like to have the output of each smoother in a column, using the name of the variable. I still would like to see the Fit Group graph, for visual inspection, but I can't find a way to have JMP write the predicted values to a different column automatically [I usually save predicteds, coefficients, etc. manually].

Is there a way to do this?. This is the script I am using:

KernelSmootherGroup# = Expr(

Fit Group(

    Bivariate( Y( :Name( "Var1" ) ), X( :RowNO ),

        Kernel Smoother( 1, 1, 0.0985804416403786, 0 )

    ),

    Bivariate( Y( :Name( "Var2" ) ), X( :RowNO ),

        Kernel Smoother( 1, 1, 0.0985804416403786, 0 )

    ),

    Bivariate( Y( :Name( "Var3" ) ), X( :RowNO ),

        Kernel Smoother( 1, 1, 0.0985804416403786, 0 )

    ),

    <<{Arrange in Rows( 1 )},

    SendToReport(

        Dispatch(

            {"Bivariate Fit of Var1 By RowNO"},

            "2",

            ScaleBox,

            {Min( 0.1 ), Max( 1 ), Inc( 0.02 ), Minor Ticks( 1 )}

        ),

        Dispatch(

            {"Bivariate Fit of Var1 By RowNO"},

            "Bivar Plot",

            FrameBox,

            {Frame Size( 1085, 240 )}

        ),

        Dispatch(

            {"Bivariate Fit of Var2 By RowNO"},

            "2",

            ScaleBox,

            {Min( 0.1 ), Max( 1 ), Inc( 0.02 ), Minor Ticks( 1 )}

        ),

        Dispatch(

            {"Bivariate Fit of Var2 By RowNO"},

            "Bivar Plot",

            FrameBox,

            {Frame Size( 1092, 240 )}

        ),

        Dispatch(

            {"Bivariate Fit of Var3 By RowNO"},

            "2",

            ScaleBox,

            {Min( 0.1 ), Max( 1 ), Inc( 0.02 ), Minor Ticks( 1 )}

        ),

        Dispatch(

            {"Bivariate Fit of Var3 By RowNO"},

            "Bivar Plot",

            FrameBox,

            {Frame Size( 1096, 240 )}

        ),

    )

);   

   

);

KernelSmootherGroup#;

Any help will be appreciated,

JoseGL

1 ACCEPTED SOLUTION

Accepted Solutions
txnelson
Super User

Re: Help with Kernel Smoother output

Here is your script, modified with the code added that will output the Predicted values:

Names default to here(1);

dt=current data table();

KernelSmootherGroup# = Expr( 

       Fit Group(

              biv1=Bivariate( Y(:Name( "Var1" ) ), X( :RowNO ), Kernel Smoother(1, 1, 0.0985804416403786, 0 ) ),

              biv2=Bivariate( Y(:Name( "Var2" ) ), X( :RowNO ), Kernel Smoother(1, 1, 0.0985804416403786, 0 ) ),

              biv3=Bivariate( Y(:Name( "Var3" ) ), X( :RowNO ), Kernel Smoother(1, 1, 0.0985804416403786, 0 ) ),

              <<{Arrange in Rows( 1 )},

              SendToReport(

                     Dispatch(

                          {"Bivariate Fit of Var1 By RowNO"},

                           "2",

                           ScaleBox,

                           {Min( 0.1 ), Max( 1 ), Inc( 0.02 ), Minor Ticks( 1 )}

                     ),

                     Dispatch(
{
"Bivariate Fit of Var1 By RowNO"}, "Bivar Plot", FrameBox, {Frame Size( 1085, 240 )} ),

                     Dispatch(

                           {"Bivariate Fit of Var2 By RowNO"},

                           "2",

                          ScaleBox,

                           {Min( 0.1 ), Max( 1 ), Inc( 0.02 ), Minor Ticks( 1 )}

                     ),

                     Dispatch(
{
"Bivariate Fit of Var2 By RowNO"}, "Bivar Plot", FrameBox, {Frame Size( 1092, 240 )} ),

                     Dispatch(

                           {"Bivariate Fit of Var3 By RowNO"},

                           "2",

                           ScaleBox,

                           {Min( 0.1 ), Max( 1 ), Inc( 0.02 ), Minor Ticks( 1 )}

                     ),

                     Dispatch(
{
"Bivariate Fit of Var3 By RowNO"}, "Bivar Plot", FrameBox, {Frame Size( 1096, 240 )} ),

              )

       );     


biv1
<< (curve[1] << save predicteds);
biv2
<< (curve[1] << save predicteds);
biv3
<< (curve[1] << save predicteds);  

); 

KernelSmootherGroup#;

Jim

View solution in original post

2 REPLIES 2
txnelson
Super User

Re: Help with Kernel Smoother output

Here is your script, modified with the code added that will output the Predicted values:

Names default to here(1);

dt=current data table();

KernelSmootherGroup# = Expr( 

       Fit Group(

              biv1=Bivariate( Y(:Name( "Var1" ) ), X( :RowNO ), Kernel Smoother(1, 1, 0.0985804416403786, 0 ) ),

              biv2=Bivariate( Y(:Name( "Var2" ) ), X( :RowNO ), Kernel Smoother(1, 1, 0.0985804416403786, 0 ) ),

              biv3=Bivariate( Y(:Name( "Var3" ) ), X( :RowNO ), Kernel Smoother(1, 1, 0.0985804416403786, 0 ) ),

              <<{Arrange in Rows( 1 )},

              SendToReport(

                     Dispatch(

                          {"Bivariate Fit of Var1 By RowNO"},

                           "2",

                           ScaleBox,

                           {Min( 0.1 ), Max( 1 ), Inc( 0.02 ), Minor Ticks( 1 )}

                     ),

                     Dispatch(
{
"Bivariate Fit of Var1 By RowNO"}, "Bivar Plot", FrameBox, {Frame Size( 1085, 240 )} ),

                     Dispatch(

                           {"Bivariate Fit of Var2 By RowNO"},

                           "2",

                          ScaleBox,

                           {Min( 0.1 ), Max( 1 ), Inc( 0.02 ), Minor Ticks( 1 )}

                     ),

                     Dispatch(
{
"Bivariate Fit of Var2 By RowNO"}, "Bivar Plot", FrameBox, {Frame Size( 1092, 240 )} ),

                     Dispatch(

                           {"Bivariate Fit of Var3 By RowNO"},

                           "2",

                           ScaleBox,

                           {Min( 0.1 ), Max( 1 ), Inc( 0.02 ), Minor Ticks( 1 )}

                     ),

                     Dispatch(
{
"Bivariate Fit of Var3 By RowNO"}, "Bivar Plot", FrameBox, {Frame Size( 1096, 240 )} ),

              )

       );     


biv1
<< (curve[1] << save predicteds);
biv2
<< (curve[1] << save predicteds);
biv3
<< (curve[1] << save predicteds);  

); 

KernelSmootherGroup#;

Jim
gutloja
Level III

Re: Help with Kernel Smoother output

Thanks a lot, Jim.
This is what I was looking for.

Recommended Articles