I want to plot several graphs with the same data source in a same window.Here I put a data filter before the plotting.But it dosen't work.Could anyone help??!
dt= Open( "$SAMPLE_DATA/Big Class.jmp" );
New Windows("mt report",
nwBB = Border box(
dt<< Data Filter(
Add Filter( columns( :group ), Where( :group == 1 ) )
);
V List Box(
Graph Builder(.....);
Graph Builder(.....);
)
)
);
See the script below for the proper ordering of the elements to make the script work
Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA/Big Class.jmp" );
New Window( "mt report",
nwBB = Border Box(
V List Box(
dt << Data Filter( Add Filter( columns( :group ), Where( :group == 1 ) ) ),
dt << Graph Builder(
Size( 528, 454 ),
Show Control Panel( 0 ),
Variables( X( :weight ), Y( :height ) ),
Elements( Points( X, Y, Legend( 3 ) ), Smoother( X, Y, Legend( 4 ) ) )
),
dt << Graph Builder(
Size( 528, 454 ),
Show Control Panel( 0 ),
Variables( X( :height ), Y( :weight ) ),
Elements( Points( X, Y, Legend( 3 ) ), Smoother( X, Y, Legend( 4 ) ) )
)
)
)
);
Try something like this:
dt = open("$sample_data\Big Class.jmp");
nw = new window("Test 2 Graphs + Data Filter",
vlistbox(
dt << Graph Builder(
Size( 518, 445 ),
Show Control Panel( 0 ),
Variables( X( :age ), Y( :sex ), Overlay( :sex ) ),
Elements( Points( X, Y, Legend( 9 ) ) ),
Local Data Filter( Add Filter( columns( :height ) ) )
),
dt << Graph Builder(
Size( 526, 451 ),
Show Control Panel( 0 ),
Variables( X( :weight ), Y( :height ) ),
Elements( Points( X, Y, Legend( 5 ) ), Smoother( X, Y, Legend( 6 ) ) ),
Local Data Filter( Add Filter( columns( :sex ) ) )
),
)
);
So if I want to get the plot with column(group) value=1,I have to code like this??
Elements(...)
Local Data Filter(Add Filter( columns( :group ), Where( :group == 1 ) ))),
See the script below for the proper ordering of the elements to make the script work
Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA/Big Class.jmp" );
New Window( "mt report",
nwBB = Border Box(
V List Box(
dt << Data Filter( Add Filter( columns( :group ), Where( :group == 1 ) ) ),
dt << Graph Builder(
Size( 528, 454 ),
Show Control Panel( 0 ),
Variables( X( :weight ), Y( :height ) ),
Elements( Points( X, Y, Legend( 3 ) ), Smoother( X, Y, Legend( 4 ) ) )
),
dt << Graph Builder(
Size( 528, 454 ),
Show Control Panel( 0 ),
Variables( X( :height ), Y( :weight ) ),
Elements( Points( X, Y, Legend( 3 ) ), Smoother( X, Y, Legend( 4 ) ) )
)
)
)
);
Big thx!! I'll try it tomorrow in company!
Hello,
It seems that in JMP16, this script would not have the data filter included in the report (as was the case for JMP15) but rather in its own data filter window.
Any suggestions to get a result similar to JMP 15?
Best,
Sebastien