.. highlightlang:: us .. index:: auto_xy_LinearInterpolation .. _auto_xy_linearinterpolation: auto_xy_LinearInterpolation =========================== .. us.tag auto_xy_LinearInterpolation NOTREADYENGLISH auto_xy New300 The function is obsolete. New scripts should use the :ref:`XYSetFilterFunctions` function. :ref:`auto_xy_LinearInterpolation` calculates linear interpolated points for a given x/y curve. The x-coordinates must be increasing. .. function:: hDataNew = auto_xy_LinearInterpolation(hData_Layer, bNewDataset, nType, rvPoints) .. us.return **Return Value** *hDataNew* is the handle of the newly created dataset. .. us.params **Parameters** .. uparam:: hData_Layer *hData_Layer* is either the dataset handle *hData*, or a vector with the handles of the dataset and a diagram ([hData, hLayer]). If only a dataset handle is given, the dataset will be inserted to the diagram where *hData* is found. If called with [*hData*, *hLayer*], the new dataset will be inserted to the diagram *hLayer*. .. uparam:: bNewDataset *bNewDataset* .. uparam:: nType *nType* nType = 1 or nType = 2 .. uparam:: rvPoints *rvPoints* The meaning of *rvPoints* depends on the value of *nType*. If *nType* = 1 .. us.comment **Comment** The dataset with the handle *hData* must always be assigned to a diagram or else all ``auto_xy_``-functions will return the value 0 (Dataset could not be created). .. us.example **Example** Create a new dataset with 100 points, evenly distributed over the x range: :: auto_xy_LinearInterpolation(hData_Layer, TRUE, 1, 100) Create a new dataset with the x-coordinates 1.5, 2, 2.5 :: auto_xy_LinearInterpolation(hData_Layer, TRUE, 2, [1.5,2,2.5]) .. seealso:: :ref:`overview-automation`, :ref:`auto_LoadTemplate`, :ref:`auto_LoadDataset` :sub:`id-2035060`