View Single Post
  #4 (permalink)  
Old 07-10-2012, 02:55 PM
saman
Guest
 
Posts: n/a
Default Re: Multiple matrix output

On Tuesday, July 10, 2012 12:54:54 PM UTC+2, saman wrote:
> hi ,
> I have three matrix called
> Real, Dimension(::A,B,C
> A=5,B=5,C=5
> I want to print them to an external file where first column is A, 2nd column is B and the last is C. For example I want to have the following format in output:
>
> 15 20 1
> 12 21 4
> 18 12 2
> 15 12 3
> 60 78 4
>
> I write this code but it is not what I want:
>
> OPEN(35, file = 'phenotype',status="REPLACE&quot
> DO cc=1,n
> DO bb=1,n
> DO aa=1,n
> WRITE(35, '(F10.3,2x,F10.3,2x,F10.3)') phenotype(aa),genvalue(bb),E(cc)
> END DO
> END DO
> END DO
> CLOSE(35)
>
> Can anybody help me?
> best,
> Sami



Dear Les
Thank you very much.
Reply With Quote