cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
  • Register to attend Discovery Summit 2025 Online: Early Users Edition, Sept. 24-25.
  • New JMP features coming to desktops everywhere this September. Sign up to learn more at jmp.com/launch.
Choose Language Hide Translation Bar
tsuku24
Level I

Efficient way to customize dual-axis graph with markers, colors, and lines in Big Class.jmp (JMP 18.2.1)

Hi everyone,

I'm a native Japanese speaker and using translation tools to write this post. Please excuse any awkward phrasing.

I'm using JMP 18.2.1 and working with a modified version of the sample dataset Big Class.jmp.
I have uploaded the JMP file with all necessary columns already created.
The manually created script is saved in the JMP file under the name “Prototype.”


Here’s what I want to achieve with the graph:

Graph setup:

  • X-axis: Name
  • Y-axis 1: 身長, 身長_TopLine, 身長_BotLine, 身長_MidLine
  • Y-axis 2: 体重, 体重_TopLine, 体重_BotLine, 体重_MidLine
    (Note: 身長 = Height, 体重 = Weight)

Marker customization by gender (using Overlay):

  • Male: Circle (○)
  • Female: Plus (+)

Graph style:

  • 身長 and 体重: plotted as points
  • *_TopLine and *_BotLine: blue lines
  • *_MidLine: green lines

Export:

I want to export the graph as interactive HTML with full interactivity.
Currently, I’m manually changing each line style, color, and marker type from the legend, which is very time-consuming.
Ultimately, I want to automate the entire graph creation process using JSL.

Is there a better way to fully control these settings via scripting?

Any advice, examples, or best practices would be greatly appreciated!

1 ACCEPTED SOLUTION

Accepted Solutions
jthi
Super User

Re: Efficient way to customize dual-axis graph with markers, colors, and lines in Big Class.jmp (JMP 18.2.1)

In my opinion, it is easiest to do it interactively in JMP once and then copy the script. You can then use that JMP created script in your automated process. 

For example, to edit the lines, you can double click on the legend, select all top/bot lines and modify them at the same time

jthi_0-1755754750949.png

Also, in some cases you might be able to use Presets.

-Jarmo

View solution in original post

3 REPLIES 3
jthi
Super User

Re: Efficient way to customize dual-axis graph with markers, colors, and lines in Big Class.jmp (JMP 18.2.1)

In my opinion, it is easiest to do it interactively in JMP once and then copy the script. You can then use that JMP created script in your automated process. 

For example, to edit the lines, you can double click on the legend, select all top/bot lines and modify them at the same time

jthi_0-1755754750949.png

Also, in some cases you might be able to use Presets.

-Jarmo
tsuku24
Level I

Re: Efficient way to customize dual-axis graph with markers, colors, and lines in Big Class.jmp (JMP 18.2.1)

Thank you very much!

This method has improved the operation speed.
As you mentioned, it seems to be the most effective approach.
For example, if we later change the column used for overlay—such as adding a "Nationality" column—we can update the script like this:

 

Item ID( "Mean(体重_TopLine)(性別=F)" ) → Item ID( "Mean(体重_TopLine)(Nationality=JAPAN)" )
Item ID( "Mean(体重_TopLine)(性別=M)" ) → Item ID( "Mean(体重_TopLine)(Nationality=USA)" )

This way, we can easily switch the grouping condition by replacing the label inside the Item ID function.

 

 

jthi
Super User

Re: Efficient way to customize dual-axis graph with markers, colors, and lines in Big Class.jmp (JMP 18.2.1)

If you will always have similarly formatted graphs with the same amount of graphs, you could create functions/expressions to handle it

-Jarmo

Recommended Articles