共用方式為


效能公式 (Chart 控制項)

效能公式會相較於歷程資料計算價格變動率。不同於變動率公式,它會對第一個可用資料計算變動率。輸出為百分比。

這個公式也可用來計算交易量變動率。

效能指標的範例圖

公式詳細資料

語法

Chart.DataManipulator.FinancialFormula(
    FinancialFormula.Performance,
    "Price",
    "Performance")

輸入值

這個公式接受一個輸入 Y 值。

  • Price
    計算效能指標的價格。它可以是您想要計算效能指標的任何其他資料,例如成交量。

輸出值

這個公式輸出一個 Y 值。

  • Performance
    效能指標。

備註

折線圖類型是方便顯示公式輸出的圖表類型。

範例

下列範例會從 Series1 的 Y 值接受每日收盤價的輸入 (Series1:Y4),然後將效能指標輸出至 Series3 (Series3:Y)。

Chart1.DataManipulator.FinancialFormula (FinancialFormula.Performance, "Series1:Y4", "Series3:Y")
Chart1.DataManipulator.FinancialFormula (FinancialFormula.RateOfChange, 5, "Series1:Y4", "Series3:Y");

請參閱

參考

System.Windows.Forms.DataVisualization.Charting

System.Web.UI.DataVisualization.Charting

其他資源

財務公式

套用公式