Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

- JMP User Community
- :
- Discussions
- :
- Re: How to Constraint Factors to not be specific states

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page

Highlighted

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

Aug 28, 2020 10:15 PM
(193 views)

Hello all,

I am a novice and I am actually trying to set up my first DOE using JMP.

I would like to setup a couple of constraints for two of my factors and I cannot get it to work.

I have 3 factors where x1 can only be 0 and 1, while x2 and x3 can be -1,0,1.

*The first constraint is when x1 is 0, x2 and x3 can only be -1 or 0.

Similarly, when x1 is 1, then x2 and x3 can only be -1 or 1.

*The other constraint is x2 and x3 cannot be -1 at the same time, regardless of what x1 is.

I feel like the logic is straight forward but I do not know how the script coding works and the logic structure I put in doesn't compile.

Any help would greatly be appreciated; if this is even possible in JMP

Regards,

KVH

1 ACCEPTED SOLUTION

Accepted Solutions

Highlighted

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

The means of defining constraints depends on the type of the factors involved. You talk about specific levels so it seems you are thinking about categorical factors and disallowed combinations.

Also, adding constraints to the factor combinations will limit the effects that may be estimated.

I used the disallowed combinations filter in Custom Design to specify your constraints. It looks like this picture when set up correctly:

The result is this D-optimal design in 18 runs:

I include a script below that will produce the same Custom Design platform so that you can modify anything you like:

```
DOE(
Custom Design,
{Add Response( Maximize, "Y", ., ., . ),
Add Factor( Categorical, {"0", "1"}, "X1", 0 ),
Add Factor( Categorical, {"-1", "0", "1"}, "X2", 0 ),
Add Factor( Categorical, {"-1", "0", "1"}, "X3", 0 ),
Set Random Seed( 281228126 ), Number of Starts( 12705 ), Add Term( {1, 0} ),
Add Term( {1, 1} ), Add Term( {2, 1} ), Add Term( {3, 1} ),
Add Alias Term( {1, 1}, {2, 1} ), Add Alias Term( {1, 1}, {3, 1} ),
Add Alias Term( {2, 1}, {3, 1} ), Set Sample Size( 18 ),
Disallowed Combinations(
X1 == "0" & X2 == "1" | X1 == "0" & X3 == "1" | X1 == "1" & X2 == "0" | X1
== "1" & X3 == "0" | X2 == "-1" & X3 == "-1"
), Simulate Responses( 0 ), Save X Matrix( 0 )}
);
```

Learn it once, use it forever!

1 REPLY 1

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

The means of defining constraints depends on the type of the factors involved. You talk about specific levels so it seems you are thinking about categorical factors and disallowed combinations.

Also, adding constraints to the factor combinations will limit the effects that may be estimated.

I used the disallowed combinations filter in Custom Design to specify your constraints. It looks like this picture when set up correctly:

The result is this D-optimal design in 18 runs:

I include a script below that will produce the same Custom Design platform so that you can modify anything you like:

```
DOE(
Custom Design,
{Add Response( Maximize, "Y", ., ., . ),
Add Factor( Categorical, {"0", "1"}, "X1", 0 ),
Add Factor( Categorical, {"-1", "0", "1"}, "X2", 0 ),
Add Factor( Categorical, {"-1", "0", "1"}, "X3", 0 ),
Set Random Seed( 281228126 ), Number of Starts( 12705 ), Add Term( {1, 0} ),
Add Term( {1, 1} ), Add Term( {2, 1} ), Add Term( {3, 1} ),
Add Alias Term( {1, 1}, {2, 1} ), Add Alias Term( {1, 1}, {3, 1} ),
Add Alias Term( {2, 1}, {3, 1} ), Set Sample Size( 18 ),
Disallowed Combinations(
X1 == "0" & X2 == "1" | X1 == "0" & X3 == "1" | X1 == "1" & X2 == "0" | X1
== "1" & X3 == "0" | X2 == "-1" & X3 == "-1"
), Simulate Responses( 0 ), Save X Matrix( 0 )}
);
```

Learn it once, use it forever!