1
C===========================================================================
2
C Copyright (C) 1995-2006 European Southern Observatory (ESO)
4
C This program is free software; you can redistribute it and/or
5
C modify it under the terms of the GNU General Public License as
6
C published by the Free Software Foundation; either version 2 of
7
C the License, or (at your option) any later version.
9
C This program is distributed in the hope that it will be useful,
10
C but WITHOUT ANY WARRANTY; without even the implied warranty of
11
C MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12
C GNU General Public License for more details.
14
C You should have received a copy of the GNU General Public
15
C License along with this program; if not, write to the Free
16
C Software Foundation, Inc., 675 Massachusetts Ave, Cambridge,
19
C Correspondence concerning ESO-MIDAS should be addressed as follows:
20
C Internet e-mail: midas@eso.org
21
C Postal address: European Southern Observatory
22
C Data Management Division
23
C Karl-Schwarzschild-Strasse 2
24
C D 85748 Garching bei Muenchen
26
C===========================================================================
28
C ++++++++++++++++++++++++ YSTVALS.FOR +++++++++++++++++++++++++++++++++++++++
29
C .LANGUAGE Fortran 77
30
C .IDENTIFICATION Module YSTVALS.FOR
32
C Module contains layer between the keyword related FORTRAN STxxxx interfaces
33
C and the SC_interfaces written in (hopefully independent) C
34
C .AUTHOR K. Banse ESO - Garching
35
C .KEYWORDS standard interfaces.
36
C .ENVIRONMENT FORTRAN and C standards
37
C .VERSION [1.00] 871207: created from SXFTOC.C
40
C ......................................................
44
C STVALS(ACTION,A,NAXIS,NPIX,SUBLO,SUBHI,CUTVLS,RSULTS,RESPIX,NOPIX,STAT)
47
C ACTION: char. exp. = MIN for min, max calculation
48
C = MEAN for above + mean values, std deviation
49
C = ALL for above + moments of 2. + 3. order
50
C A: R*4 array array to work on
51
C NAXIS: I*4 no. of axis of A (maxium of 3, currently)
52
C NPIX: I*4 array no. of pixels per axis in A
53
C SUBLO: I*4 array start pixels of subframe
54
C SUBHI: I*4 array end pixels of subframe
55
C CUTVLS: R*4 array user supplied cutvalues for subframe
58
C RSULTS: R*4 array depending on ACTION, this array contains
59
C min, max, mean, sigma, 2-moment, 3-moment,
61
C RESPIX: I*4 array holds pixel no. of min + max of array
62
C NOPIX: I*4 total no. of pixels inside subframe
63
C with value in [CUTVLS(1),CUTVLS(2)]
64
C STAT: I*4 return status
65
C = 0 o.k., otherwise error
67
C --------------------------------------------------
70
SUBROUTINE STVALS(ACTION,A,NAXIS,NPIX,SUBLO,SUBHI,CUTVLS,
71
+ RSULTS,RESPIX,NOPIX,STAT)
76
REAL A(*), CUTVLS(*), RSULTS(*)
77
INTEGER NAXIS, NPIX(*), SUBLO(*), SUBHI(*)
78
INTEGER RESPIX(*), NOPIX, STAT
81
CALL YST1(A,NAXIS,NPIX,SUBLO,SUBHI,CUTVLS,
82
+ RSULTS,RESPIX,NOPIX,STAT)
87
SUBROUTINE ZMSTAT(IMNO,AREA,NAXPIX,START,STEP,RBINS,
92
CHARACTER*(*) AREA, FORMSTR, DEFAUL
94
DOUBLE PRECISION START(*), STEP(*)
95
INTEGER IMNO, NAXPIX(*)
100
CALL ZST1(IMNO,NAXPIX,START,STEP,RBINS)