https://github.com/cran/bild
Raw File
Tip revision: 6661b7703cf2271cb13756a6ff2969ef8e1d88f3 authored by M. Helena Goncalves on 03 November 2023, 14:40:02 UTC
version 1.2-1
Tip revision: 6661b77
mat4.f
      subroutine mat4(p1,p2,p3,p4,P)
C   creates 4x4 MC transition matrix, given probs of 1's
      implicit double precision (a-h,o-z)
      dimension P(4,4)
      P(1,1)=1-p1
      P(1,2)=p1
      P(1,3)=0
      P(1,4)=0
      P(2,1)=0
      P(2,2)=0
      P(2,3)=1-p2
      P(2,4)=p2
      P(3,1)=1-p3
      P(3,2)=p3
      P(3,3)=0
      P(3,4)=0
      P(4,1)=0
      P(4,2)=0
      P(4,3)=1-p4
      P(4,4)=p4
      return
      end
back to top