Author |
Topic  |
|
magr0046
Germany
Posts |
Posted - 11/20/2007 : 08:50:03 AM
|
Hi all!
I have the following problem: I took PL spectra (col(A)=wavelength;col(B)=intensity) as a function of the temperature at 44 different temperatures. I am interested in the dependence of FWHM and maximum position from the temperature. Therefore I have to integrate on several series of 44 datasheets. As area, FWHM, maximum intensity and position of maximum intensity are stored in the integ.properties, I wanted to realize the integration by a simple for loop. This is my code
for (n=1 ; n<=5 ; n++){type " $(n) -- integrating data$(n+48)_B data$(n+48)_B[1]=$(data$(n+48)_B[1]) " integrate data$(n+48)_B}
I know, this code might be quite simple compared to what is normally posted, but I don't understand some things: I can read out single datapoints by (e.g.) $(data$(n+48)_B[1], but I dont manage to integrate the data using nearly the same data$(n+48)_B.
Once the integration is performed, I want to put the integ.properties into a new worksheet. I hope this could be realized using something like data1_B[$(n)]=integ.area
So thanks for your opinion. |
|
Mike Buess
USA
3037 Posts |
Posted - 11/20/2007 : 09:17:10 AM
|
integrate data$(n+48)_B will work if data$(n+48) is a valid worksheet. Note that your script requires a semicolon ';' before the integrate command.
for (n=1 ; n<=5 ; n++){type " $(n) -- integrating data$(n+48)_B data$(n+48)_B[1]=$(data$(n+48)_B[1]) "; integrate data$(n+48)_B}
quote: Once the integration is performed, I want to put the integ.properties into a new worksheet. I hope this could be realized using something like data1_B[$(n)]=integ.area
That will work but you don't need to substitute the variable n...
data1_B[n]=integ.area;
Mike Buess Origin WebRing Member
Edited by - Mike Buess on 11/20/2007 09:19:15 AM |
 |
|
magr0046
Germany
Posts |
Posted - 11/20/2007 : 09:27:54 AM
|
Thank you for your short term answer. I inserted the missing semicolon, but the result is still a #command error.
(data$(n+48) is supposed to be a valid worksheet, as I have worksheet names varying from data49 to data90 approx, but I got the command error.
Nevertheless is works sometimes. Thank you for the help.
Edited by - magr0046 on 11/20/2007 12:40:59 PM |
 |
|
|
Topic  |
|
|
|