Categorical Factor, Controlling probability by scriptI am tring to make automation code to control the nominal values by the script.
For the simulator, I want to set the probability of the values. However, it doesnt seem to work.
How can I control categorized values probability with the script ?
prf = Profiler(
Y( :Pred Formula Eye Height, :Pred Formula Eye Width ),
Profiler(
1,
Term Value(
Duty Cycle(0.48, Lock( 0 ), Show( 1 )),
Random Jitter(0.04, Lock( 0 ), Show( 1 )),
Deterministic Jitter(0, Lock( 0 ), Show( 1 )),
Process Variation("Normal", Lock( 0 ), Show( 1 )),
Temperature(11.25, Lock( 0 ), Show( 1 )),
Voltage(1.0, Lock( 0 ), Show( 1 ))
),
Simulator(
1,
Factors(
Duty Cycle << Random( Normal( 0.48, 0.08 ) ),
Random Jitter << Random( Normal( 0.04, 0.05 ) ),
Deterministic Jitter << Random( Normal( 0, 0 ) ),
<FONT face="arial black,avant garde">Process Variation << Distribution( {"Fast", "Slow", "Normal"}, [0.33, 0.33, 0.34] )</FONT>,
Temperature << Random( Normal( 11.25, 2 ) ),
Voltage << Random( Normal( 1.0, 0.05 ) )
),
Responses(
Pred Formula Eye Height << No Noise,
Pred Formula Eye Width << No Noise
)
)
)
);Automation and ScriptingRe: Categorical Factor, Controlling probability by scriptCould the issue be that you have Profiler twice? This is an example from Scripting Index which seems to send the Simulator after Profiler has been created
Names Default To Here(1);
dt = Open("$SAMPLE_DATA/Tiretread.jmp");
obj = Profiler(
Y(
:Pred Formula ABRASION, :Pred Formula MODULUS, :Pred Formula ELONG,
:Pred Formula HARDNESS
)
);
obj << Simulator(
1,
Factors(
SILICA << Random(Normal(1.25, 0.3266)),
SILANE << Random(Normal weighted(50, 6.532)), SULFUR << Fixed(2.25)
),
Responses(
Pred Formula ABRASION << No Noise, Pred Formula MODULUS << No Noise,
Pred Formula ELONG << No Noise, Pred Formula HARDNESS << No Noise
)
);
But I would guess you could just move it inside the Profiler message
Names Default To Here(1);
dt = Open("$SAMPLE_DATA/Tiretread.jmp");
obj = Profiler(
Y(
:Pred Formula ABRASION, :Pred Formula MODULUS, :Pred Formula ELONG,
:Pred Formula HARDNESS
),
Term Value(
SILICA(1.75, Lock(0), Show(1)),
SILANE(45.2, Lock(0), Show(1)),
SULFUR(2.45, Lock(0), Show(1))
),
Simulator(
1,
Factors(
SILICA << Random(Normal(1.25, 0.3266)),
SILANE << Random(Normal weighted(50, 6.532)), SULFUR << Fixed(2.25)
),
Responses(
Pred Formula ABRASION << No Noise, Pred Formula MODULUS << No Noise,
Pred Formula ELONG << No Noise, Pred Formula HARDNESS << No Noise
)
)
);
Re: Categorical Factor, Controlling probability by scriptHi thanks for the fast reply.
I was curious how I could control the probability of factor Process variation.
this have 3 discrete value fast, normal, slow.
I want to simulate it with specific probability with script.
however with below syntax. It does not work.
Can I Get help for the right syntax? I cannot find any regarding function for it
Process Variation << Distribution( {"Fast", "Slow", "Normal"}, [0.33, 0.33, 0.34] )Re: Categorical Factor, Controlling probability by scriptHave you done it in JMP interface and then saved the script? It should have the correct syntax for you to use