- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
Combined Stacked Bars and Line Plot in One Graph
Hello!
Good day.
Team,
May i request your support .
In JMP 8, is it possible to create a Stacked Bar and Line in one Graph ?
If yes, could you please teach me how to ?
Here is my sample data, to better illustrate my query (done this thru excel):
Description: 1. X- axis is DAY
2. YIELD is Y-axis (left) as Line Graph
3. DEFECT1-5 is Y-axis (right) as Stacked Bar
I attached also the data.
Please find time to answer my query.
thank you.
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
Re: Combined Stacked Bars and Line Plot in One Graph
Something like this ?
Graph Builder(
Show Control Panel( 0 ),
Variables(
X( :Day ),
Y( :Defect1 ),
Y( :Defect2, Position( 1 ) ),
Y( :Defect3, Position( 1 ) ),
Y( :Yield, Position( 1 ), Side( "Right" ) )
),
Elements(
Line( X, Legend( 8 ), Row order( 0 ), Summary Statistic( "Mean" ) ),
Bar(
X,
Y( 1 ),
Y( 2 ),
Y( 3 ),
Legend( 6 ),
Bar Style( "Stacked" ),
Summary Statistic( "Mean" )
),
Line( X, Y( 4 ), Legend( 9 ), Row order( 0 ), Summary Statistic( "Mean" ) ),
Bar( X, Legend( 10 ), Bar Style( "Stacked" ), Summary Statistic( "Mean" ) )
),
SendToReport( Dispatch( {}, "400", LegendBox, {Position( {0, 1, 2, 3, -1} )} ) )
)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
Re: Combined Stacked Bars and Line Plot in One Graph
Hello,
I think that Graph Builder is available in Jmp 8. You can use it to make this kind of graphs.
This following script was done with jmp 9 and give similar result than Excel one.
=============================
Graph Builder(
Show Control Panel( 0 ),
Variables(
X( :Day ),
Y( :Defect1 ),
Y( :Defect2, Position( 1 ) ),
Y( :Defect3, Position( 1 ) ),
Y( :Yield, Position( 1 ) )
),
Elements(
Line( X, Y( 4 ), Legend( 8 ), Row order( 0 ), Summary Statistic( "Mean" ) ),
Bar(
X,
Y( 1 ),
Y( 2 ),
Y( 3 ),
Legend( 6 ),
Bar Style( "Stacked" ),
Summary Statistic( "Mean" )
)
)
)
=============================
You can also read this post on jmp blog.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
Re: Combined Stacked Bars and Line Plot in One Graph
Hi! Gbu,
Thank you very much for your response.
I tried your recommendation. It is almost there. But i need the Defect/s in the Right Y-Axis.
Can you further improve the script ?
Sorry, i really can't figure it out using the Graph Builder.
best regards,
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
Re: Combined Stacked Bars and Line Plot in One Graph
Something like this ?
Graph Builder(
Show Control Panel( 0 ),
Variables(
X( :Day ),
Y( :Defect1 ),
Y( :Defect2, Position( 1 ) ),
Y( :Defect3, Position( 1 ) ),
Y( :Yield, Position( 1 ), Side( "Right" ) )
),
Elements(
Line( X, Legend( 8 ), Row order( 0 ), Summary Statistic( "Mean" ) ),
Bar(
X,
Y( 1 ),
Y( 2 ),
Y( 3 ),
Legend( 6 ),
Bar Style( "Stacked" ),
Summary Statistic( "Mean" )
),
Line( X, Y( 4 ), Legend( 9 ), Row order( 0 ), Summary Statistic( "Mean" ) ),
Bar( X, Legend( 10 ), Bar Style( "Stacked" ), Summary Statistic( "Mean" ) )
),
SendToReport( Dispatch( {}, "400", LegendBox, {Position( {0, 1, 2, 3, -1} )} ) )
)