cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
  • JMP will suspend normal business operations for our Winter Holiday beginning on Wednesday, Dec. 24, 2025, at 5:00 p.m. ET (2:00 p.m. ET for JMP Accounts Receivable).
    Regular business hours will resume at 9:00 a.m. EST on Friday, Jan. 2, 2026.
  • We’re retiring the File Exchange at the end of this year. The JMP Marketplace is now your destination for add-ins and extensions.

Discussions

Solve problems, and share tips and tricks with other JMP users.
Choose Language Hide Translation Bar
dustincurry
Level I

Printing variables to display box/window

I have a script that calculates some slopes and offsets based on a large data set. 

Once the slopes and offsets are calculated I want to output them to a new display box or window. 

It has been a couple years since I have really done much scripting with JMP so I'm fairly rusty, so I'm sure the code below is far from correct.

How can I output the variables to some kind of pop out window?

My variables are Slope_1C, Offset_1C, Slope_2C, Offset_2C.

 

New Window ("Slopes and Offsets",
Text box("1C Slope = ", Slope_1C),
Text box("1C Offset =", Offset_1C),
Text box("2C Slope =", Slope_2C),
Text box("2C Offset =", Offset_2C),
);

 

Thanks!

1 REPLY 1
jthi
Super User

Re: Printing variables to display box/window

If your variables have numeric values, you will have to change them to characters with Char(). Then you could concatenate them, for example:

Text box("2C Slope =" || char(Slope_2C))

I would use Lineup Box in case like this:

Names Default To Here(1);

Slope_1C = 1;
Offset_1C = 2;
Slope_2C = 3;
Offset_2C = 4;

New Window("Slopes and Offsets",
	Lineup Box(N Col(2),
		Text Box("1C Slope = "),
		Text Box(char(Slope_1C)),
		Text Box("1C Offset = "),
		Text Box(char(Offset_1C)),
		Text Box("2C Slope = "),
		Text Box(char(Slope_2C)),
		Text Box("2C Offset = "),
		Text Box(char(Offset_2C)),
	)
);

jthi_0-1634750644235.png

 

-Jarmo

Recommended Articles