cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Choose Language Hide Translation Bar
dfusco923
Level III

Using JMP Script to Populate a Column with Data

In the attached JMP data set there is a Character, Nominal "Cost Set" column.  It is not populated with Data yet. 

 

I have scrip that can populate all the cells with "ETC" :

For Each Row(:Cost Set  =  "ETC")

 

However what I would like to do is if the :Label column is equal to "May ACWP" I'd like to populate the :Cost Set column with "ACWP", otherwise the :Label column = "ETC"

 

Can someone help me with the script to do this?

 

Thanks!

 

 

3 ACCEPTED SOLUTIONS

Accepted Solutions
txnelson
Super User

Re: Using JMP Script to Populate a Column with Data

For Each Row(
     If( :Label == "May ACWP",
          "ACWP",
          "ECT"
     );
);

Please take the time to read the new user documentation, Discovering JMP, available under the Help pull down menu.

Jim

View solution in original post

Re: Using JMP Script to Populate a Column with Data

:Cost Set << Set Each Value( If( Contains( (:label column << Get Name ), "ACWP" ), "ACWP", "ETC" ) )

View solution in original post

dfusco923
Level III

Re: Using JMP Script to Populate a Column with Data

Hello Jim - Sorry for the delayed response thank you for providing the script for this - Dan F.

View solution in original post

4 REPLIES 4
txnelson
Super User

Re: Using JMP Script to Populate a Column with Data

For Each Row(
     If( :Label == "May ACWP",
          "ACWP",
          "ECT"
     );
);

Please take the time to read the new user documentation, Discovering JMP, available under the Help pull down menu.

Jim
dfusco923
Level III

Re: Using JMP Script to Populate a Column with Data

Hello Jim - Sorry for the delayed response thank you for providing the script for this - Dan F.

Re: Using JMP Script to Populate a Column with Data

:Cost Set << Set Each Value( If( Contains( (:label column << Get Name ), "ACWP" ), "ACWP", "ETC" ) )
dfusco923
Level III

Re: Using JMP Script to Populate a Column with Data

Hello Mark - Sorry for the delayed response thank you for providing the script for this - Dan F.