Fitting EXAFS in Artemis: paths, coordination numbers, and what counts as a result
Shell fitting of extended X-ray absorption fine structure (EXAFS) is commonly done in Artemis, part of the Demeter package. Athena turns an experimental spectrum into a file Artemis can import. Artemis then lines the measured oscillation up with scattering paths from FEFF, and from that estimates the coordination number $N$, a distance correction, the disorder $\sigma^2$, and the energy-origin shift $\Delta E_0$.
The interface, the order of operations, and three examples are kept apart below. The $\mathrm{Pt\text{-}O\text{-}Cu}$, $\mathrm{PtO_2}$, and iron data come from different tutorials. Their parameters and logs stay with the tutorial they came from. They are not merged into one fit. None of these sources gives a paper DOI.
Three parts of Demeter
The notes split Demeter into three pieces:
- Athena processes the experimental data and produces the X-ray absorption near-edge structure (XANES) and the EXAFS.
- Artemis fits the EXAFS and extracts structural parameters such as the coordination number.
- Hephaestus is described there as a database related to synchrotron experiments.

The input to an Artemis fit is the unweighted EXAFS oscillation $\chi(k)$. Background subtraction is finished in Athena. Artemis does not do that step. The fit uses scattering amplitudes and phase shifts from FEFF and minimises a least-squares target. That target falls into local minima easily, so the window, the paths, and the starting values have to be checked by hand.
The program embeds Atoms and FEFF6. It does not include FEFF8 or later. Its fitting core corresponds to FEFFIT from the old UWXAFS package. The graphical interface was added later.
Each part of the main window does one job
Athena keeps its tools in one window. Artemis splits data, theoretical paths, parameters, and the fit, so the work moves between them. From left to right the main window is roughly:
| Region | Role |
|---|---|
| GDS, Plot, History, Journal | define parameters, plot, revisit earlier fits, write notes |
| Data | only files that Athena has saved can be imported |
| Model and paths | a CIF is turned into paths by Atoms and FEFF |
| Fit result | reports $N$, quantities related to bond length, and $\sigma^2$ |
In GDS, guess means a parameter to be fitted, set means a parameter held fixed, and a quantity can also be computed from other parameters. The Sample window chooses the $R$-space range on the left and lists paths, with the parameter names used by each path, on the right. History keeps every fit, because a usable result is usually reached by changing the model repeatedly.


A repeatable order is:
- Process the spectrum in Athena and save a
.prj. - In Artemis, use File → Open project or data, or Add inside the data set, and import that file.
- Add the CIF in the Feff calculation, name the absorbing atom, then Run Atoms and Run FEFF.
- Plot $\lvert\chi(R)\rvert$ for each path, and drag into the data window only the paths that line up with the sample peaks.
- Set the $k$ and $R$ windows and, for each path, $N$, $\Delta E_0$, $\Delta R$, and $\sigma^2$.
- Run Fit, read the log, then change the window or the paths. Parameter names that appear in GDS have to match the names in the path formulae.
Example 1: oxygen and copper paths in $\mathrm{Pt\text{-}O\text{-}Cu}$
One second-shell exercise uses a FEFF calculation named Pt-O-Cu. The cluster radius in the figure is $5.00\ \mathrm{\AA}$ and the cluster contains 16 atoms. The two single-scattering paths that are selected are:
| Path | $R_{\mathrm{eff}}$ | Note |
|---|---|---|
| O1.1 | $1.929\ \mathrm{\AA}$ | $\mathrm{Pt\text{-}O}$ single scattering |
| Cu2.1 | $2.545\ \mathrm{\AA}$ | $\mathrm{Pt\text{-}Cu}$ single scattering |
On the same screen the Fourier-transform window is $k_{\min} = 3\ \mathrm{\AA}^{-1}$, $k_{\max} = 11\ \mathrm{\AA}^{-1}$, $R_{\min} = 1\ \mathrm{\AA}$, $R_{\max} = 3\ \mathrm{\AA}$. The tutorial text then changes $R_{\max}$ from 3 to 3.3 and fits again. The screenshot still says rmax = 3, so that figure is the window before the change.

