Share your ideas for the JMP Scripting Unsession at Discovery Summit by September 17th. We hope to see you there!
Choose Language Hide Translation Bar
Highlighted
Level II

how to replicate each run once at time for DSD

i want to create code that helps me to replicate selected run in full factorial design.

For example if i have full factorial design with 4 factors and 16 runs. i want to select one run to be replicated to generate a new matrix. i need do looping to generate 16 matrices based on the original full factorial matrix.

4 REPLIES 4
Highlighted
Staff

Re: how to replicate each run once at time for DSD

1. You want to create an augmented design by replicating one run?
2. You want to augment the original design once for for every run in the original design?
3. Do you want the new designs in their own data table?

Assuming the answer to all these questions is yes, then this script illustrates how it might be done.

``````Names Default to Here( 1 );

// set up example design
design = DOE(
Full Factorial Design,
{Add Response( Maximize, "Y", ., ., . ),
Add Factor( Continuous, {-1, 1}, "X1", 0 ),
Add Factor( Continuous, {-1, 1}, "X2", 0 ),
Add Factor( Continuous, {-1, 1}, "X3", 0 ),
Add Factor( Continuous, {-1, 1}, "X4", 0 ), Set Random Seed( 1338093688 ),
Make Design, Simulate Responses( 0 )}
);

dt = design << Make Table;

design << Close Window;

// assume that orginal design by JMP is available as current data table
factor = dt << Get Column Names( Numeric, String );
Remove From( factor );

// obtain design and remove response column (last data column)
design = dt << Get As Matrix;
design[0,NCol(design)] = [];

// iterate over the rows of the original table
nr = N Row( design );
For( i = 1, i <= nr, i++,
augmented = design |/ design[i,0];
As Table( augmented, << Column Names( factor ) );
);``````

The initial part of the script creates an example. In practice, delete this portion of the script. Create the design with JMP platform and make the table. Then run the remainder of the script.

Learn it once, use it forever!
Highlighted
Level II

Re: how to replicate each run once at time for DSD

Mr.  markbailey

what should i do if i want to change the original matrix ?

what should i do if i want to replicated two runs of the original matrix ?

how to calculate the power analysis, relative standard errors , D_eff and A_eff ?

finally is there any material that helps me to start writing code in JMP script?

thank you

Highlighted
Staff

Re: how to replicate each run once at time for DSD

"what should i do if i want to change the original matrix ?"

The original matrix is based on the design saved to a JMP data table. Therefore, the script works with any data table made from a JMP design platform.

"what should i do if i want to replicated two runs of the original matrix ?"

You could duplicate two rows at a time with a second, nest iteration. The exact iteration would depend on whether you wanted all combinations.

"how to calculate the power analysis, relative standard errors , D_eff and A_eff ?"

Launch the Evaluate Design platform on each of the resulting data tables. This  platform provides the same information as found in the Design Evaluation outline when you design an experiment with JMP.

"finally is there any material that helps me to start writing code in JMP script?"

Sure, see Help > JMP Document Library > Scripting Guide book. We also provide instructor-based training for scripting.

Learn it once, use it forever!
Highlighted
Level II

Re: how to replicate each run once at time for DSD

Sir, I have tried to add more loop unfortunately it did not work with me

could you please help me how to write code for selecting two different rows for each iteration.

another helping request how can i use the previous example for different matrix that not including in JMP?

cheers

Article Labels

There are no labels assigned to this post.