Description des types structurés utilisés pour relayer les solutions entre modules QTLMap

Type structuré "Solutions de l'estimation des paramètres d'une analyse"

!!//    nqtl       : hypothesis to test
!!//    lrtmax     : maximum reached
!!//    dxmax      : position where are the maximum
!!//    nxmax      : position in the data structure where the maximum are reached
!!//    chrmax     : chromosome where the maximum are reached
!!//
!!//    lrt1       : LRT curve under Hypothesis One (Only this hypothesis case)
!!//    pater_eff  : paternal effect curve under Hypothesis One
!!//    mater_eff  : maternal effect curve under Hypothesis One
!!//    xlrp       : LRT sires surve under Hypothesis One
!!//    xlrm       : LRT dams surve under Hypothesis One
!!//
!!//    lrt0_2     : LRT curve under Hypothesis Two against Zero (Only this hypothesis case)
!!//    lrt1_2     : LRT curve under Hypothesis Two against One (Only this hypothesis case)
!!//    pater_eff2 : paternal effect curve under Hypothesis Two
!!//    mater_eff2 : maternal effect curve under Hypothesis Two
!!//    xlrp2      : LRT sires surve under Hypothesis Two against One
!!//    xlrm2      : LRT dams surve under Hypothesis Two against One
    type TYPE_LRT_SOLUTION
      !// number of Qtls => size of nxmax,chrmax
      integer                                      :: nqtl = -1
      !// The hypothesis (usually equivalent to nqtl)
      integer                                      :: hypothesis = -1
      !// LRT Maximum reached
      real (kind=dp)   ,dimension(:),pointer       :: lrtmax => NULL()
      !// Centimorgan positions of Qtls
      !// real (kind=dp)   ,dimension(:),pointer       :: dxmax => NULL()
      !// Position of Qtl in data structure
      integer          ,dimension(:),pointer       :: nxmax => NULL()
      !// Chromosome where the position is localised
      integer          ,dimension(:),pointer       :: chrmax => NULL()
      !//--------------------- QTL = 1 -----------------------------------
      !// chr,LRT curves if nqtl = 1
      real (kind=dp)   ,dimension(:,:),pointer     :: lrt1 => NULL()
      real (kind=dp)  ,dimension(:,:,:),pointer    :: pater_eff => NULL()
      real (kind=dp)   ,dimension(:,:,:),pointer   :: mater_eff => NULL()
      real (kind=dp)   ,dimension(:,:,:),pointer   :: xlrp      => NULL()
      real (kind=dp)   ,dimension(:,:,:),pointer   :: xlrm      => NULL()

      !//--------------------- QTL = 2 ---------------------------------
      !// chr,LRT curves if nqtl = 2
      real (kind=dp) ,dimension(:,:,:,:),pointer   :: lrt0_2 => NULL()
      !// chr,LRT curves if nqtl = 2
      real (kind=dp) ,dimension(:,:,:,:),pointer   :: lrt1_2 => NULL()
      !// chr1,chr2,np,npo1,npo2,2 (effet 1, effet2)
      real (kind=dp)  ,dimension(:,:,:,:,:,:),pointer    :: pater_eff2 => NULL()
      real (kind=dp)  ,dimension(:,:,:,:,:,:),pointer    :: mater_eff2 => NULL()
      !// chr1,chr2,,np,npo1,npo2
      real (kind=dp)   ,dimension(:,:,:,:,:),pointer   :: xlrp2 => NULL()
      real (kind=dp)   ,dimension(:,:,:,:,:),pointer   :: xlrm2 => NULL()
      type (CONFIDENCE_INTERVALS_SOLUTION)  , dimension(:) , pointer :: list_ci => NULL()

      contains

      procedure, public :: newOne           => new_lrt_solution
      procedure, public :: newTwo           => new_lrt_solution2
      generic  ,public  :: new              => newOne,newTwo
      procedure, public :: release          => release_lrt_solution

    end type TYPE_LRT_SOLUTION

Type structuré pour l'information de test des variables corrélées lors d'une analyse

!!//    Description of a alert of a correlation to high between classical effect and a qtl effect
!!//
!!//    attributes members :
!!//    --------------------
!!//    qtl    : number of qtl to test
!!//    ip     : sire index where the correlation are finding
!!//    jm     : dams index where the correlation are finding
!!//    corr   : value of the correlation
!!//    ntlev  : level of the qtl
!!//    name_effect  : name of the classical effect
!!//    name_level   : name of qtl level

    ! Type pour l impression des alerts de correlation trop eleve entre les effets polygenic, de nuisance et les effets qtls
    type CORR_ALERT_TYPE
         integer              :: qtl=0
         integer              :: ip = -1         ! indice du pere sinon -1
         integer              :: jm = -1         ! indice de la mere concerne sinon -1
         real(kind=dp)        :: corr            ! la correlation
         integer              :: ntlev =-1       ! le niveau du qtl concerne
         character(len=LEN_W) :: name_effect     ! le nom de l effet
         character(len=LEN_W) :: name_level      ! le nom du niveau
    end type CORR_ALERT_TYPE

Type structuré pour les tests de nuisances des effets fixés et covariables sur les effets QTL

!!//    Description of a nuisance test
!!//
!!//    attributes members :
!!//    --------------------
!!//    directeffect  : false if the qtl are in interaction with the effect
!!//    name          : name without the nuisance
!!//    df            : freedom degree
!!//    lrt           : likelihood ratio test
!!//    pvalue        :

    !type pour l impression de test lin
    type TEST_NUISANCES_TYPE
         logical              :: directeffect    ! intra qtl (fixed effect) or direct effect
         character(len=LEN_W) :: name            ! name without the nuisances
         integer              :: df
         real(kind=dp)        :: lrt
         real(kind=dp)        :: pvalue
    end type TEST_NUISANCES_TYPE

Type structuré "Valeur des LRTs et Positions du maximum de vraissemblance"

Type structuré pour "transporter" l'information sur le calcul des intervalles de confiance

type CONFIDENCE_INTERVALS_SOLUTION
      !// Name method
      character(len=LEN_DEF)                   ,public :: method = "" 
      !// number of average
      integer                                  ,public :: nci      = 0
      !// average 95%,90%,...
      real (kind=dp)   ,dimension(:),pointer           :: ci_seuil => NULL()
      !// lower and upper
      real (kind=dp)   ,dimension(:,:),pointer         :: ci_intervals => NULL()

      contains
       procedure, public ::  release => release_confidence_intervals_solution

end type CONFIDENCE_INTERVALS_SOLUTION