Subscribe Bookmark RSS Feed

Referencing an overlay plot

i have a problem referencing an overlay plot in a report.
my code is similar to the following example:

Dis1=Outline Box( "Chart",
OLP=dt << Overlay Plot("Name", code));

Dis2 = buttonbox("BT1", code);

REP = New Window("TXT", Outlinebox(V list box(Dis1,Dis2)));

to make things short, i'll just explain that i can't reference OLP directly (i have several windows open, all created with OLP, and i don't necessary want to reference the latest one).

how can i reference OLP from a specific window?
5 REPLIES
I'll try to be more clear about the problem...

i have a script creating an overlay plot, it looks something like that:

new window(outlinebox("Txt1", outlinebox("Txt2", OLP=overlay plot("Title", code))));

now if i want to make any change to the overlay plot i can simply reference OLP (e.g. OPL<<:Series1( Connect Points( 0 ), Show Points( 0 ) )).

my problem is that in my code i can't reference to OLP.
Is there a way to get a reference from a report to an overlay plot object?
i'm only able to get a reference to it a as display box which doesn't enable me to make the changes i want.

any ideas are welcomed.

THX
Interesting. I tried to recreate your situation using Big Class.jmp from Sample Data:

New Window(
Outline Box( "TXT1",
Outline Box( "Txt2",
Overlay Plot( Y( :height ), Separate Axes( 1 ) )
)
)
);

...and JMP runs, but produces nothing and puts nothing in the log !
try this code:

New Window( "TXT1",V list box( outline box("TXT2",
Outline Box( "OLP",
Overlay Plot(
Y( :height ),
Separate Axes( 1 ),
Connect Thru Missing( 1 ),
Show Points( 0 ),
SendToReport( Dispatch( {}, "Overlay Plot", FrameBox, Frame Size( 594, 313 ) ) )
)
)
)));


now, after you've ran this code and got the overlay plot, try to make it show the points (show points(1)) using script
We're closer, although not there yet.

This first snippet selects the window:

op = New Window( "TXT1",V list box( outline box("TXT2",
Outline Box( "OLP",
Overlay Plot(
Y( :height ),
Separate Axes( 1 ),
Connect Thru Missing( 1 ),
Show Points( 0 ),
SendToReport( Dispatch( {}, "Overlay Plot", FrameBox, Frame Size( 594, 313 ) ) )
)
)
)));
r1=op["Overlay Plot"];
r1<
Eugene, Thanks

I've managed to get this far, the problem is that r1 is a reference to a display box (same properties as display box) and not a platform object.

BTW, this problem can be resolved by naming the overlay plot:
OLP=Overlay plot(......).

than OLP<<:height (show points(0)) accomplishes the job.

however, in my code i have several windows and OLP references only the latest one, so i order to make that change to an overlay plot which is not the latest one i need to somehow reference it by obtaining the platform object.

thanks a lot for your help.