Subscribe Bookmark RSS Feed

Only use a portion of a platform in a new output window?

mewing

Community Trekker

Joined:

Jun 23, 2011

I'm writing a custom platform and I have an issue with the default output produced by certain platforms, I only want to use a portion of the output but without giving up interactivity.

User has some data, they're presented with a window to cast columns to appropriate roles.  My JSL makes an identical linked subset of their data, but makes it private (this is now the current data table), runs the partition platform, saves the leaf numbers and then makes a phased control chart with the leaf numbers as the phases.  The phased control chart has an HListBox type setup with the control chart (which I want), then a warning about excluded rows (I don't want, at least not like this), then the phase summaries (which I'm ambivalent about).  I'm also trying to avoid having too many nested levels of outline boxes.

If I take this control chart and pass it a <<Report, I can pick out from the display tree the elements I want, but the graph is no longer interactive - I can't click on the data and have the relevant row be selected.

Is there a way to make a control chart, get just the plot and put it into a new window?


dt_out = dt << Subset( Selected Rows(0), Selected Columns(0), private, linked); //data the final results are based on.



tmp = "part = dt_out << Partition( Y( :Name(\!"" || process[1] || "\!") ), X( :Name(\!"" || labels[1] || "\!") ), Minimum Size Split( 10 ), Criterion( \!"Maximize Significance\!" ) );"; //change min split size


eval(parse(tmp));


for(i=1,i<=maxv,i++,


      part << Split Best;


);


part << Save Leaf Numbers();


part << Close Window();



tmp = "cc_out = dt_out << Control Chart(Sample Label( :Name(\!"" || labels[1] || "\!")),Phase( :Leaf Number ),Group Size( 1 ),KSigma( 3 ),Chart Col(:Name(\!"" || process[1] || "\!"),Individual Measurement));";


eval(parse(tmp));


rcc = cc_out<<Report;



mcs = "fnw = New Window(\!"" || Char(tablename) || " - CPA Analysis\!",


  Outline Box(\!"Changepoint Analysis\!",rcc[IfBox(2)])


)";


eval(parse(mcs))


2 REPLIES
XanGregg

Staff

Joined:

Jun 23, 2011

FWIW, Excerpt Box does that, but only in the context of a Sheet Box (which "holds" the whole report behind the scenes).

David_Burnham

Super User

Joined:

Jul 13, 2011

Instead of picking out the elements you want, delete the ones that you don't want:

My Control Chart = Function({colName}, {Default Local},

     Eval(Parse(Eval Insert("\[

           cc = Control Chart( Sample Size( 5 ), KSigma( 3 ), Chart Col( ^colName^, XBar, R ), Invisible );

     ]\")));

     ccr = cc << Report;

     ccr[TextBox(3)]<<Delete;

     ccr

);

Open("$SAMPLE_DATA/Big Class.jmp");

cc = My Control Chart("weight");

New Window("Demo",cc) << On Close( cc<<Close Window );

-Dave