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
lala
Level IX

How does JSL extract a subset of selected rows for a column in a data table?

It seemed like a simple question, but I didn't succeed.
This selected line number is already selected by other scripts.

Thanks!

 

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

r = dt << Get Selected Rows();
d3 = dt << Subset( Output Table( "tt" ), Selected Rows( r ), selected columns( 0 ) );

2024-04-23_09-19-07.png

2 ACCEPTED SOLUTIONS

Accepted Solutions
txnelson
Super User

Re: How does JSL extract a subset of selected rows for a column in a data table?

selected rows() expects a boolean value, either 0 or 1.  In your example you would specify

selected rows( 1 )

which indicates to the platform to use selected rows for the subset.

Jim

View solution in original post

lala
Level IX

Re: How does JSL extract a subset of selected rows for a column in a data table?

Thank Jim!

d3 = dt << Subset(
	Output Table( "tt" ),
	Selected Rows( 0 ),
	Rows( dt << Get Selected Rows() ),
	Selected columns only( 0 )
);
  • I press manual operation to modify.

View solution in original post

3 REPLIES 3
txnelson
Super User

Re: How does JSL extract a subset of selected rows for a column in a data table?

selected rows() expects a boolean value, either 0 or 1.  In your example you would specify

selected rows( 1 )

which indicates to the platform to use selected rows for the subset.

Jim
lala
Level IX

Re: How does JSL extract a subset of selected rows for a column in a data table?

Thank Jim!

d3 = dt << Subset(
	Output Table( "tt" ),
	Selected Rows( 0 ),
	Rows( dt << Get Selected Rows() ),
	Selected columns only( 0 )
);
  • I press manual operation to modify.

txnelson
Super User

Re: How does JSL extract a subset of selected rows for a column in a data table?

This works too

Jim

Recommended Articles