cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
  • Don’t miss your chance to experience Discovery Summit Europe at our best available rate! Early bird registration through 31 Oct.
  • Graph Builder Toolbar streamlines interactive graphing. Creates shortcuts on Report and GraphBuilder Helpers toolbars. Download and install the extension.
  • JMP will suspend normal business operations for our Rest and Recharge Day on Friday, October 2, 2026.
    Regular business hours will resume on Monday, October 5, 2026.

Discussions

Solve problems, and share tips and tricks with other JMP users.
Choose Language Hide Translation Bar
Phil_Brown
Super User (Alumni)

Is there a way to specify the x/y position of a TextSeg within a FrameBox?

Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA/Big Class.jmp" );

Graph Builder(
	Show Control Panel( 0 ),
	Variables( X( :height ), Y( :weight ) ),
	Elements(
		Points( X, Y, Legend( 1 ) ),
		Line Of Fit(
			X,
			Y,
			Legend( 4 ),
			Degree( "Cubic" ),
			Confidence of Prediction( 1 ),
			Root Mean Square Error( 1 ),
			Equation( 1 )
		)
	),
	SendToReport(
		Dispatch(
			{},
			"Graph Builder",
			FrameBox,
			{DispatchSeg(
				TextSeg( 1 ),
				Set Text(
					"weight = -3850 + 197.7*height - 3.343*height² + 0.01906*height³
RMSE: 15.77  Tallest: Lawrence"
				)
			)}
		)
	)
);
PDB
1 ACCEPTED SOLUTION

Accepted Solutions

Re: Is there a way to specify the x/y position of a TextSeg within a FrameBox?

If you want to control the X and Y positions of text, you will need to add a Graphics Script to the FrameBox instead of to the TextSeg as the TextSeg is always going to appear in the top left corner.

 

Here is an example:

 

Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA\Big Class.jmp" );

gb = dt << Graph Builder(
	Show Control Panel( 0 ),
	Variables( X( :height ), Y( :weight ) ),
	Elements(
		Points( X, Y, Legend( 1 ) ),
		Line Of Fit(
			X,
			Y,
			Legend( 4 ),
			Degree( "Cubic" ),
			Confidence of Prediction( 1 ),
			Root Mean Square Error( 1 ),
			Equation( 1 )
		)
	)
);

Report( gb )[FrameBox( 1 )] << Add Graphics Script(
	Text( Center Justified, {60, 40}, "Tallest: Lawrence" )
);
Justin

View solution in original post

2 REPLIES 2

Re: Is there a way to specify the x/y position of a TextSeg within a FrameBox?

If you want to control the X and Y positions of text, you will need to add a Graphics Script to the FrameBox instead of to the TextSeg as the TextSeg is always going to appear in the top left corner.

 

Here is an example:

 

Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA\Big Class.jmp" );

gb = dt << Graph Builder(
	Show Control Panel( 0 ),
	Variables( X( :height ), Y( :weight ) ),
	Elements(
		Points( X, Y, Legend( 1 ) ),
		Line Of Fit(
			X,
			Y,
			Legend( 4 ),
			Degree( "Cubic" ),
			Confidence of Prediction( 1 ),
			Root Mean Square Error( 1 ),
			Equation( 1 )
		)
	)
);

Report( gb )[FrameBox( 1 )] << Add Graphics Script(
	Text( Center Justified, {60, 40}, "Tallest: Lawrence" )
);
Justin
Phil_Brown
Super User (Alumni)

Re: Is there a way to specify the x/y position of a TextSeg within a FrameBox?

Ok, indeed was aware of Text(). TextSeg being relatively new to me, I wondered about its limitations. Thanks Justin!

PDB

Recommended Articles