大家好,
我有一个包含许多输出的实验,我想获取脚本中预测公式给出的值,以将它们发送到数据表。 有人知道该怎么做吗?
谢谢,
何塞·安吉尔
在你的脚本中尝试这个
rfit = fit << Report;
pf=rfit["Prediction Profiler"] << get scriptable object;
pf << Remember Settings;
dtout = (rfit["Prediction Profiler"]["Remembered Settings"][Table Box(1)]<< Make Into Data Table);
将模型保存为列公式的建议是一个很好的建议。 有很多使用方法。
此示例说明了如何以另一种方式直接获取分析器中显示的值:
Names Default to Here( 1 );
dt = Open( "$SAMPLE_DATA/Big Class.jmp" );
fit = dt << Fit Model(
Y( :weight ),
Effects( :age, :sex, :height ),
Personality( "Standard Least Squares" ),
Emphasis( "Minimal Report" ),
Run(
Profiler(
1,
Confidence Intervals( 1 ),
Term Value(
age( 12, Lock( 0 ), Show( 1 ) ),
sex( "F", Lock( 0 ), Show( 1 ) ),
height( 62.55, Lock( 0 ), Show( 1 ) )
)
),
:weight << {Summary of Fit( 1 ), Analysis of Variance( 1 ),
Parameter Estimates( 1 ), Scaled Estimates( 0 ),
Plot Actual by Predicted( 1 ), Plot Regression( 0 ),
Plot Residual by Predicted( 1 ), Plot Studentized Residuals( 0 ),
Plot Effect Leverage( 1 ), Plot Residual by Normal Quantiles( 0 ),
Box Cox Y Transformation( 0 )}
)
);
fit rep = fit << Report;
prediction = Num( fit rep["Prediction Profiler"][AxisBox(1)][TextBox(2)] << Get Text );如果您选择旁边的红色三角形响应>保存列>预测公式,它将向您的数据表添加一列,其中包含预测公式。 如果右键单击该列,然后转到公式(旁边会有一个复选标记),您可以查看公式。