Hi @Julianveda ,
I like Jim's answer, but if you are looking for a graph that looks like this instead ...
... you need to drag the Position variable onto the X axis twice.
I hope this helps,
~John
Here's the script for the graph above.
Open( "$SAMPLE_DATA/Football.jmp" ) <<
Graph Builder(
Size( 413, 246 ),
Show Control Panel( 0 ),
Variables(
X( :Position ),
X( :Position ),
Y( :Weight, Side( "Right" ) ),
Y( :Height, Position( 1 ) )
),
Elements( Position( 1, 1 ), Bar( X, Y( 2 ), Legend( 70 ) ) ),
Elements( Position( 2, 1 ), Bar( X, Y( 1 ), Legend( 73 ) ) ),
SendToReport(
Dispatch( {}, "Weight", ScaleBox,
{Min( 0 ), Max( 296.774225863422 ), Inc( 50 ), Minor Ticks( 0 )
}
),
Dispatch( {}, "graph title", TextEditBox,
{Set Text( "Mean(Height) & Mean(Weight) vs. Position" )}
)
)
)