Hi. I am new to labtalk and hope somebody can help me out with this. I will appreciate your help a lot.
So, by looking up the manaul, it said I should use the following code for smoothing a curve: layer -c; // Count the number of data plots in the layer and save result in variable "count" string gname$ = %H; // Get the name of this Graph page newbook na:=Smoothed; // Create a new book named smooth - actual name is stored in bkname$ wks.ncols=0; // Start with no columns loop(ii,1,count) { range riy = [gname$]!$(ii); // Input Range refers to 'ii'th plot range roy = [bkname$]!($(ii*2-1),$(ii*2)); // Output Range refers to two, new columns smooth iy:=riy meth:=sg poly:=3 oy:=roy; // Savitsky-Golay smoothing using third order polynomial }
However, this is only the Savitsky-Golay method. What code should I use to replace the last line if I want to do average adjacent method?