Hi Karla, These are excellent questions for the mailing list, so I am taking the liberty of CCing my answers to the list. That way, other people can have a chance to answer your excellent questions. On Thursday 31 March 2005 14:10, you wrote:
Hello, I am fairly new to EXAFS data analysis. I am currently working on data that I collected from 10-ID at the APS.
Aha! My new home! I just collected my first spectra from that beamline a couple of weeks ago. ;-)
I have a couple of questions. First, in Artemis, when I click on the "x" buttons to select my k- and r-ranges, the window never seems to correspond to where I clicked. Is this a bug?
Probably not. The default in Artemis is use a Kaiser-Bessel window. The various strange words to describe FT windows ("Kaiser-Bessel", "Hanning", "Welch", and so on) refer to different functional forms for the window. None of the functional forms will be 0 at the specified boundary -- instead they all have window sills that extend a bit below the boundary. Thus, if you use the Kaiser-Bessel window, set kmin=2, and dk=1, the window will become non-zero at about 1.5. In short, it's not a bug. It's an unexpected (for you, at least ;-) feature of the functional form of the window. Try setting dk or dr to 0 then replotting. The FT may not look good, but the window plotted by Artemis will be what I think you were expecting.
Second, why does Artemis allow a physical parameter like sigma squared to be negative?
There are a few ways I could answer this question. I could talk about how Artemis allows arbitrarily sophisticated fitting models where the sophisticated user needs complete freedom to specify the fitting model. But that's a little abstract, so let's consider a slightly more concrete example. Suppose that your sample has some kind of oxygen-coordinated iron atom and you have reason to believe that there is a high level of disorder in the first coordination shell. So you choose to run Feff using some model compound that itself has much disorder in the first shell. You then use the first shell paths that came from the Feff calculation to model your unknown data. In this case a negative sigma^2 might be telling you that your unknown has *less* disorder than you model compound. In more general terms, the negative sigma^2 is probably trying to tell you something. You should remember that sigma^2 is correlated to other terms in the fit, most importantly to the various amplitude terms, such as coordination number and S02. If sigma^2 is negative, then the fitten value for amplitude is probably to small. A negative sigma^2 will puff up the signal to compensate for the amplitude term being rather too small. If Artemis did not allow sigma^2 to go negative, you might never know about this kind of problem. So I would say that this too is a feature of the program and not a bug.
Lastly, I have had a hard time figuring out these math expressions despite reading over the mailing lists. Can you use the ">" sign so that sigma squared is always greater than 0? How else can I write a math expression so that the fitting never gives me a sigma squared that is less than 0? Any help would be greatly appreciated!
Using ">" won't work. ">" is not a symbol in Ifeffit's math parser. This is a topic that has come up many times over the past few years on the mailing list. In fact, I think that someone should write a FAQ entry on this topic. Here are a few suggestions: 1. Guess a parameter like this: "guess ss 0.003", then use it on the sigma^2 line of the path page like this: "abs(ss)". 2. A very similar approach is to use the max function. In the sigma^2 line of the path page, say this: "min(ss, 0)". This can be improved slightly. Doing this: "min(ss, 0.001)" constrains the sigma^2 for the path to be no smaller than 0.001. 3. If you start reading the mailing list archives here: http://millenia.cars.aps.anl.gov/pipermail/ifeffit/2005-February/001650.html you will find a conversation between Matt and Scott about a way to impose a penalty for a sigma^2 being too small rather than forcing to be above a hard boundary. Matt's scheme is kind of involved... If you use any of these approaches, I would encourage you to do so with hesitation. As I mentioned above, the negative sigma^2 is not a short coming of Ifeffit or Artemis. Much more likely, it is useful information that you should heed and use to figure out what shortcoming in your fitting model is leading that to happen. HTH, B -- Bruce Ravel ----------------------------------- bravel@anl.gov -or- ravel@phys.washington.edu Environmental Research Division, Building 203, Room E-165 Argonne National Laboratory phone and voice mail: (1) 630 252 5033 Argonne IL 60439, USA fax: (1) 630 252 9793 My homepage: http://feff.phys.washington.edu/~ravel EXAFS software: http://feff.phys.washington.edu/~ravel/software/exafs/
Karla,
I have a couple of questions. First, in Artemis, when I click on the "x" buttons to select my k- and r-ranges, the window never seems to correspond to where I clicked. Is this a bug?
Probably not. The default in Artemis is use a Kaiser-Bessel window. The various strange words to describe FT windows ("Kaiser-Bessel", "Hanning", "Welch", and so on) refer to different functional forms for ...
I don't understand "the window never seems to correspond to where I clicked". What should happen is this (in order): - you click on the [x] box to the right of a parameter - you click on the plot window - the 'x' (E, k, R) value of the point you clicked on gets written into the entry for the parameter value (to the left of the box). - you re-generate the plot to have this selected value take effect. Is that not what happens? Are you saying that the wrong 'x' value is getting written into the parameter entry or that the window looks different than you think it should? For the negative sigma2 values, I agree with Bruce: it's not a bug, exactly. More generally, it's not trivial for the fitting procedure to know that some variables or even Path Parameters have "unreasonable values" unless a) the program enforces how you model the data (which leads to loss of flexibility) or b) the user explicitly says what "reasonable values" are, either using rigid math expressions or the restraint mechanism. --Matt
On Thursday 31 March 2005 16:14, Matt Newville wrote:
I have a couple of questions. First, in Artemis, when I click on the "x" buttons to select my k- and r-ranges, the window never seems to correspond to where I clicked. Is this a bug?
Probably not. The default in Artemis is use a Kaiser-Bessel window. The various strange words to describe FT windows ("Kaiser-Bessel", "Hanning", "Welch", and so on) refer to different functional forms for ...
I don't understand "the window never seems to correspond to where I clicked". What should happen is this (in order): - you click on the [x] box to the right of a parameter - you click on the plot window - the 'x' (E, k, R) value of the point you clicked on gets written into the entry for the parameter value (to the left of the box). - you re-generate the plot to have this selected value take effect.
Is that not what happens? Are you saying that the wrong 'x' value is getting written into the parameter entry or that the window looks different than you think it should?
Hmmm... I guess I jumped to the conclusion that the issue was with the shape of the window function. It didn't even occur to me that Karla might have been saying that the wrong value was being plucked from the plot into the little entry box. If that's what's happening, then that's a serious bug that I haven't seen before. B -- Bruce Ravel ----------------------------------- bravel@anl.gov -or- ravel@phys.washington.edu Environmental Research Division, Building 203, Room E-165 Argonne National Laboratory phone and voice mail: (1) 630 252 5033 Argonne IL 60439, USA fax: (1) 630 252 9793 My homepage: http://feff.phys.washington.edu/~ravel EXAFS software: http://feff.phys.washington.edu/~ravel/software/exafs/
Yes, and when I regenerate the plot, a window pops up to show what range I picked, right? This window does not intersect at 0 on the Xs I picked. I believe the correct x values are written. Matt Newville wrote:
Karla,
I have a couple of questions. First, in Artemis, when I click on the "x" buttons to select my k- and r-ranges, the window never seems to correspond to where I clicked. Is this a bug?
Probably not. The default in Artemis is use a Kaiser-Bessel window. The various strange words to describe FT windows ("Kaiser-Bessel", "Hanning", "Welch", and so on) refer to different functional forms for ...
I don't understand "the window never seems to correspond to where I clicked". What should happen is this (in order): - you click on the [x] box to the right of a parameter - you click on the plot window - the 'x' (E, k, R) value of the point you clicked on gets written into the entry for the parameter value (to the left of the box). - you re-generate the plot to have this selected value take effect.
Is that not what happens? Are you saying that the wrong 'x' value is getting written into the parameter entry or that the window looks different than you think it should?
For the negative sigma2 values, I agree with Bruce: it's not a bug, exactly. More generally, it's not trivial for the fitting procedure to know that some variables or even Path Parameters have "unreasonable values" unless a) the program enforces how you model the data (which leads to loss of flexibility) or b) the user explicitly says what "reasonable values" are, either using rigid math expressions or the restraint mechanism.
--Matt
At 03:41 PM 3/31/2005 -0700, you wrote:
Yes, and when I regenerate the plot, a window pops up to show what range I picked, right? This window does not intersect at 0 on the Xs I picked. I believe the correct x values are written. I have seen an intermittent bug in which the window displayed is not correct (my students sometimes see it too). Fortunately, the window actually used by the fit is in agreement with the numbers in the boxes. I haven't reported this bug yet because I haven't figured out how to make it reproducible. I use Windows XP with Artemis 0.7.012. This isn't exactly the same problem Karla is having, since mine is quite intermittent and may be related to multiple datasets. I'll try to keep a better eye out for when it arises. --Scott Calvin Sarah Lawrence College
On Thursday 31 March 2005 17:03, Scott Calvin wrote: Karla> Yes, and when I regenerate the plot, a window pops up to show Karla> what range I picked, right? This window does not intersect at Karla> 0 on the Xs I picked. I believe the correct x values are Karla> written. Scott> I have seen an intermittent bug in which the window displayed Scott> is not correct (my students sometimes see it too). Fortunately, Scott> the window actually used by the fit is in agreement with the Scott> numbers in the boxes. I haven't reported this bug yet because I Scott> haven't figured out how to make it reproducible. I use Windows Scott> XP with Artemis 0.7.012. Scott> This isn't exactly the same problem Karla is having, since mine Scott> is quite intermittent and may be related to multiple Scott> datasets. I'll try to keep a better eye out for when it arises. One or more of us is not expression him/herself clearly -- I say this because I am now quite confused. To use the example of kmin, the functional forms of most of the window functions are such that they go to zero at kmin-dk/2. It's always been this way. The exception is the sine window, but it doesn't go to zero at kmin, either. I suppose that I might be missing the point entirely, so I'll leave it with this: without a convincing screen shot demonstrating the problem, I am going to assume that there isn't one. B -- Bruce Ravel ----------------------------------- bravel@anl.gov -or- ravel@phys.washington.edu Environmental Research Division, Building 203, Room E-165 Argonne National Laboratory phone and voice mail: (1) 630 252 5033 Argonne IL 60439, USA fax: (1) 630 252 9793 My homepage: http://feff.phys.washington.edu/~ravel EXAFS software: http://feff.phys.washington.edu/~ravel/software/exafs/
Here's a screenshot; this is the result after "Plot R" has been pressed. I'll try to whittle the project file down to the minimum necessary to generate the problem and then send it to you. --Scott Calvin Sarah Lawrence College At 05:34 PM 3/31/2005 -0600, Bruce wrote:
I suppose that I might be missing the point entirely, so I'll leave it with this: without a convincing screen shot demonstrating the problem, I am going to assume that there isn't one.
Oops--left off the attachment. :( Here it is. --Scott Calvin Sarah Lawrence College At 07:09 PM 3/31/2005 -0500, you wrote:
Here's a screenshot; this is the result after "Plot R" has been pressed. I'll try to whittle the project file down to the minimum necessary to generate the problem and then send it to you.
--Scott Calvin Sarah Lawrence College
Scott: My screenshots were from athena. I will check artemis on Linux as well. Carlo On Thu, 31 Mar 2005, Scott Calvin wrote:
Oops--left off the attachment. :( Here it is.
--Scott Calvin Sarah Lawrence College
At 07:09 PM 3/31/2005 -0500, you wrote:
Here's a screenshot; this is the result after "Plot R" has been pressed. I'll try to whittle the project file down to the minimum necessary to generate the problem and then send it to you.
--Scott Calvin Sarah Lawrence College
-- Carlo U. Segre -- Professor of Physics Associate Dean for Special Projects, Graduate College Illinois Institute of Technology Voice: 312.567.3498 Fax: 312.567.3494 Carlo.Segre@iit.edu http://www.iit.edu/~segre
Bruce et al: The screenshot did not come through to me but I can tell you what I have discovered for the Kaiser-Bessel function: 1. in Chi(k) the window starts to drop at the selected value. It reaches zero a bit lower (higher) than the value set. In k-space, it is hard to see this because of the scale but if you zoom, you can see that the drop takes about 0.05 delta k. See the "k-space.png" attachment where the window is set to 2.997. 2. in Chi(R) the window function seems to start dropping a bit further out than the set point. See the "r-space.png" attachment where the window point is at 1.009. Again it drops in a finite distance of about 0.02 in delta r. In the r-space case the drop is much more noticeable because the drop starts beyond the window set point. Hope this helps. Carlo On Thu, 31 Mar 2005, Scott Calvin wrote:
Here's a screenshot; this is the result after "Plot R" has been pressed. I'll try to whittle the project file down to the minimum necessary to generate the problem and then send it to you.
--Scott Calvin Sarah Lawrence College
At 05:34 PM 3/31/2005 -0600, Bruce wrote:
I suppose that I might be missing the point entirely, so I'll leave it with this: without a convincing screen shot demonstrating the problem, I am going to assume that there isn't one.
_______________________________________________ Ifeffit mailing list Ifeffit@millenia.cars.aps.anl.gov http://millenia.cars.aps.anl.gov/mailman/listinfo/ifeffit
-- Carlo U. Segre -- Professor of Physics Associate Dean for Special Projects, Graduate College Illinois Institute of Technology Voice: 312.567.3498 Fax: 312.567.3494 Carlo.Segre@iit.edu http://www.iit.edu/~segre
Carlo,
The screenshot did not come through to me but I can tell you what I have discovered for the Kaiser-Bessel function:
1. in Chi(k) the window starts to drop at the selected value. It reaches zero a bit lower (higher) than the value set. In k-space, it is hard to see this because of the scale but if you zoom, you can see that the drop takes about 0.05 delta k. See the "k-space.png" attachment where the window is set to 2.997.
It's probably that 0.05Ang^-1 is the spacing between points in k-space, so you're just seeing the line that join two successive points. The danger of looking too closely! --Matt
Agreed, I also checked artemis later with a single data set and i did not see anything like Scott showed in his screenshot. Carlo On Thu, 31 Mar 2005, Matt Newville wrote:
Carlo,
The screenshot did not come through to me but I can tell you what I have discovered for the Kaiser-Bessel function:
1. in Chi(k) the window starts to drop at the selected value. It reaches zero a bit lower (higher) than the value set. In k-space, it is hard to see this because of the scale but if you zoom, you can see that the drop takes about 0.05 delta k. See the "k-space.png" attachment where the window is set to 2.997.
It's probably that 0.05Ang^-1 is the spacing between points in k-space, so you're just seeing the line that join two successive points. The danger of looking too closely!
--Matt
_______________________________________________ Ifeffit mailing list Ifeffit@millenia.cars.aps.anl.gov http://millenia.cars.aps.anl.gov/mailman/listinfo/ifeffit
-- Carlo U. Segre -- Professor of Physics Associate Dean for Special Projects, Graduate College Illinois Institute of Technology Voice: 312.567.3498 Fax: 312.567.3494 Carlo.Segre@iit.edu http://www.iit.edu/~segre
On Thursday 31 March 2005 18:09, Scott Calvin wrote:
Here's a screenshot; this is the result after "Plot R" has been pressed. I'll try to whittle the project file down to the minimum necessary to generate the problem and then send it to you.
Scott, I see. Does this ever happen with a single data set? Or is it a multiple data set phenomenon? Thx, B -- Bruce Ravel ----------------------------------- bravel@anl.gov -or- ravel@phys.washington.edu Environmental Research Division, Building 203, Room E-165 Argonne National Laboratory phone and voice mail: (1) 630 252 5033 Argonne IL 60439, USA fax: (1) 630 252 9793 My homepage: http://feff.phys.washington.edu/~ravel EXAFS software: http://feff.phys.washington.edu/~ravel/software/exafs/
Hi Scott, You could try looking through the Ifeffit buffer to see how it is generating the window function. That would at least tell you what it is doing, if not necessarily why. When doing multiple data sets with different FT parameters for different data sets, it's not obvious which set is the right one to show in the plot. Bruce is forced to guess.... --Matt
Hello everybody,
Yes, and when I regenerate the plot, a window pops up to show what range I picked, right? This window does not intersect at 0 on the Xs I picked. I believe the correct x values are written.
I guess I have already seen that and I think it is related to the way the edges of the window are calculated. Basically, if you choose a Hamming window, set a k-range from, say, kmin to kmax, and a dk window smoothness dk, you would notice that the window starts at kmin -dk/2, increases up to kmin+dk/2, remains flat up to kmax-dk/2, and then cancels at kmax+dk/2. So, basically, the limits for this window are kmin-dk/2 and kmax+dk/2. NOw, it seems that Ifeffit is calculating these limits for *any* window. Incidentally, there's another bug that I observed many times with Artemis0.7.12 running on Win2000 (sorry Bruce!): when I perform a multi-spectrum fitting and when I set the width of the back-fourier transform window for the first spectrum, that window is reproduced for all subsequent FTs, whatever the actual R-range I choose for these FTs (example: R-range for EXAFS_1 is 1-3 Å (dk = 0 to avoid the problems at the limits), R-range for EXAFS_2 is 1-4 Å; the window ploted all along the FT for EXAFS_2 is 1-3 Å). Because I ususally use the same R-ranges for multispectral fitting, I didn't care much, but I guess this could be a problem in the future (i.e., what actual R-range is used for EXAFS_2?...) Best regards, Michel Schlegel -- Michel Schlegel Commissariat à l'énergie atomique CEN de Saclay, DEN/DPC/SCP/LRSI Bat 391 - Piece 205B F91 191 Gif-sur-Yvette Cedex, France Ph: +33 (0)1 69 08 93 84 Fax: +33 (0)1 69 08 54 11
Incidentally, there's another bug that I observed many times with Artemis0.7.12 running on Win2000 (sorry Bruce!): when I perform a multi-spectrum fitting and when I set the width of the back-fourier transform window for the first spectrum, that window is reproduced for all subsequent FTs, whatever the actual R-range I choose for these FTs (example: R-range for EXAFS_1 is 1-3 Å (dk = 0 to avoid the problems at the limits), R-range for EXAFS_2 is 1-4 Å; the window ploted all along the FT for EXAFS_2 is 1-3 Å). Because I ususally use the same R-ranges for multispectral fitting, I didn't care much, but I guess this could be a problem in the future (i.e., what actual R-range is used for EXAFS_2?...)
Best regards,
Michel Schlegel
This bug of Michel's sounds like the same one I sent the screenshot of (and I sent the large project file to Bruce separately). To answer Bruce's question as to whether I've ever seen it with a single dataset fit, I'm afraid I'm not sure. I'll try to keep an eye out. --Scott Calvin Sarah Lawrence College
Karla, (Scott, Bruce, Carlo), On Thu, 31 Mar 2005, Karla wrote:
Yes, and when I regenerate the plot, a window pops up to show what range I picked, right?
Sorry, but I can't tell what you're saying "yes" to here, and am resisting the tempation to guess. When you click on the plot, Does the correct value get written in the entry or not? I also can't tell what you mean by "a window pops up to show what range I picked", but I believe the answer is No: no windows pop up. Maybe I'm just not understanding. Assuming you're talking about Fourier Transform windows (that's a guess too, but what you asked about last time): The FT window with those parameters is generated, and plotted if you choose, when you hit the plot button. I can't tell whether this is obvious or not. The relationship between the FT window parameters and the shape of the window function is not always simple. It's possible that this is the confusion. Again, I'm not sure.
This window does not intersect at 0 on the Xs I picked. I believe the correct x values are written.
This would suggest that the values sent from the plot to the entry are ok.... but I'm still not sure. Perhaps you want the FT window to be 0 at some value that you choose? If so, choosing a window function type and set of parameters that does this would be necessary. This section of the Ifeffit reference manual might help: http://cars9.uchicago.edu/ifeffit/refman/node142.html If not, let us know, --Matt
participants (9)
-
Bruce Ravel
-
Bruce Ravel
-
Carlo Segre
-
Carlo U. Segre
-
Karla
-
Matt Newville
-
Michel Schlegel
-
Scott Calvin
-
Scott Calvin