cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
  • Instantly extract effect sizes, F-ratios, and FDR-adjusted p-values from your models with the Calculate Effects Sizes extension, available now in the JMP Marketplace!
  • New to JMP? Join us Sept. 23-24 for the Early User Edition of Discovery Summit, tailor-made for new users. Register now for free!
  • Your voice matters! Tell us how you prefer to receive JMP updates, so we can tailor our communication to your needs. Take short survey.

Discussions

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

How do I select all rows below a specific value?

Hello,

 

Is there a way in JSL to select all rows below a specific value in a column? The tricky part is that I know what the specific value is but I won't know which row it is on or what values may fall below it in the data table.

 

In my Example Data Table, I would like to select where Column 3 == "B" and all subsequent rows. After running the script, rows 4 through 15 should be selected. Keep in mind that the data table will change and I won't know which row "B" will start on or what "A", "X", "Y" and "Z" are or how many rows are in the data table.

 

Ex.JPG

1 ACCEPTED SOLUTION

Accepted Solutions
txnelson
Super User

Re: How do I select all rows below a specific value?

I think this script will get you what you want

names default to here(1);
dt=current data table();

dt << select where(
	row()>=min(dt<<get rows where(:Column 3=="B"))
);
Jim

View solution in original post

2 REPLIES 2
txnelson
Super User

Re: How do I select all rows below a specific value?

I think this script will get you what you want

names default to here(1);
dt=current data table();

dt << select where(
	row()>=min(dt<<get rows where(:Column 3=="B"))
);
Jim
Raquel
Level III

Re: How do I select all rows below a specific value?

Your script worked perfectly! Thank you so much!

Recommended Articles