Home

Awesome

NAME

Demeter - A comprehensive XAS data analysis system using Feff and Ifeffit or Larch

VERSION

This documentation refers to Demeter version 0.9.26

SYNOPSIS

Import Demeter components into your program:

use Demeter;

This will import all Demeter components into your program. Using Demeter automatically turns on strict and warnings.

DESCRIPTION

This module provides an object oriented interface to the EXAFS data analysis capabilities of the popular and powerful Ifeffit package and its successor Larch. Given that the Ifeffit and Larch APIs involve streams of text commands, this package is, at heart, a code generator. Many methods of this package return text. All actual interaction with Ifeffit or Larch is handled through a single method, dispose, which is described below. The internal structure of this package involves accumulating text in a scalar variable through successive calls to the various code generating methods. This text is then disposed to Ifeffit, to Larch, to a file, or elsewhere. The outward looking methods organize all of the complicated interactions of your data with Ifeffit or Larch.

This package is aimed at many targets. It can be the back-end of a graphical data analysis program, providing the glue between the on-screen representation of the fit and the actual command executed by Ifeffit or Larch. It can be used for one-off data analysis chores -- indeed most of the examples that come with the package can be reworked into useful one-off scripts. It can also be the back-end to sophisticated data analysis chores such as high-throughout data processing and analysis or complex physical modeling.

Demeter is a parent class for the objects that are directly manipulated in any real program using Demeter. Each of these objects is implemented using Moose, the amazing meta-object system for Perl. Although Moose adds some overhead at start-up for any application using Demeter, its benefits are legion. See Moose and http://moose.iinteractive.com for more information.

IMPORT

Subsets of Demeter can be imported to shorten loading time.

PRAGMATA

Demeter "pragmata" are ways of affecting the run-time behavior of a Demeter program by specfying that behavior at compile-time.

  use Demeter qw(:plotwith=gnuplot)
or
  use Demeter qw(:ui=screen)
or
  use Demeter qw(:plotwith=gnuplot :ui=screen)

METHODS

An object of this class represents a part of the problem of EXAFS data processing and analysis. That component might be data, a path from Feff, a parameter, a fit, or a plot. Moose provides a sane, solid, and consistent way of interacting with these objects.

Not every method shown in the example above is described here. You need to see the subclass documentation for methods specific to those subclasses.

Main methods

These are the basic methods for constructing objects and accessing their attributes.

Convenience methods

Utility methods and common attribute accessors

Here are a number of methods used internally, but which are available for your use.

Demeter provides a generic mechanism for reporting on errors in a fitting model. When using Demeter non-interactively, useful messages about problems in the fitting model will be written to standard output. Critical problems in a non-interactive mode will be cause the script to croak (see Carp).

In an interactive mode (such as with the Wx interface), the add_trouble method is used to fill the trouble attribute, which is inherited by all Demeter objects. In the default, untroubled state, an object will have the trouble attribute set to an empty string (i.e. something logically false). As problems are found in the fitting model (see Demeter::Fit::Sanity), the trouble attribute gets short text strings appended to it. The list of problems an object has are separated by pipe characters (|).

See Demeter::Fit::Sanity for a complete description of these problem codes. The Fit, Data, Path, and GDS objects each have their own set of problem codes.

CONFIGURATION AND ENVIRONMENT

See Demeter::Config for details about the configuration system.

DEPENDENCIES

The dependencies of the Demeter system are in the Build.PL file.

BUGS AND LIMITATIONS

Please report problems to the Ifeffit Mailing List (http://cars9.uchicago.edu/mailman/listinfo/ifeffit/)

Patches are welcome.

AUTHOR

Bruce Ravel (http://bruceravel.github.io/home)

http://bruceravel.github.io/demeter/

LICENCE AND COPYRIGHT

Copyright (c) 2006-2016 Bruce Ravel (http://bruceravel.github.io/home). All rights reserved.

This module is free software; you can redistribute it and/or modify it under the same terms as Perl itself. See perlgpl.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.