view test-data/rnaplfold_result1.ps @ 0:d14bc79748a3 draft

planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/rna_tools/vienna_rna commit 0065dafe7bbd382bb995b28cc4089c9e4f4eeeb9
author rnateam
date Tue, 06 Dec 2016 12:34:24 -0500
parents
children
line wrap: on
line source

%!PS-Adobe-3.0 EPSF-3.0
%%Title: RNA Dot Plot
%%Creator: ViennaRNA-2.2.10
%%CreationDate: Tue Oct  4 14:45:55 2016
%%BoundingBox: 66 530 520 650
%%DocumentFonts: Helvetica
%%Pages: 1
%%EndComments

%Options: 
%This file contains the square roots of the base pair probabilities in the form
% i  j  sqrt(p(i,j)) ubox

%%BeginProlog
/DPdict 100 dict def
DPdict begin
/logscale false def
/lpmin 1e-05 log def

/box { %size x y box - draws box centered on x,y
   2 index 0.5 mul sub            % x -= 0.5
   exch 2 index 0.5 mul sub exch  % y -= 0.5
   3 -1 roll dup rectfill
} bind def

/ubox {
   logscale {
      log dup add lpmin div 1 exch sub dup 0 lt { pop 0 } if
   } if
   3 1 roll
   exch len exch sub 1 add box
} bind def

/lbox {
   3 1 roll
   len exch sub 1 add box
} bind def

/drawseq {
% print sequence along all 4 sides
[ [0.7 -0.3 0 ]
  [0.7 0.7 len add 0]
  [-0.3 len sub -0.4 -90]
  [-0.3 len sub 0.7 len add -90]
] {
   gsave
    aload pop rotate translate
    0 1 len 1 sub {
     dup 0 moveto
     sequence exch 1 getinterval
     show
    } for
   grestore
  } forall
} bind def

/drawgrid{
  0.01 setlinewidth
  len log 0.9 sub cvi 10 exch exp  % grid spacing
  dup 1 gt {
     dup dup 20 div dup 2 array astore exch 40 div setdash
  } { [0.3 0.7] 0.1 setdash } ifelse
  0 exch len {
     dup dup
     0 moveto
     len lineto
     dup
     len exch sub 0 exch moveto
     len exch len exch sub lineto
     stroke
  } for
  [] 0 setdash
  0.04 setlinewidth
  currentdict /cutpoint known {
    cutpoint 1 sub
    dup dup -1 moveto len 1 add lineto
    len exch sub dup
    -1 exch moveto len 1 add exch lineto
    stroke
  } if
  0.5 neg dup translate
} bind def

end
%%EndProlog
DPdict begin
%delete next line to get rid of title
270 665 moveto /Helvetica findfont 14 scalefont setfont (Anolis_carolinensis_chrUn_GL343590.trna2-A) show

/sequence { (\
UGGGAAUUAGCUCAAAUGGUAGAGCGCUCGCUUAGCAUGUGAGAGGUAGUGGGAUCGAUGCCCACAUUCUCCA\
) } def
/winSize 70 def
/len { sequence length } bind def

292 416 translate
72 6 mul len 1 add winSize add 2 sqrt mul div dup scale
/Helvetica findfont 0.95 scalefont setfont

