Subscribe Bookmark RSS Feed

JSL: Combined graphs from multiple data table and combined into a single window

bernie426

Community Trekker

Joined:

Feb 9, 2015

If I have graphs from multiple data table and like to combined those graph into a single window for a report, how can this work out using a script. I tried a simple script below using jmp provided tables, but the script does not work out from me. Can anyone help?

Thanks!

Here is my script,

Names Default To Here( 1 );

New Window( "Combined graphs",

  V Sheet Box(

  <<Hold(Open( "$SAMPLE_DATA/Big Class.jmp" ),

       Bivariate(

                      Y( :weight ),

                      X( :height ),Fit Line()

                      )

                     ),

  <<Hold(Open( "$SAMPLE_DATA/Big Class.jmp" ),Treemap( Categories( :age ) ) ),

  <<Hold(Open( "$SAMPLE_DATA/Big Class.jmp" ),

       Bubble Plot(

                      X( :height ),

                      Y( :weight ),

                      Sizes( :age ),

                      Coloring( :sex ),

                      Circle Size( 6.226 ),

                      All Labels( 0 )

                      )

                      ),

  <<Hold(Open("$SAMPLE_DATA/Diabetes.jmp"),

  Distribution( Continuous Distribution( Column( :BMI ) ) );

  ),

  H Sheet Box(

  Sheet Part(

  "weight by height",

  Excerpt Box(

  1,

  {Picture Box( 1 )}

  )

  ),

  Sheet Part(

  "",

  Excerpt Box(

  3,

  {Picture Box( 1 )}

  )

  )

  ),

  H Sheet Box(

  Sheet Part(

  "height by weight",

  Excerpt Box(

  4,

  {Picture Box( 1 )}

  )

  ),

  Sheet Part(

  "BMI Distribution",

  Excerpt Box(

  4,

  {Picture Box( 1 )}

  )

  )

  )

  )

);

1 ACCEPTED SOLUTION

Accepted Solutions
Solution

Maybe something like this?

Names Default To Here( 1 );

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

bv = expr(dt << Bivariate( Y( :weight ), X( :height ), Fit Line() ));

tm = expr(dt << Treemap( Categories( :age ) ));

bp = expr(dt << Bubble Plot( X( :height ), Y( :weight ), Sizes( :age ), Coloring( :sex ), Circle Size( 6.226 ),

                        All Labels( 0 )));

dtd = Open( "$SAMPLE_DATA/Diabetes.jmp" );

dist = expr(dtd << Distribution( Continuous Distribution( Column( :BMI ) ) ));

New Window( "Combined graphs",

      lineup box(ncol(2), bv, tm, bp, dist);

);

3 REPLIES
ian_jmp

Staff

Joined:

Jun 23, 2011

Something like this, perhaps? Else use 'Window > Combine Windows' and make an Application.

NamesDefaultToHere(1);

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

g1 = Expr(dt1 << Bivariate( Y( :height ), X( :weight ) ));

dt2 = Open("$SAMPLE_DATA/Bands Data.jmp");

g2 =  Expr(dt2 << Distribution( Nominal Distribution( Column( :Name( "Banding?" ) ) ) ));

win = NewWindow("Reports from Two Tables", HListBox(g1, g2));


Solution

Maybe something like this?

Names Default To Here( 1 );

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

bv = expr(dt << Bivariate( Y( :weight ), X( :height ), Fit Line() ));

tm = expr(dt << Treemap( Categories( :age ) ));

bp = expr(dt << Bubble Plot( X( :height ), Y( :weight ), Sizes( :age ), Coloring( :sex ), Circle Size( 6.226 ),

                        All Labels( 0 )));

dtd = Open( "$SAMPLE_DATA/Diabetes.jmp" );

dist = expr(dtd << Distribution( Continuous Distribution( Column( :BMI ) ) ));

New Window( "Combined graphs",

      lineup box(ncol(2), bv, tm, bp, dist);

);

gutloja

Community Trekker

Joined:

Jul 31, 2015

I was wondering about this myself the other day. Thanks for sharing!

-JoseL