That tutorial recommends fixing the amplitude reduction factor $S_0^2$ at 0.87 from a metal foil. It also describes a workaround: if the software will not give $N$ its own name, multiply the guess for $N$ into the cell that holds $S_0^2$, so that the result displays a coordination number. The Fit 1 log in the same piece, however, already contains fitted variables named N1 and N2. The advice to fix $S_0^2$, and the parameter table in that log, are two procedures and should be read separately.
The Fit 1 log matches the Happiness quoted in the text, so it can be paired with the fit from before rmax was changed:
- 9.9375 independent points, 7 variables.
- Reduced $\chi^2$ is 33.116. The R-factor is 0.0086.
- Happiness = 95.47/100.
- The log says 7 of 9.938 independent points were used, with a penalty of 4.528.
- The software notes that Happiness is a semantic score and should not be reported in a paper.
The distance terms in the log are corrections relative to the FEFF reference distance. $R_{\mathrm{eff}}$ is $1.929\ \mathrm{\AA}$ for the $\mathrm{O}$ path and $2.545\ \mathrm{\AA}$ for the $\mathrm{Cu}$ path. $R_1 = -0.058\ \mathrm{\AA}$ is the correction. Writing it down as the $\mathrm{Pt\text{-}O}$ bond length makes the bond too short.
| Parameter | Fitted value | Uncertainty |
|---|---|---|
| $N_1$ | 1.466 | 0.213 |
| $E_1$ | 4.705 eV | 1.371 eV |
| $R_1$ | $-0.0582\ \mathrm{\AA}$ | $0.0087\ \mathrm{\AA}$ |
| $\sigma^2_1$ (SIG1) | $0.00402\ \mathrm{\AA}^2$ | $0.00153\ \mathrm{\AA}^2$ |
| $N_2$ | 2.567 | 0.510 |
| $R_2$ | $0.00549\ \mathrm{\AA}$ | $0.0084\ \mathrm{\AA}$ |
| $\sigma^2_2$ (SIG2) | $0.01087\ \mathrm{\AA}^2$ | $0.00165\ \mathrm{\AA}^2$ |
The trailing digits follow the screenshot. The uncertainties on $N_1$ and $N_2$ are already large compared with the values. $E_1$ is about 4.7 eV, inside the $\pm 10\ \mathrm{eV}$ range quoted later. $\sigma^2_1$ is above that tutorial’s room-temperature lower bound of $0.0025\ \mathrm{\AA}^2$ for a metal–oxygen pair, and $\sigma^2_2$ is larger than $\sigma^2_1$, which goes the same way as “a more distant shell has a larger $\sigma^2$”. All of that only says that this log meets a few of the tutorial’s own rules of thumb. It does not mean the fit is ready to be copied into a paper.

The text also notes that if a single $\Delta E_0$ fits poorly, it can be split into two variables. A reduced $\chi^2$ cannot be judged from one number alone. It is useful when it gets smaller during the same round of changes, which means that step is better than the previous one.
Example 2: the first shell of $\mathrm{PtO_2}$, and $S_0^2$
Another tutorial fits only the first shell of $\mathrm{PtO_2}$, in order to show where the coordination number comes from. The sample still has to be saved as a .prj in Athena first.
In that example the $R$ window is changed to $1\text{–}2\ \mathrm{\AA}$. The path that is kept is a FEFF path whose $R_{\mathrm{eff}}$ is about $0.3\text{–}0.5\ \mathrm{\AA}$ longer than the peak being fitted, and that path is dragged into the path list. The same length difference appears later as “a Fourier-transform peak is usually $0.3\text{–}0.5\ \mathrm{\AA}$ shorter than the true bond length”. The peak position itself is not yet the bond length.


Parameters are split by shell. Every shell uses the same $S_0^2$. $\Delta E_0$ may be shared. $\Delta R$ and $\sigma^2$ are separate for each shell. In the demonstration, $S_0$ is first set to 1 and $n_1$ is floated. After the fit, that tutorial reads $n_1$ in the log as the first-shell $\mathrm{Pt\text{-}O}$ coordination number.
The Fit 1 screenshot also prints the software’s own warnings, which have to be read against the tutorial text:
- Happiness = 92.19/100.
- There is a penalty for an “absolute value greater than 10”, and an independent-point penalty of 5.810. The symbol that is named is the English label in the figure.
- $E_0$ is about 12.6 eV, $r_1$ about $-0.034\ \mathrm{\AA}$, $s_1$ about $0.0038\ \mathrm{\AA}^2$, $n_1$ about 4.74, and $s_0$ is set to 1. The variable names in the log are enot, r1, s1, n1, and s0.
- The correlation of $r_1$ with $E_0$ is about 0.86, and the correlation of $\sigma^2$ with the coordination-number term is also about 0.85.

