Subscribe Bookmark RSS Feed

Sorting a Table Box

Apologies for what I have to believe is a trivial question, but I can't see how to do it.  How do I script the sorting of a Table Box by one of its columns?  I know I can do it manually by right-clicking on the Table Box in question and selecting "Sort by Column" from the pop-up menu, so it's certainly possible, but the list of properties of the Table Box doesn't appear to contain any obvious candidates that might perform this action, and the guesses I've tried to date with syntaxes like "tb << sort(by(column(X), order(ascending))", don't work.  What's bothering me is that I'm fairly sure I've done this easily enough at some time in the past, but now I can't find the script.  Can anybody tell me how to do it?  (I'm running JMP 9)

Many thanks.

1 REPLY
ms

Super User

Joined:

Jun 23, 2011

I tried this in JMP 9

tb << sort by column( "X" );

And got this in the log

tb << sort by column( "X" )

/*:

SortByCol not implemented yet

First time I encounter that message. JSL rarely gives any clues why something, apart from syntax errors, is not working. Perhaps someone with access to JMP 10 beta can try if it yet has been implemented there.

So for now you may have to sort the matrices etc. before sending them into a table box.