【お知らせ】この部分は英語原文のみでの提供となります。何卒ご了承ください。
2.1.17.2.3.2 curve_derivative
Contents
Description
Simple derivative calculations without smoothing. Missing values are ignored.
Derivative is computed by taking the average of the two data points slopes from the previous and next data points.
Syntax
bool curve_derivative( curvebase & cuv )
Parameters
- cuv
- [modify] curve of Y data, result of derivatives are put back to replace original data
Return
FALSE if not enough data to compute derivatives, else return TRUE
Examples
EX1
void curve_derivative_ex1() { vector vx, vy; vx.Data(-4.5, 6.7, 0.23); vy.Data(1, vx.GetSize()); Curve crv(vx, vy); vector vderiv; vderiv = vy; if(curve_derivative(crv)) { Worksheet wks; wks.Create(); wks.SetSize(-1, 3); Dataset da(wks, 0); da = vx; Dataset db(wks, 1); db = vy; Dataset dc(wks, 2); vderiv = crv; dc = vderiv; } }
Remark
See Also
Header to Include
origin.h