[AIT logo]

Institut für Astronomie und Astrophysik

Abteilung Astronomie

Sand 1, D-72076 Tübingen, Germany
[Uni logo]

pfold Source code in cafe_pfold.pro


           folds data set(s) with certain period.
         pfold[,range] [,subgroup][,group][,/stderror][,/add]
Input Parameters
           range    - (optional) Defines range of data points to fold. This can
                      be either:
                       - Data point range, denoted by the data
                         point number:
                         <n1>[-], while ,  are positive
                         numbers. Data point numbers start from zero.
                         Open intervals can be represented with a
                         "*" instead of the number.
                         If only one number is given, a single
                         data point will be referenced.
                         If <val2> is less than  all but the
                         interval <val2>.. are referenced.
                       - X value range, denoted by float point numbers:
                         <val1>-, while , 
                         represents X values defining the interval to
                         reference. Open intervals can be represented
                         with a *  instead of the value. If <val2> is
                         less than <val1> all but the interval
                         <val2>.. is referenced.
                       - Vector of data point indices. The vector is
                         denoted with [val,val,...,val] (indgen may
                         be used also).
                       - Boolean expressions with X/Y values. All
                         values for which this expression is true are
                         referenced. The expression may contain
                         algebraic formulas combined with comparison
                         operators "lt", "le", "eq", "gt", "ge" as used in IDL
                         comparisons. For each data point a keyword
                         is defined which has meaning and can be used
                         for the boolean expression:
                                 x - The x-column value.
                                 y - The y-column value.
                             error - The error column value.
                          selected - True when the data point is selected.
                               def - True when the data point is defined.
                               x1  - Multi column first column value.
                               x2  - Multi column second column
                               x3  - Multi column third column value.
                         To avoid interference with functions which
                         also can be used a lower/upper case
                         distinction  is made. IDL funktions should
                         be upper case.
                      Default is to fold the entire data set.
           subgroup - (optional) The data set (subgroup) for which the model
                      should be applied. This can be either the
                      subgroup number or the file name representing
                      the data set. It is possible to set more than
                      one subgroup, either with numbers in brackets
                      ([]) separated with ","; or denoting filenames
                      with wildcards ("*").
                      Default are all subgroups in currently used
           group    - (optional) The data group for which folding
                      should applied.
                      Default is the current group. Must be in
                      range [0..29].
Keyword Parameters
           add      - Do not overwrite existing subgroups (0) but use
                      the next free one in current result group.
          period    - The period to fold the data with. Should be
                      initialized with the set command.  If not
                      defined the user will be prompted for.
          nbins     - Number of bins to use for folding. Default: 20.
          time0     - Use this instead of first x value as start time.
          dt        - Width of each time bin. Default is difference
                      between first two x values.
          tolerance - parameter defining the lower limit for the gap
                      length; the reference is the time difference
                      between the first and second entry in the time
                      array; tolerance defines the maximum allowed relative
                      deviation from this reference bin length;
                      default: 1e-8; this parameter is passed to timegap
                      (see timgap.pro for further explanation).
          stderror  - Compute profile error by checking the standard
                      deviation for each bin instead using error
                      propagation of data errors. May be used to get
                      information about intrinsic profile
          events    - Consider input to contain events only. In this
                      case only the time (x) axis is used and folded
                      as single events.
                      To work properly the data sets must not contain
                      any gaps which are not acknowledged by to be
                      outside of the good time interval (s.b.).
          gti       - Good time interval (for events only). Must be
                      2-D array with of the form: gti[2,*]. It
                      defines the start (gti[0,*]) and stop
                      (gti[1,*]) time of event times (x) to be used
                      for the pfold process.
                      If not given it will be computed under
                      following assumptions:
                      1.) start and stop of each data set define the
                          outer gti boundary.
                      2.) ignored data points define inner gti
          pdot      - Take period derivative into account. If a
                      single value is given this one will be
                      computed. If pdot is of the form pdot = [a,b]
                      then the period derivative will be scanned from
                      in the range a..b. The number of steps are
                      defined with pdotnum (s.b.).
          pddot     - Second derivative of period to be taken into
          time0     - Epoch for folding, needed when usind
Output Parameters
           All data points given as input are summed up within a
           histogram according their x value modulo a period. The
           period must be set before.
Side Effects
           Creates/Overrides first subgroup in the result group. If
           /add is used a new subgroup will be created.
           > set, period=2000.
           > pfold
           -> fold all data in current group with a period of 2000.
Revision History
           $Id: cafe_pfold.pro,v 1.19 2005/02/15 10:40:40 goehler Exp $

Last modified by pro2html on 2005 February 16 at 04:17 UTC

[Home Page] [Software, Documentation] [IDL Documentation] [Quick Reference] [Feedback]

Jörn Wilms (wilms@astro.uni-tuebingen.de)
Updated automatically