Hello,
I would like to add an item in the menu Analyse.
This new item would be "My Fit Y by X". This item opens exactly the same window as "Fit Y by X", but after filling the Yresponse, Xfactor and press OK, the graphic obtained has a specific template I can write in JSL.
In fact I would like only the graph "Normal Quantile Plot -> Plot Quantile by Actual" without "line of fit" and "Normal quantile Label" and additional personalization of colors and sizes.
Is this possible ? Is there an other simple way to apply a template of graphic ?
Thank you.
Here is a method I like to use for simple scripts.
Good Luck!
Oneway(
All Graphs( 0 ),
Plot Quantile by Actual( 1 ),
Line of Fit( 0 ),
Box Plots( 0 ),
X Axis Proportional( 0 ),
Points Jittered( 1 )
);
Im sure this is possible, please see a small example below.
But I do not see "normal quantile plot" in "Fit Y by X" ...
You simply can use "Column Dialog" for requesting the parameter,
prepare some expressions for your graphs manipulating them with the proper input.
See scripting index for many examples.
BR
Names Default To Here( 1 );
// my platform
dt = Open( "$SAMPLE_DATA\Big Class.jmp" );
cd = Column Dialog(
ex y = ColList( "Y", Min Col( 1 ), Max Col( 2 ), Data Type( "Numeric" ) ),
ex x = ColList( "X", Max Col( 1 ), Modeling Type( {"Continuous", "Multiple Response"} ) )
);
Show( cd["ex y"] );
show(cd["ex y"][1]<< get name);
obj_expr = Expr(
Distribution(
Continuous Distribution( Column( Expr( cd["ex y"][1] ) ), Outlier Box Plot( 0 ), Normal Quantile Plot( 1 ) ),
SendToReport(
Dispatch( {expr(cd["ex y"][1]<< get name)}, "", Picture Box( 5 ), {Set Summary Behavior( "Collapse" )} ),
Dispatch( {expr(cd["ex y"][1]<< get name)}, "Quantiles", OutlineBox, {Close( 1 )} ),
Dispatch( {expr(cd["ex y"][1]<< get name)}, "Summary Statistics", OutlineBox, {Close( 1 )} )
)
)
);
Eval( Eval Expr( obj_expr ) );
Thank you Georg,
I will try this, I did not know how to access to the dialogues, your solution is probably the good one.
The normal quantile plot is an optionnal display once the graphic is open (after clic OK), not directly in the Fit Y by X.
Subsidiary question : You may know how to get access to the script of the Built-in Command : "ANALYSE:FIT Y BY X" ?
This command is called via the window : View --> Customize --> Menus and Toolbars --> Main Menu --> Analyse --> Fit Y by X --> Action. I don't know how to access to the script behind. If everything is allready written, why spending time to code and debug...
Many thanks
Here is a method I like to use for simple scripts.
Good Luck!
Oneway(
All Graphs( 0 ),
Plot Quantile by Actual( 1 ),
Line of Fit( 0 ),
Box Plots( 0 ),
X Axis Proportional( 0 ),
Points Jittered( 1 )
);
Hello gzmorgan, this is even faster, perfect.
I just needed to suppress Y() and X() from my template graph script to obtain the dialogue where I can choose the parameters of the graph.
Great !
Thanks, I accept and close the topic.