| サイトマップ | |
||
トップ | オブジェクト | プロパティ | メソッド | 定数 |
Function オブジェクトは、Plot オブジェクトにある各種関数ラインのいずれか1つをあらわします。Function オブジェクトには、Line オブジェクトの各種プロパティに加え、回帰線や基準線に固有のプロパティと属性があります。Function オブジェクトには ObjectType プロパティが用意されており、その値は 10 または GPT_FUNCTION になります。
Functions GraphObjects コレクション
|
プロパティ:Application , ChildObjects , Color , Height , Left , Name , NameObject , ObjectType , OwnerGraphObject , Parent , StockScheme, Top , Width |
メソッド:GetAttribute, SelectObject, SetAttribute, SetObjectCurrent |
Function オブジェクトは、以下に示す Functions コレクションから取得します:
Index | Constant | Function |
---|---|---|
1 | SLA_FUNC_REGR | Regression Line |
2 | SLA_FUNC_CONF1 | Upper Confidence Intervals |
3 | SLA_FUNC_CONF2 | Lower Confidence Interval |
4 | SLA_FUNC_PRED1 | Upper Prediction Interval |
5 | SLA_FUNC_PRED2 | Lower Prediction Interval |
6 | SLA_FUNC_QC1 | 1st Reference Line (Upper Specification) |
7 | SLA_FUNC_QC2 | 2nd Reference Line (Upper Control Line) |
8 | SLA_FUNC_QC3 | 3rd Reference Line (Mean) |
9 | SLA_FUNC_QC4 | 4th Reference Line (Lower Control Line) |
10 | SLA_FUNC_QC5 | 5th Reference Line (Lower Specification) |
Function オブジェクトの属性や属性値を取得したり設定するには、多くの場合、GetAttribute メソッドと SetAttribute メソッドを使います。これらの属性を指定するには、Function 属性の定数を使用します。基準線 (Reference Line) のラベルを取得するには、NameObject プロパティを使用しますが、これを使用するには事前にそのラベルが表示されている必要があります。
なお、Function ラインの表示と非表示は、Plot オブジェクトの属性を使用する点に注意してください。
Dim SPRegressionLine Set SPRegressionLine = ActiveDocument.CurrentPageItem.GraphPages(0).Graphs(0).Plots(0).Functions(SLA_FUNC_REGR) SPRegressionLine.SetAttribute(SLA_REGROPTIONS,SLA_REGR_FORPLOT Or FLAG_SET_BIT) SPRegressionLine.SetAttribute(SLA_REGROPTIONS,SLA_REGR_TOAXES Or FLAG_SET_BIT) SPRegressionLine.SetAttribute(SEA_LINETYPE,SEA_LINE_DOTTED) SPRegressionLine.Color = RGB_RED
Dim SPRefLine Set SPRefLine = ActiveDocument.CurrentPageItem.GraphPages(0).Graphs(0).Plots(0).Functions(SLA_FUNC_QC3) SPRefLine.SetAttribute(SLA_QCOPTIONS,SLA_QCOPTS_SHOWQC3 Or FLAG_SET_BIT) SPRefLine.SetAttribute(SEA_LINETYPE,SEA_LINE_DOTTED) SPRefLine.SetAttribute(SLA_PLOTOPTIONS,SLA_FLAG_QCON Or FLAG_SET_BIT) SPRefLine.Color = RGB_BLACK