The same text then sets a stricter rule: the window has to turn pale green before a result can be considered, and red, red-yellow, yellow, and yellow-green are all rejected. Even with a green window it still requires an R-factor below 0.02, a positive $S_0^2$, a positive $\sigma^2$, and Happiness exactly equal to 100.00/100. The log above is 92.19/100, and $E_0$ is already outside the $\pm 10\ \mathrm{eV}$ range used in the other material. So $n_1 \approx 4.74$ is the fitted value on that demonstration screen. It is not a $\mathrm{Pt\text{-}O}$ coordination number that has passed the tutorial’s own acceptance rule.
When $S_0^2$ is unknown, the tutorial switches to a standard: the first-shell coordination number of $\mathrm{PtO_2}$ is fixed at 6, only the parameter table is changed, and $S_0$ is backed out. In the corresponding log, $S_0$ is about 0.79 with an uncertainty of about 0.086. $E_0$, $r_1$, and $s_1$ stay on the same scale as above. The exact trailing digits follow the screenshot.

Example 3: iron in $R$-space
The third tutorial starts from $\mathrm{Fe}$ data exported by Athena. It says to import a CIF of $\mathrm{Fe_3O_4}$, then Run Atoms, Run FEFF, and Plot path, and to pick paths against the sample spectrum. Path parameters are set to guess in one right-click: N1, E1, R1, SIG1, N2, E2, R2, SIG2. This tutorial explicitly floats every parameter. That is not the same as Example 1, which fixes $S_0^2$ at 0.87.
The experimental file in the screenshot is named Fe_lepidocrocite.000, and $R$-space shows two main peaks between about $1$ and $3\ \mathrm{\AA}$. The FEFF path legend lists O10.1, O7.1, O6.1, Fe1.1, Fe3.1, Fe1.2, and others. It does not label the figure as $\mathrm{Fe_3O_4}$. The source never says whether the $\mathrm{Fe_3O_4}$ in the text and the lepidocrocite filename in the figure are the same sample. That point is left unchecked.


The tutorial says the result took 19 adjustments. It does not give final values of $N$, $R$, and $\sigma^2$ in the text. It only keeps the order of operations: import the Athena data, import the CIF, calculate and select paths, set parameters and the fit range, and repeat until it is reasonable to stop.
Three criteria, not one
A curve that lies on the data is necessary. It is not a shared definition of “usable”. The three sources do not say the same thing.
| Source | R-factor | $S_0^2$ | $\sigma^2$ | $\Delta E_0$ | Happiness |
|---|---|---|---|---|---|
| $\mathrm{Pt\text{-}O\text{-}Cu}$ procedure | below 0.02 is fairly good; 0.02–0.05 means the model is slightly off or the data are ordinary; 0.05–0.1 means a large deviation or very poor data; above 0.1, change the model | fix at 0.87 from a foil | at room temperature, $\mathrm{M\text{-}O} \ge 0.0025\ \mathrm{\AA}^2$; $\mathrm{M\text{-}S} \ge 0.003\ \mathrm{\AA}^2$; $\mathrm{M\text{-}M}$ not below the matching foil; a more distant shell of the same coordination should be larger | preferably between $-10$ eV and $+10$ eV; the uncertainty is often large, so the error bar itself is not the test. $\Delta E_0$ values for paths in the same sample should lie close together | the text shows 95.47/100 and continues by changing the $R$ window |
| $\mathrm{PtO_2}$ coordination-number note | must be below 0.02 | must be positive; the standard step fixes the first-shell coordination number at 6 and backs $S_0^2$ out | must be positive | no separate numerical window | must equal 100, and the result window must be pale green |
| Parameter-plausibility figure | do not call a fit successful only because the R-factor is below 0.02 | $0.7 < S_0^2 < 1.0$ | $\sigma^2 > 0.003\ \mathrm{\AA}^2$ | absolute value below 10 eV | look first at whether the curve matches and whether Happiness is high, then at the other parameters |
The same parameter figure uses the $R$-space of a $\mathrm{Cu}$ foil to show the window. If the range is too wide, oscillations outside the main peak are pulled into the fit. Once the window is drawn in around the main peak, the fit and the data coincide better at the peak. The red crosses in the figure mark the fit with the window left too wide.

