Hi @DivisiveFerret8.,
I don't know of a fast way to do this interactively in JMP, but with some jsl we can make those columns quickly:
Names Default to Here (1);
dt = Current Data Table();
// Get the number of columns
ncols = N Col( dt );
// Nested loop to go through all pairwise combinations of columns
For( i = 1, i < ncols, i++,
For( j = i + 1, j <= ncols, j++,
colName1 = Column( dt, i ) << get name;
colName2 = Column( dt, j ) << get name;
// create new column
newColName = colName1 || " + " || colName2;
dt << New Column( newColName, Numeric, "Continuous", Format( "Best", 12 ) );
// compute the sum
Column( dt, newColName ) << set each value(
Column( dt, colName1 )[Row()] + Column( dt, colName2 )[Row()]
);
)
);
//EDIT//
The above code is for all combinations of columns in the table, but I see now you were asking about a group of columns:
Names Default to Here (1);
dt = Current Data Table();
// List of specific columns
// columns = {"Column A", "Column B", "Column C", "Column D", "Column E", "Column F", "Column G", "Column H", "Column I", "Column J"};
// Using selected columns
// columns = dt << Get Selected Columns;
// Referencing by Group Name
columns = dt << get column group( "XY" );
// Number of specific columns
ncols = N Items( columns );
// Nested loop to go through all pairwise combinations of specified columns
For( i = 1, i < ncols, i++,
For( j = i + 1, j <= ncols, j++,
colName1 = columns[i]<<Get Name;
colName2 = columns[j]<<Get Name;
// create new column
newColName = colName1 || " + " || colName2;
dt << New Column( newColName, Numeric, "Continuous", Format( "Best", 12 ) );
// compute the sum
Column( dt, newColName ) << set each value(
Column( dt, colName1 )[Row()] + Column( dt, colName2 )[Row()]
);
)
);
I left some other options in there, like a list of specific columns, or using selected columns.
I hope this helps!
@julian