For the latest version of JMP Help, visit JMP.com/help.


Scripting Guide > Scripting Tools > Work with the Script Editor > Match Parentheses, Brackets, and Braces
Publication date: 07/24/2024

Match Parentheses, Brackets, and Braces

The script editor helps you match fences (or parentheses, square brackets, and braces) in the following ways:

The matching closing fence is added when you type an opening fence.

When you click next to either an opening or closing fence, the fence and its match are highlighted in blue. If the fence does not have a match, it is highlighted in red.

If you double-click a fence, everything between the matching fence is selected (including the fences).

If you put your cursor within an expression and press Ctrl+] on Windows (Command+B on macOS), the entire expression is selected. Fences that enclose the expression are included. Repeat this process to highlight the next-higher expression. Figure 4.6 shows an example.

Figure 4.6 Each Step in Matching Fences 

Each Step in Matching Fences

When you type an opening brace, JMP adds the closing brace. Enter code between the braces, type the closing brace, and then your cursor automatically moves after the closing brace that JMP added. This prevents you from accidentally adding an unnecessary closing brace.

You can turn on and off the autocompletion of braces in the JMP preferences. See Set Preferences for the Script Editor.

Want more information? Have questions? Get answers in the JMP User Community (community.jmp.com).