XMM-Newton SAS Home Page
XMM-Newton Science Analysis System


ssclib (ssclib-4.30) [xmmsas_20160201_1833-15.0.0]

getAryStatInfo Array or vector other printAryStatInfo Home Index

Meta Index / Home Page / General-purpose array-processing utilities / Array or vector other


calcAryStatInfoMask

This subroutine is the core routine for the function getAryStatInfo (Section 2.8.3). The difference is that this function returns, as well as (aryStatInfo???T), the final mask file, which is used to determine the valid entry to calculate the statistical information of the array. If that is what you want, you can call this subroutine directly.

The following is an example interface for the Double-type one. Again, in other types, only the difference is the type of the input Array, arin (and the returned type, accordingly - see Section 2.2 for detail).

  interface calcAryStatInfoMask
    subroutine calcAryStatInfoMaskDouble1d(arin, retInfo, arMaskOut, arMaskIn &
       , minAreaIndices, maxAreaIndices, valLower, valUpper, flagInfo)

      integer, parameter :: rankArin = 1
      real(double), intent(in)  :: arin(:)      ! Input data Array
      type(aryStatInfoDoubleT), intent(out) :: retInfo
      logical, intent(out) :: arMaskOut(:)	! Must be predefined.
      logical, intent(in), optional :: arMaskIn(:)
      integer(int32), intent(in), optional :: minAreaIndices(rankArin), maxAreaIndices(rankArin)
      real(double), intent(in), optional :: valLower, valUpper
      type(aryStatInfoFlagT), intent(in), optional :: flagInfo
    end subroutine calcAryStatInfoMaskDouble1d

    subroutine calcAryStatInfoMaskDouble2d(arin, retInfo, arMaskOut, arMaskIn &
       , minAreaIndices, maxAreaIndices, valLower, valUpper, flagInfo)

      integer, parameter :: rankArin = 2
      real(double), intent(in)  :: arin(:,:)    ! Input data Array
      type(aryStatInfoDoubleT), intent(out) :: retInfo
      logical, intent(out) :: arMaskOut(:,:)	! Must be predefined.
      logical, intent(in), optional :: arMaskIn(:,:)
      integer(int32), intent(in), optional :: minAreaIndices(rankArin), maxAreaIndices(rankArin)
      real(double), intent(in), optional :: valLower, valUpper
      type(aryStatInfoFlagT), intent(in), optional :: flagInfo
    end subroutine calcAryStatInfoMaskDouble2d
  end interface

Note that the ranks of arin and arMaskIn (if specified) and arMaskOut have to be identical. And (the rank of) arMaskOut has to be defined in the caller side before the call.



XMM-Newton SOC/SSC -- 2016-02-01