cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Check out the JMP® Marketplace featured Capability Explorer add-in
Choose Language Hide Translation Bar
JPB
JPB
Level II

problem with Graph Builder header

Hi everyone, when I run graph builder my headers look fine:

JPB_0-1700254046287.png

But when I journal them I get this:

JPB_2-1700254123875.png

If I grab the header to expand it the header of course expands, but it changes the size of the chart as well, which is not desirable:

JPB_3-1700254147096.png

Please let me know how I can expand the header but not change my chart.  I see this issue with both JMP 16 and JMP 17.

 

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
JPB
JPB
Level II

Re: problem with Graph Builder header

Hi Jarmo, thanks for the suggestion.  However, I contacted JMP support (as you suggested) and they had a better solution.  The following is their reply, which works for me.

-------------------------------

This appears to be a bug in JMP related to using the Journal and using a Wrap variable in Graph Builder.  You can change the stretch property for the Label Box in the Journal to have it extend to the full width of the graph instead of being stopped at the right edge of the first graph panel.  Here are the instructions to change the stretching manually:

  1. Journal the Graph Builder window
  2. In the Journal, choose Edit -> Properties from the menu.
  3. Click on one of the page titles to highlight the display box and show the properties on the right side of the window.
  4. Click the disclosure triangle next to the Stretching outline box
  5. Change the value in the dropdown box for the X Stretch property to Window.
  6. Repeat steps 3-5 for the other page label boxes.

JPB_0-1703202514059.png

I am not sure if you are scripting this, but if so, here is a modified version of your script to make the journal show the entire label.  The modification was to assign a variable to reference the platform then add 4 statements at the end.

gb = Graph Builder(
	Size(606, 532),
	Show Control Panel(0),
	Variables(
		X(:Time),
		Y(:Data),
		Page(:Dispense Strategy),
		Wrap(:Group, Levels per Row(3)),
		Overlay(:Channel),
		Color(:Test)
	),
	Elements(Line(X, Y, Legend(8))),
	SendToReport(
		Dispatch(
			{},
			"Data",
			ScaleBox(2),
			{Min(-1), Max(12), Inc(2), Minor Ticks(0)}
		),
		Dispatch(
			{},
			"Data",
			ScaleBox(3),
			{Min(-1), Max(12), Inc(2), Minor Ticks(0)}
		)
	)
);

// Send the graph to the journal
gb << Journal;

// get a reference to the journal
journ = Current Journal();

// use XPath to get all the label boxes with the axis title as part of the label
boxes = journ << XPath("//LabelBox[contains(., 'Dispense Strategy')]");

// change the X Stretch property for all the boxes at once
boxes << Set Stretch("Window", "Neutral"); 

View solution in original post

4 REPLIES 4
jthi
Super User

Re: problem with Graph Builder header

This might require a bit more information (at least I don't remember facing similar issues). Below are few questions that come to my mind:

  • Is this normal graph builder window?
  • How many pages you have? How many X-groups you have?
  • What elements are you using in graph builder (xaxis, yaxis, xgroup, color, page)?
  • Do you create the graph manually and then save as journal?
  • Do you have filters in use? Do you have column switchers in use?

 

This simple script seems to work fine

Names Default To Here(1); 

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

gb = dt << Graph Builder(
	Size(674, 1664),
	Show Control Panel(0),
	Variables(X(:weight), Y(:height), Page(:age), Group X(:sex), Overlay(:sex)),
	Elements(Points(X, Y, Legend(9)), Line Of Fit(X, Y, Legend(11)))
);

gb << journal;

jthi_0-1700288950405.png

Graph Builder on the left and journal on the right

 

You can also contact JMP support if you cannot share more information here regarding your report support@jmp.com . If you contact them and get an answer, please post back so we can know what was the issue.

-Jarmo
JPB
JPB
Level II

Re: problem with Graph Builder header

Hi Jarmo, thank you for taking the time to investigate my problem and reply.  To answer your questions, I created a data table with a script that reproduces my problem (I probably should have done that in the first place ;-).  The script in the data table will generate the graph builder plot, and when I journal the plot I get the attached journal that shows the problem I described in my original post.  Any thoughts you have on how to address it would be appreciated.

jthi
Super User

Re: problem with Graph Builder header

I'm not sure what is breaking the page title, but maybe you could hide the column title from those

jthi_1-1702013036200.png

 

jthi_0-1702013017968.png

 

-Jarmo
JPB
JPB
Level II

Re: problem with Graph Builder header

Hi Jarmo, thanks for the suggestion.  However, I contacted JMP support (as you suggested) and they had a better solution.  The following is their reply, which works for me.

-------------------------------

This appears to be a bug in JMP related to using the Journal and using a Wrap variable in Graph Builder.  You can change the stretch property for the Label Box in the Journal to have it extend to the full width of the graph instead of being stopped at the right edge of the first graph panel.  Here are the instructions to change the stretching manually:

  1. Journal the Graph Builder window
  2. In the Journal, choose Edit -> Properties from the menu.
  3. Click on one of the page titles to highlight the display box and show the properties on the right side of the window.
  4. Click the disclosure triangle next to the Stretching outline box
  5. Change the value in the dropdown box for the X Stretch property to Window.
  6. Repeat steps 3-5 for the other page label boxes.

JPB_0-1703202514059.png

I am not sure if you are scripting this, but if so, here is a modified version of your script to make the journal show the entire label.  The modification was to assign a variable to reference the platform then add 4 statements at the end.

gb = Graph Builder(
	Size(606, 532),
	Show Control Panel(0),
	Variables(
		X(:Time),
		Y(:Data),
		Page(:Dispense Strategy),
		Wrap(:Group, Levels per Row(3)),
		Overlay(:Channel),
		Color(:Test)
	),
	Elements(Line(X, Y, Legend(8))),
	SendToReport(
		Dispatch(
			{},
			"Data",
			ScaleBox(2),
			{Min(-1), Max(12), Inc(2), Minor Ticks(0)}
		),
		Dispatch(
			{},
			"Data",
			ScaleBox(3),
			{Min(-1), Max(12), Inc(2), Minor Ticks(0)}
		)
	)
);

// Send the graph to the journal
gb << Journal;

// get a reference to the journal
journ = Current Journal();

// use XPath to get all the label boxes with the axis title as part of the label
boxes = journ << XPath("//LabelBox[contains(., 'Dispense Strategy')]");

// change the X Stretch property for all the boxes at once
boxes << Set Stretch("Window", "Neutral");