cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
  • 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!
  • Use World Cup data to build models, explore spatial relationships, and create informative visualizations in JMP. Register. July 17, 2 pm US Eastern Time.
  • 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
bpp0920200
Level I

How to specify a number array

Hello Guys,

I want to specify a number array from 1 to 100.

Right now I am doing it in the following way.

sel[1] = {"1", "2", "3", "4", .....continued upto "100"};

But this method is very cumbersome as I have to type in all numbers up to 100. Is there any shorter way in which I can tell JMP that I mean all numbers from 1 to 100.

Thanks

2 REPLIES 2
pmroz
Super User

Re: How to specify a number array

To get a matrix of 100 values going from 1 to 100:

a_matrix = 1::100;

To convert this to a list:

a_list = as list(a_matrix)[1];

ms
Super User (Alumni) ms
Super User (Alumni)

Re: How to specify a number array

Your example shows a list of numbers within quotation marks, i.e. text-formatted numbers. If that's what you need, this formula would do it:

Local({i = 0}, Repeat({i++; Char(i)}, 100));

Recommended Articles