cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
  • Learn how to build custom Python data connectors and further customize JMP’s Data Connector Framework with the Python Data Connector Demo, available now in the JMP Marketplace!
  • See how to create experiments to support product design and ID useful product features. Register for June 12 webinar, 2pm US Eastern Time.

Discussions

Solve problems, and share tips and tricks with other JMP users.
Choose Language Hide Translation Bar
TimeTortoise
Level I

Assigning values to new column based on 3 exsisting columns that are a result of a binning formula

Hi JMP Community,

 

I am trying to find a clean way to assign a value to a column based on values of 3 columns which have been created using JMP's binning formula. Specifically, my team has found that 3 raw material metrics influence how our process runs best (the first one grouped into 4 categories & the other two grouped into 2 categories, giving a total of 16 categories). We would like to mine our historical process data and assign a Bin it. Any suggestions on what tool might be able to help do this?

 

Attached is a snip showing how our bin's are structured.

 

Best -TimeTortise

1 ACCEPTED SOLUTION

Accepted Solutions
txnelson
Super User

Re: Assigning values to new column based on 3 exsisting columns that are a result of a binning formula

I didn't test this formula for your final bin column, but it should work

 

As Constant(
	combos = {"HighHighHigh", "HighHigBaseline", "HighBaselineHigh", "HighBaselineBaseline", 
	"ElevatedHighHigh", "ElevatedHigBaseline", "ElevatedBaselineHigh", "ElevatedBaselineBaseline", 
	"BaselineHighHigh", "BaselineHigBaseline", "BaselineBaselineHigh", "BaselineBaselineBaseline", 
	"UnknownHighHigh", "UnknownHigBaseline", "UnknownBaselineHigh", "UnknownBaselineBaseline"};
	binList = "ABCDEFGHIJKLMNOP";
);

"Bin " || Substr( binList, Contains( combos, :Moisture || :Mw || :LOI ), 1 );
Jim

View solution in original post

3 REPLIES 3
jthi
Super User

Re: Assigning values to new column based on 3 exsisting columns that are a result of a binning formula

For which column are you looking the values for? And what do you consider "clean"? If it is a Bin column you could: concatenate all the three columns together to create a new column. Then map that to bin values using Match() in a formula or by using Value Codes column property. You could also just create mapping table and use Join/Update to add the binning values

-Jarmo
txnelson
Super User

Re: Assigning values to new column based on 3 exsisting columns that are a result of a binning formula

I didn't test this formula for your final bin column, but it should work

 

As Constant(
	combos = {"HighHighHigh", "HighHigBaseline", "HighBaselineHigh", "HighBaselineBaseline", 
	"ElevatedHighHigh", "ElevatedHigBaseline", "ElevatedBaselineHigh", "ElevatedBaselineBaseline", 
	"BaselineHighHigh", "BaselineHigBaseline", "BaselineBaselineHigh", "BaselineBaselineBaseline", 
	"UnknownHighHigh", "UnknownHigBaseline", "UnknownBaselineHigh", "UnknownBaselineBaseline"};
	binList = "ABCDEFGHIJKLMNOP";
);

"Bin " || Substr( binList, Contains( combos, :Moisture || :Mw || :LOI ), 1 );
Jim
TimeTortoise
Level I

Re: Assigning values to new column based on 3 exsisting columns that are a result of a binning formula

Jim,

 

Thanks that is a very clever use of those two functions! I will need to rewrite for my table but it is more than enough to get me on the right path. I would never have thought of such an elegant solution.

 

Best -Ben

Recommended Articles