If a tangent line on a graph is needed, a little more work is required. Here is a code snippet example using drawing tools:
function DrawTangent(inwave,xpos, arrowscale) wave inwave variable xpos, arrowscale Duplicate/FREE inwave, dinwave Differentiate wave0 /D=dinwave SetDrawLayer/W=Graph0 /K userfront SetDrawEnv/W=Graph0 xcoord= bottom,ycoord= left,arrow= 1, save DrawLine/W=Graph0 xpos, inwave(xpos), xpos+arrowscale, inwave(xpos)+arrowscale*dinwave(xpos) end
This has the feature that resizing the graph will maintain the tangent appearance of the added line. Modify to your taste, and flexibility requirements.
The
Differentiate
command is available via the Analysis menuJuly 20, 2011 at 01:34 pm - Permalink
wave inwave
variable xpos, arrowscale
Duplicate/FREE inwave, dinwave
Differentiate wave0 /D=dinwave
SetDrawLayer /W=Graph0 /K userfront
SetDrawEnv/W=Graph0 xcoord= bottom,ycoord= left,arrow= 1, save
DrawLine/W=Graph0 xpos, inwave(xpos), xpos+arrowscale, inwave(xpos)+arrowscale*dinwave(xpos)
end
This has the feature that resizing the graph will maintain the tangent appearance of the added line. Modify to your taste, and flexibility requirements.
July 21, 2011 at 07:02 am - Permalink
July 21, 2011 at 10:01 am - Permalink
Thanks all of you
July 21, 2011 at 12:22 pm - Permalink