cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Check out the JMP® Marketplace featured Capability Explorer add-in
Choose Language Hide Translation Bar
Mauro_Gerber
Level IV

concatenate / save and evaluate formulas

When manually concatenate two tables there is an option to “save and evaluate formulas” so the formulas in the new or appended date gets evaluated.

In JSL this option is not available only “keep formula” witch suppresses the evaluation.

 

dt_1 << Concatenate(dt_2,Append to first table,save and evaluate formulas(1)); // this is not possible

I know that you can use:

 

dt_1:mycol << Suppress Eval( 0 );
dt_1:mycol << Eval Formula(1);

 

To get tho the same result as with the manual option, but I must search and do this for each column with a formula.

 

Is there a hidden function or plans to include it in Concatenate as an option?

"I thought about our dilemma, and I came up with a solution that I honestly think works out best for one of both of us"
- GLaDOS
1 ACCEPTED SOLUTION

Accepted Solutions
Jeff_Perkinson
Community Manager Community Manager

Re: concatenate / save and evaluate formulas

Keep Formulas does not supress the evaluation as far as I can tell.

 

Try this script and see that the formula in Row No is evaluated in the resulting table.

 

dt1 = New Table( "One Table",
	Add Rows( 10 ),
	New Column( "Row no",
		Numeric,
		"Continuous",
		Format( "Best", 12 ),
		Formula( Row() )
	)
);

dt2 = New Table( "Another Table",
	Add Rows( 10 ),
	New Column( "Row no",
		Numeric,
		"Continuous",
		Format( "Best", 12 ),
		Formula( Row() )
	)
);

Data Table( "One Table" ) <<
Concatenate(
	Data Table( "Another Table" ),
	Keep Formulas,
	Create source column
);

JMPScreenSnapz041.png

-Jeff

View solution in original post

3 REPLIES 3
Jeff_Perkinson
Community Manager Community Manager

Re: concatenate / save and evaluate formulas

Keep Formulas does not supress the evaluation as far as I can tell.

 

Try this script and see that the formula in Row No is evaluated in the resulting table.

 

dt1 = New Table( "One Table",
	Add Rows( 10 ),
	New Column( "Row no",
		Numeric,
		"Continuous",
		Format( "Best", 12 ),
		Formula( Row() )
	)
);

dt2 = New Table( "Another Table",
	Add Rows( 10 ),
	New Column( "Row no",
		Numeric,
		"Continuous",
		Format( "Best", 12 ),
		Formula( Row() )
	)
);

Data Table( "One Table" ) <<
Concatenate(
	Data Table( "Another Table" ),
	Keep Formulas,
	Create source column
);

JMPScreenSnapz041.png

-Jeff
Mauro_Gerber
Level IV

Re: concatenate / save and evaluate formulas

THX for your quick reply, your example works fine, I even preset the column to "supress eval" and it evaluate it after the concat.
So my table has a formula, but it's not executed and is still supressed after the concat. I found earlyer a mention that it could be a time issue that the table hasn't time to evaluate the column and is somehow stuck. I will investigate further.

"I thought about our dilemma, and I came up with a solution that I honestly think works out best for one of both of us"
- GLaDOS
Mauro_Gerber
Level IV

Re: concatenate / save and evaluate formulas

I could follow the datamanipulation and found the "problem"

 

I make a subset of an existing data table  and clear all the data which locks the formula column and suppresses the evaluation.

Then filling the table with data, but the formula stays empty.

I concatenate multiple of the same tables (append to first table). If the master table has a supressed eval, concat tables are not evaluated either.

 

Allow evaluation of the subset solved the problem.

dt_2 = dt << Subset(Output Table( "temp" ),Selected Rows( 0 ),Rows( [1] ),Selected columns only( 0 ),copy formula(1),link to original data table(0),Suppress formula evaluation( 0 ));

Concat dt_2 has then formula evaluation enabled.

"I thought about our dilemma, and I came up with a solution that I honestly think works out best for one of both of us"
- GLaDOS