Two further points about coordination number are easy to skip:
- In a phase mixture, the fitted coordination number is a weighted average of the phases. It is not the number of atoms around one lattice site.
- $\Delta E_0$ should be similar for different paths in the same sample, and similar for the same coordination across a series of samples.
The $\mathrm{PtO_2}$ note makes Happiness = 100 a hard condition. The software log says not to report Happiness in a paper. The $\mathrm{Pt\text{-}O\text{-}Cu}$ log is still discussing the R-factor at 95.47/100. The parameter figure only asks for a “high” Happiness. A citation has to say which standard is being used.
An $R$-space peak is not the structure
Shell fitting depends on a rough idea of the sample structure, and that judgement is large. A few limits on reading the spectrum can be set next to the fit parameters above.
Fourier-transform peaks move toward low $R$. When the disorder is large, the shift is a few tenths of an ångström. It is not a shortening of the interatomic distance. Most peaks sit $0.3\text{–}0.5\ \mathrm{\AA}$ short of the true bond length. The distance to report is the one from the shell fit. That matches the $\mathrm{PtO_2}$ example, where $R_{\mathrm{eff}}$ is $0.3\text{–}0.5\ \mathrm{\AA}$ longer than the peak.
A weak shoulder beside a strong peak, and any peak with $R$ below $1\ \mathrm{\AA}$, may be noise. Peak area correlates with coordination number. It can be used to compare coordination qualitatively. It does not replace the fitted $N$.

An EXAFS fit returns the average local structure of the sample, not one definite geometry. The figure’s example is a $\mathrm{Co\text{-}N}$ coordination number of 4, which still cannot be called tetrahedral without another method. The figure uses a first-principles XANES calculation to constrain the local model. The program name on the slide is written FDNMNES. The ordinary name is FDMNES (finite difference method for near-edge structure). The curve in the figure is labelled $\mathrm{O_2\text{-}CoN_4C_{12}}$.

A comparison at the $\mathrm{Fe}$ K-edge labels peaks as $\mathrm{Fe\text{-}C}$, $\mathrm{Fe\text{-}P}$, and $\mathrm{Fe\text{-}Fe}$. In the legend, orange is $\mathrm{Pd_1Fe}$ SAA@PC, green is $\mathrm{Fe_2O_3}$, and black is $\mathrm{Fe}$ foil. Those labels say that different neighbours fall at different $R$. The assignment still follows the original figure.

The source sentence for the number of independent points
The number of fitted parameters should be smaller than the number of independent points. The form used in EXAFS is
$$N_{\mathrm{idp}} = \frac{2\Delta k,\Delta R}{\pi}.$$
The source prints the sentence as “the number of parameters to be fitted is greater than the number of independent points”, and it also places an extra $R$ in front of the formula. That sentence is not used. The Fit 1 log gives 9.9375 independent points and 7 variables.
What to check after a fit
- Whether the data and the CIF are the same sample. In the iron example the text says $\mathrm{Fe_3O_4}$ and the data file in the figure is
Fe_lepidocrocite.000. - Whether $R_{\mathrm{eff}}$ of a path is only about $0.3\text{–}0.5\ \mathrm{\AA}$ longer than the target peak, and whether the $R$ window has taken in a noise peak.
- Whether $S_0^2$ is fixed, set to 1, or backed out from a standard with a known coordination number. The three tutorials do not do the same thing.
- When $R$ in the log is a $\Delta R$, add back that path’s $R_{\mathrm{eff}}$ before comparing it with a bond length.
- Which standard is being used for the R-factor, $\sigma^2$, $\Delta E_0$, and Happiness. The $\mathrm{PtO_2}$ text requires Happiness of 100. The log in its figure is 92.19.
- A coordination number is an average. Inferring a geometry from $N$ needs additional XANES or structural information.