<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />Hello all,
I'm creating graphs using Graph Builder, and I'm using the Wrap zone to show a "matrix" of graphs. However, when I have a lot of levels the font size for each graphs header is too large. Is there any way to reduce it?
For example:
dt = open("$sample_data\S4 Temps.jmp");
Graph Builder(
Show Control Panel( 0 ),
Variables( X( :outside temp ), Y( :Y ), Wrap( :Name( "room/office" ) ) ),
Elements(
Points( X, Y, Legend( 1 ) ),
Line( X, Y, Legend( 3 ), Row order( 0 ), Summary Statistic( "Mean" ) )
),
SendToReport(
Dispatch( {}, "outside temp", ScaleBox, {Rotated Labels( "Automatic" )} )
)
);
Thanks for that information MS. I'll probably roll my own display, as too much space is still taken up by the text box for the graph box header.
The only way I have found is to reduce the Text Font size in preferences. However that will also change the legend font size and the wrap heading accordingly.
It can be somewhat automated with jsl (partly reused code from a recent similar thread
wrap_column = Column( "room/office" );
dt = Open( "$sample_data\S4 Temps.jmp" );
Graph Builder(
Show Control Panel( 0 ),
Variables( X( :outside temp ), Y( :Y ), Wrap( wrap_column ) ),
Elements(
Points( X, Y, Legend( 1 ) ),
Line( X, Y, Legend( 3 ), Row order( 0 ), Summary Statistic( "Mean" ) )
),
SendToReport( Dispatch( {}, "outside temp", ScaleBox, {Rotated Labels( "Automatic" )} ) )
);
// Change Text Font size
p_expr = Expr( Get Preferences( text font ) );
p_start = p_expr;
scale_factor = 20; // Adjust according to string length and one's own liking
Summarize( g = by( wrap_column ) );
For( i = 1, i <= N Items( g ) / scale_factor, i++,
p = p_expr;
Preferences( text font( Arg( Arg( p, 1 ), 1 ), Arg( Arg( p, 1 ), 2 ) - 1 ) );
);
// Uncomment and run the code below to reset original setting after export of graph
// Eval( p_start );