Multiple input for Graph BuilderHi All,
I am working on a script that will allow me to select more than one Y response(and X factor as well) and using Graph builder, I will be able to plot it accordingly. I am able to select the relevant Y and X but somehow the Graph builder part is not working. Here is the script:
dt = Open( "$SAMPLE_DATA/Big Class.jmp" );
dlg = Column Dialog(
ColID = Col List( "X, Factor", Max Col( 1 ) ),
SS = Col List( "Y, Response" ),<BR />);
Graph Builder(
Variables( X( Column(dt,ColID ), Y( Column(dt, SS ) ),
Elements( Points( X, Y, Legend( 3 ) ), Smoother( X, Y, Legend( 4 ) ) )
)),
); Please let me know which part of the script went wrong.
Thank you.
Re: Multiple input for Graph BuilderThank you Jim and MS.Re: Multiple input for Graph BuilderJim is right. For the assignments of ColID and SS to be effective, the list dlg must be evaluated first. Also, there seems to some misplaced parantheses in the code.
Try this:
dt = Open("$SAMPLE_DATA/Big Class.jmp");
dlg = Column Dialog(
ColID = Col List("X, Factor", Max Col(1)),
SS = Col List("Y, Response", Max Col(1))
);
Eval List(dlg[1 :: 2]);
Graph Builder(
Variables(X(Column(dt, ColID)), Y(Column(dt, SS))),
Elements(Points(X, Y, Legend(3)), Smoother(X, Y, Legend(4)))
);Re: Multiple input for Graph BuilderThe values returned from the Column Dialog are not in a scaler format. They are returned in a list. In your example, the list is named dlg.
Look in the JMP Scripting Guide for details
Help==>Books==>Scripting Guide