Modifica la trasparenza dell'area con JSLCIAO,
Sto adattando un modello tramite una variabile di raggruppamento e salvando le formule di previsione e intervallo nella mia tabella. Quindi inserisco la Y originale, la Y prevista e LCL/UCL sull'asse Y e creo un grafico con la variabile di raggruppamento nella funzionalità Wrap (vedi il codice qui sotto per un esempio).
Ciò che desidero è poter impostare la trasparenza della mia Area su un valore specifico tramite script. So che posso cliccare con il tasto destro del mouse sulla legenda e modificarla in questo modo, ma questo è per uno script che accetta input utente, quindi non posso usare i normali comandi Invia a Report e Invia, dove richiamo le colonne in modo statico.
<BR />Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA/Diamonds Data.jmp" );
mod = Fit Model(
Y( :Price ),
By( :Color ),
Effects( :Depth ),
Personality( "Standard Least Squares" ),
Emphasis( "Effect Screening" ),
Run(
:Price << {Summary of Fit( 0 ), Analysis of Variance( 0 ), Parameter Estimates( 1 ),
Sorted Estimates( 0 ), Plot Actual by Predicted( 1 ), Plot Regression( 0 ),
Plot Residual by Predicted( 1 )}
)
);
mod << prediction and interval formulas;
Graph Builder(
Size( 1163, 748 ),
Show Control Panel( 0 ),
Show Legend( 0 ),
Variables(
X( :Depth ),
Y( :Price ),
Y( :Pred Formula Price By Color, Position( 1 ) ),
Y( :Lower 95% Mean Price By Color, Position( 1 ) ),
Y( :Upper 95% Mean Price By Color, Position( 1 ) ),
Wrap( :Color ),
Overlay( :Color )
),
Elements(
Points( X, Y( 1 ), Legend( 7 ) ),
Line( X, Y( 2 ), Legend( 9 ) ),
Area( X, Y( 3 ), Y( 4 ), Legend( 10 ), Area Style( "Range" ), Transparency(0.25) )
)
);
Automazione e scriptingRe: Modificare la trasparenza dell'area con JSLPuoi cercare PolySegs e quindi impostare la loro trasparenza
Names Default To Here(1);
dt = Open("$SAMPLE_DATA/Diamonds Data.jmp");
mod = dt << Fit Model(
Y(:Price),
By(:Color),
Effects(:Depth),
Personality("Standard Least Squares"),
Emphasis("Effect Screening"),
Run(
:Price << {Summary of Fit(0), Analysis of Variance(0), Parameter Estimates(1),
Sorted Estimates(0), Plot Actual by Predicted(1), Plot Regression(0),
Plot Residual by Predicted(1)}
)
);
mod << prediction and interval formulas;
gb = dt << Graph Builder(
Size(1163, 748),
Show Control Panel(0),
Show Legend(0),
Variables(
X(:Depth),
Y(:Price),
Y(:Pred Formula Price By Color, Position(1)),
Y(:Lower 95% Mean Price By Color, Position(1)),
Y(:Upper 95% Mean Price By Color, Position(1)),
Wrap(:Color),
Overlay(:Color)
),
Elements(
Points(X, Y(1), Legend(7)),
Line(X, Y(2), Legend(9)),
Area(X, Y(3), Y(4), Legend(10), Area Style("Range"))
)
);
fbs = Report(gb) << XPath("//FrameBox");
For Each({fb}, fbs,
ps = fb << Find Seg(PolySeg(1));
If(!IsEmpty(ps),
ps << Transparency(0.25);
);
);