Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

- JMP User Community
- :
- Discussions
- :
- Discussions
- :
- Variable Level Ranges in Formulas

- Start Article
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

Jul 22, 2015 12:38 PM
(5000 views)

I am trying to use a range of levels from a source variable in a formula and encountering some challenges.

For example in *TestVar* I would have a response scale such as...

- Poor
- Fair
- Good
- Very good
- Excellent

I want to use something like IF (*TestVar == 1-3, "Rejector", "Acceptor")*

"1-3" is treated as an equation which is not what I am looking for. Delimiting does not work either. I did get around this by simply recoding *TestVar *but I am thinking there has to be a way to use a range. I did consider an *Or* statement but I am curious if there is a way to use a range.

As always, thanks for the help!

1 ACCEPTED SOLUTION

Accepted Solutions

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

How about

if **(****1** <= TestVar <= **3**, "Rejector", "Acceptor"**)**

4 REPLIES 4

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

How about

if **(****1** <= TestVar <= **3**, "Rejector", "Acceptor"**)**

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

Re: Variable Level Ranges in Formulas

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

Re: Variable Level Ranges in Formulas

I found it in the scripting guide just the other day. In chapter 5 under operators. Look at table 5.3.

<=, < Less Equal Less ** ***a*<=*b*<* c *Less Equal Less(

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

Re: Variable Level Ranges in Formulas

That is fantastic. Thank you!