cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
  • Instantly extract effect sizes, F-ratios, and FDR-adjusted p-values from your models with the Calculate Effects Sizes extension, available now in the JMP Marketplace!
  • New to JMP? Join us Sept. 23-24 for the Early User Edition of Discovery Summit, tailor-made for new users. Register now for free!
  • Your voice matters! Tell us how you prefer to receive JMP updates, so we can tailor our communication to your needs. Take short survey.

Discussions

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

Is there a way to reference the current column name in a formula?

Hi - I'd like to be able to reference the name of a column in a data table to which a formula has been applied, in much the same way that the row() function returns the current row. I want to be able to do it so that I can copy the column properties of a single column of one data table to multiple columns of another data table with a different set of names (which I don't know in advance, but which I know will have a certain structure), and then use those names to determine what action is to be performed by the formula.

 

For example, if the column name has a "1" in it then I want to evaluate formula A, whereas if it contains a "2" then I want to evaluate formula B. I could set up all the possible options within a single formula with a set of if-then-else clauses or a choose() function, if I can reference the column name from within the formula.

 

Can it be done? I have a feeling this could well be one of those questions that invites a one-line reply demonstrating that it's trivial, so apologies in advance if it is.

 

Many thanks

1 REPLY 1
Craige_Hales
Super User

Re: Is there a way to reference the current column name in a formula?

It sounds like the formula needs to change what it does based on its column name. Would it be possible to use the column name at <<setFormula time to choose a simpler formula?

 

 

Craige

Recommended Articles