/drawseq_turn {% print sequence at bottom
   gsave
   len 2 sqrt div dup neg 0.28 add exch 0.78 sub translate
    0 1 len 1 sub {
     dup dup 2 sqrt mul 0 moveto
     sequence exch 1 getinterval
     show
    } for
   grestore
} bind def
/drawgrid_turn{
  0.01 setlinewidth
  len log 0.9 sub cvi 10 exch exp  % grid spacing
  dup 1 gt {
     dup dup 20 div dup 2 array astore exch 40 div setdash
  } { [0.3 0.7] 0.1 setdash } ifelse
  0 exch len {    %for (0, gridspacing, len) 
     dup dup      %duplicate what - gridspacing??
     dup len exch sub moveto     %moveto diagonal?
     dup winSize gt
     {dup dup len exch sub winSize add lineto}
     {dup len lineto}ifelse
     dup len exch sub moveto  %moveto diagonal?
     dup len winSize sub le
     {dup dup len exch sub dup winSize exch sub len add exch lineto}
     {dup dup len exch sub len exch lineto}ifelse     stroke pop pop
  } for
  len log 0.9 sub cvi 10 exch exp  % grid spacing
      dup 1 gt {
          dup dup 20 div dup 2 array astore exch 40 div setdash
      } { [0.3 0.7] 0.1 setdash } ifelse
      0 exch len {    %for (0, gridspacing, len) 
     dup dup      %duplicate what - gridspacing??
     dup len exch sub moveto     %moveto diagonal?
     len exch sub 0.7 sub exch 0.7 sub exch lineto
     stroke
   }for
 winSize len moveto  len winSize  lineto stroke
  [] 0 setdash
  0.04 setlinewidth 
  currentdict /cutpoint known {
    cutpoint 1 sub
    dup dup -1 moveto len 1 add lineto
    len exch sub dup
    -1 exch moveto len 1 add exch lineto
   stroke
  } if
  0.5 neg dup translate
} bind def 

0.5 dup translate
drawseq_turn
45 rotate


%draw the grid
drawgrid_turn

%start of base pair probability data
2 70 0.1568 ubox
2 71 0.9619 ubox
3 69 0.1395 ubox
3 70 0.7414 ubox
3 72 0.8060 ubox
4 68 0.1157 ubox
4 69 0.6748 ubox
4 71 0.4682 ubox
5 67 0.1065 ubox
5 68 0.6724 ubox
5 70 0.3765 ubox
6 47 0.1250 ubox
6 67 0.6497 ubox
7 46 0.1273 ubox
7 66 0.6008 ubox
8 45 0.1294 ubox
8 48 0.2252 ubox
9 47 0.2335 ubox
10 25 0.7863 ubox
11 24 0.7884 ubox
11 43 0.5215 ubox
11 45 0.2330 ubox
12 23 0.7883 ubox
12 42 0.5493 ubox
12 44 0.2317 ubox
13 22 0.7882 ubox
13 41 0.5528 ubox
13 43 0.2306 ubox
14 40 0.5338 ubox
15 20 0.1027 ubox
16 38 0.5325 ubox
16 40 0.1646 ubox
17 37 0.5639 ubox
17 39 0.1633 ubox
18 36 0.5591 ubox
18 38 0.1125 ubox
19 36 0.2406 ubox
20 34 0.5341 ubox
20 35 0.2514 ubox
21 33 0.4064 ubox
22 32 0.2491 ubox
22 33 0.4413 ubox
23 32 0.5541 ubox
24 31 0.6100 ubox
25 30 0.6092 ubox
26 36 0.2144 ubox
27 35 0.2146 ubox
27 43 0.7269 ubox
28 34 0.2043 ubox
28 42 0.7445 ubox
29 41 0.7467 ubox
30 40 0.7468 ubox
31 39 0.7470 ubox
38 73 0.3242 ubox
39 72 0.3055 ubox
40 73 0.1211 ubox
41 71 0.2953 ubox
41 72 0.1146 ubox
42 70 0.2588 ubox
43 69 0.2613 ubox
43 71 0.2848 ubox
44 68 0.2587 ubox
44 70 0.3418 ubox
45 67 0.2339 ubox
45 68 0.1772 ubox
45 69 0.3617 ubox
45 70 0.1014 ubox
45 72 0.3111 ubox
46 67 0.2550 ubox
46 68 0.3039 ubox
46 69 0.1150 ubox
46 71 0.2540 ubox
47 66 0.2925 ubox
48 67 0.1378 ubox
49 65 0.9938 ubox
50 64 0.9971 ubox
51 63 0.9980 ubox
52 62 0.9980 ubox
53 61 0.9963 ubox
54 59 0.1628 ubox
55 60 0.1625 ubox
showpage
end
%%EOF