Search code examples
plotsas-jmp

In JMP, how do make the script general to accommodate different binning?


My data table has this column named "BIN". This BIN column can contain different values, depending on the binning used in that specific data set. Example, it can have values such as "A", "B", "C", etc. Or it can have values as "Grp1", "Grp2", "Grp3", etc.

To make the script general for different kinds of binning, I use the "Standardized" argument for fitting function. Example,

group by (:Name("BIN")), Fit Each Value( Standardized )

or

group by (:Name("BIN")), Fit Spline (1000, Standardized)

In this particular data that I am dealing with. I need to do the same, but with an additional condition: I need to separate the plots per computer used to generate the data. That is, I have this column called "Computer" and the values are the serial of the computer e.g. "CN110012672", "KG84394383", and "GH64578982".

For the meantime, I recorded the scripts and use the following block:

group by( :Name( "BIN" ) ),
Fit Each Value( Standardized ),
Where( :Computer == "CN110012672" ),
SendToReport(
Dispatch(

where dispatch blocks contain all the formatting needed.

My problem is that this code block is not general and will not work if another set of serials are given.

Question: How do I make my code very general to accommodate whatever values there are in the "Computer" column?


Solution

  • I figured it out.

    Simply add the code: By (:Name("Computer")), Fit Where(Standardized),