Questions tagged [jsl]

JSL is a programming language with C/Java-style syntax embedded in the JMP graphical data exploration and statistics software from SAS Inc.

Syntax

JSL uses a syntax similar to or with semicolons as statement terminators. Unlike C or Java, it does not use braces ({}) to distinguish statement opening or closing blocks, but simply uses parentheses (()) based on the notion that "everything is an expression." Variable and function names are also case-insensitive in most contexts.

For example, JSL does not distinguish between a in an expression and an if statement, e.g.:

// comparable to this C code: result = (x==0) ? -1 : (x+1)
result = If(x==0, -1, x+1);

/* comparable to this C code:
     if(x<0) {
       x -= 3;
     } else if (x==0) {
       x = 0;
     } else {
       x += 3;
     } */
If(x<=0,
   x -= 3
   , /* implicit else if */ x==0,
   x = 0
   , /* implicit else clause */
   x += 3
);

Resources

23 questions
6
votes
2 answers

How to call Python script from SAS JMP environment using jsl script

I would like to run python script from SAS JMP environment using JSL. What are the options?
Felix
  • 1,539
  • 8
  • 20
  • 35
4
votes
3 answers

How to call a *.jsl script from python script

I have a python script running. I want to call *.jsl script in my running python script and want to make use of it's output in python. May I know how can I do that?
Akshay
  • 833
  • 2
  • 16
  • 34
3
votes
1 answer

What is a jsl tag

Google maps place review commentaries page has a jsl tag, encapsulating almost the entire body of the page. I tried to scrape tags but everything encapsulated by jsl is not recognized (tried scrapy's scrapy shell and beautifulSoup, both with xpath…
Rafael Higa
  • 655
  • 1
  • 8
  • 17
3
votes
2 answers

Notation S[F1:=T1,...,Fn:=Tn] in JSL

In section 4.5 of JLS (Parameterized Types) is mentioned the following notation: S[F1:=T1,...,Fn:=Tn]. I do not exactly unbderstand the meaning of this notation. It is mentioned in the following paragraph: A generic type has type parameters…
Vitaly
  • 845
  • 1
  • 10
  • 29
2
votes
2 answers

JSL Connection to SQL Server Express Setup DSN

I am trying to automate JSL script and I need to update some records from SQL Server using JMP JSL Script. I have found below connection string, but I am not sure how to use this. Open Database("DSN=ODBC…
kuls
  • 48
  • 6
2
votes
2 answers

How to make my code more efficient (beginner :)

can someone suggest a shorter code that does the same? CASE WHEN {location} LIKE '%00' OR {location} LIKE '%010' OR {location} LIKE '%011' OR {location} LIKE '%012' OR {location} LIKE '%013' THEN '1' WHEN {location} LIKE '%38' OR {location}…
Adam Cohen
  • 23
  • 3
2
votes
1 answer

jsl tag doesn't show up when parsing HTML with Python and Beautiful Soup

A little background (I am super novice at programming, so bear with me): I am trying to scrape duration_in_traffic numbers from google maps (I know there is an API, but this data piece is restricted to 'Maps for Business' so I figured this would be…
Kevin Hansen
  • 85
  • 1
  • 6
2
votes
1 answer

Creating a new column in JMP using an if condition from another column

I am very new in JMP so I am still feeling around. I want to create a new column called "Status" in JMP. This status is character and depends on the value of the column "Grade". If the value of the entry in column "Grade" is zero, the value of the…
schrodingerscat
  • 189
  • 1
  • 3
  • 15
1
vote
1 answer

In JMP, how to custom graph line by specifying the curve name?

In JMP, we can custom any fit curve using this code obj << (Curve[1] << Line Style( DashDot )); Now what I want to customize the line style not based from curve number but by curve name. Example, if I have 5 curves (grouped by day of the week), I…
schrodingerscat
  • 189
  • 1
  • 3
  • 15
1
vote
0 answers

In JMP Fit Model Profiler, how do I create a single Output Grid Table for all groups?

I want to create a table that predicts the value of several Y variables given that two X variables have fixed value. I want to do this on a per group basis using Fit Model of JMP. The problem is that per group, I get one table. So if I have 20…
schrodingerscat
  • 189
  • 1
  • 3
  • 15
0
votes
1 answer

How to make loop function using multiple input value to JSL in Groovy

I'm using the below function in Jenkins Shared Library. /* The below function delete uploads that exist in the server. */ def delete_upload(server_url,each_upload_id,authentication){ def delete_upload_url = server_url +…
Abilash
  • 39
  • 5
0
votes
2 answers

Regex match between n and m numbers but as much as possible

I have a set of strings that have some letters, occasional one number, and then somewhere 2 or 3 numbers. I need to match those 2 or 3 numbers. I have this: \w*(\d{2,3})\w* but then for strings like AAA1AAA12A AAA2AA123A it matches '12' and '23'…
miguello
  • 544
  • 5
  • 15
0
votes
2 answers

jmp script logic works as jsl but not as add-in

I run JMP 15.2.0 and my jsl script includes this section of code, which has a minor bug: for each row( if (:ColumnA == 99, ColumnA = .) ); The 2nd ColumnA should have a leading : in order to replace 99's with null. But for some reason this…
Woodchuck
  • 3,869
  • 2
  • 39
  • 70
0
votes
0 answers

How do I find the region a point lies within

Below I have an image representation of a map with different regions labeled on it. My problem is that I need to find out what region a randomly generated point on the map will be in. I know the x_min, y_min, x_max, y_max of all the different…
MrMineHeads
  • 111
  • 1
  • 5
0
votes
0 answers

convert Timestamp to Date in JSL Scripting

I am trying to run a SQL Statement in JSL, but the statement includes a column with datetime, i do not need datetime but simply date. JSL does not like "cast for some reason" can someone please assist Open Database( "DSN=EDWPROD; UID=" || ID…
1
2