view test-data/2.cluster.top5.alirna.ps @ 17:f93c868203cc draft default tip

planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/GraphClust/CollectResults commit 4406735e44aba20859c252be39f4e99df28c7a92
author rnateam
date Sat, 27 Oct 2018 13:23:06 -0400
parents
children
line wrap: on
line source

%!PS-Adobe-3.0 EPSF-3.0
%%Creator: ViennaRNA-2.3.1
%%CreationDate: Tue May 30 20:24:21 2017
%%Title: RNA Secondary Structure Plot
%%BoundingBox: 0 0 700 700
%%DocumentFonts: Helvetica
%%Pages: 1
%%EndComments

%Options: --noLP 
% to switch off outline pairs of sequence comment or
% delete the appropriate line near the end of the file

%%BeginProlog
/RNAplot 100 dict def
RNAplot begin
/fsize  14 def
/outlinecolor {0.2 setgray} bind def
/paircolor    {0.2 setgray} bind def
/seqcolor     {0   setgray} bind def
/cshow  { dup stringwidth pop -2 div fsize -3 div rmoveto show} bind def
/min { 2 copy gt { exch } if pop } bind def
/max { 2 copy lt { exch } if pop } bind def
/arccoords { % i j arccoords
  % puts optimal x1 y1 x2 y2 coordinates used in bezier curves from i to j
  % onto the stack
  dup 3 -1 roll dup 4 -1 roll lt dup dup 5 2 roll {exch} if
  dup 3 -1 roll dup 3 -1 roll exch sub 1 sub dup
  4 -2 roll 5 -1 roll {exch} if 4 2 roll
  sequence length dup 2 div exch 3 1 roll lt 
  {exch 5 -1 roll pop 4 -2 roll exch 4 2 roll}
  { 4 2 roll 5 -1 roll dup 6 1 roll {exch} if
    4 -2 roll exch pop dup 3 -1 roll dup 4 1 roll
    exch add 4 -1 roll dup 5 1 roll sub 1 sub
    5 -1 roll not {4 -2 roll exch 4 2 roll} if
  }ifelse
   % compute the scalingfactor and prepare (1-sf) and sf*r
  2 mul exch cpr 3 1 roll div dup
  3 -1 roll mul exch 1 exch sub exch
   % compute the coordinates
  3 -1 roll 1 sub coor exch get aload pop % get coord for i
  4 -1 roll dup 5 1 roll mul 3 -1 roll dup 4 1 roll add exch % calculate y1
  4 -1 roll dup 5 1 roll mul 3 -1 roll dup 4 1 roll add exch % calculate x1
  5 -1 roll 1 sub coor exch get aload pop % get coord for j
  % duplicate j coord
  dup 3 -1 roll dup 4 1 roll exch 8 2 roll
  6 -1 roll dup 7 1 roll mul 5 -1 roll dup 6 1 roll add exch % calculate y2
  6 -1 roll mul 5 -1 roll add exch % calculate x2
  6 -2 roll % reorder
} bind def
/drawoutline {
  gsave outlinecolor newpath
  coor 0 get aload pop 0.8 0 360 arc % draw 5' circle of 1st sequence
  currentdict /cutpoint known        % check if cutpoint is defined
  {coor 0 cutpoint getinterval
   {aload pop lineto} forall         % draw outline of 1st sequence
   coor cutpoint 1 add get aload pop
   2 copy moveto 0.8 0 360 arc       % draw 5' circle of 2nd sequence
   coor cutpoint 1 add coor length cutpoint 1 add sub getinterval
   {aload pop lineto} forall}        % draw outline of 2nd sequence
  {coor {aload pop lineto} forall}   % draw outline as a whole
  ifelse
  stroke grestore
} bind def
/drawpairs {
  paircolor
  0.7 setlinewidth
  [9 3.01] 9 setdash
  newpath
  pairs {aload pop
      currentdict (cpr) known
      { exch dup
        coor  exch 1 sub get aload pop moveto
        exch arccoords curveto
      }
      { coor exch 1 sub get aload pop moveto
        coor exch 1 sub get aload pop lineto
      }ifelse
  } forall
  stroke
} bind def
% draw bases
/drawbases {
  [] 0 setdash
  seqcolor
  0
  coor {
    aload pop moveto
    dup sequence exch 1 getinterval cshow
    1 add
  } forall
  pop
} bind def

/init {
  /Helvetica findfont fsize scalefont setfont
  1 setlinejoin
  1 setlinecap
  0.8 setlinewidth
  % find the coordinate range
  /xmax -1000 def /xmin 10000 def
  /ymax -1000 def /ymin 10000 def
  coor {
      aload pop
      dup ymin lt {dup /ymin exch def} if
      dup ymax gt {/ymax exch def} {pop} ifelse
      dup xmin lt {dup /xmin exch def} if
      dup xmax gt {/xmax exch def} {pop} ifelse
  } forall
  /size {xmax xmin sub ymax ymin sub max} bind def
  /width {xmax xmin sub} bind def
  /height {ymax ymin sub} bind def
  10 10 translate
  680 size 10 add div dup scale
  size width sub width xmin sub xmax sub add 2 div 5 add
  size height sub height ymin sub ymax sub add 2 div 5 add
  translate
} bind def
end
RNAplot begin
% extra definitions for standard anotations
/min { 2 copy gt { exch } if pop } bind def
/BLACK { 0 0 0 } def
/RED   { 1 0 0 } def
/GREEN { 0 1 0 } def
/BLUE  { 0 0 1 } def
/WHITE { 1 1 1 } def
/LabelFont { % font size LabelFont
  exch findfont exch fsize mul scalefont setfont
} bind def
/Label { % i dx dy (text) Label
  % write text at base i plus offset dx, dy
  4 3 roll 1 sub coor exch get aload pop moveto
  3 1 roll fsize mul exch fsize mul exch rmoveto
  show
} bind def
/cmark { % i cmark   draw circle around base i
  newpath 1 sub coor exch get aload pop
  fsize 2 div 0 360 arc stroke
} bind def
/gmark { % i j c gmark
  % draw basepair i,j with c counter examples in gray
  gsave
  3 min [0 0.33 0.66 0.9] exch get setgray
  1 sub dup coor exch get aload pop moveto
  sequence exch 1 getinterval cshow
  1 sub dup coor exch get aload pop moveto
  sequence exch 1 getinterval cshow
  grestore
} bind def
/segmark { % f i j lw r g b segmark
  % mark segment [i,j] with outline width lw and color rgb
  % use omark and Fomark instead
  gsave
  setrgbcolor setlinewidth
  newpath
  1 sub exch 1 sub dup
  coor exch get aload pop moveto
  currentdict (cpr) known
  {
    3 -1 roll dup 4 1 roll dup
    {
      3 1 roll dup 3 -1 roll dup
      4 1 roll exch 5 2 roll exch
    }
    {
      3 1 roll exch
    } ifelse
    1 exch { coor exch get aload pop lineto } for
    {
      dup 3 1 roll 1 add exch 1 add arccoords pop pop
      4 2 roll 5 -1 roll coor exch get aload pop curveto
    } if
  }
  {
    exch 1 exch {
      coor exch get aload pop lineto
    } for
  } ifelse
  { closepath fill } if  stroke
  grestore
} bind def
/omark { % i j lw r g b omark
  % stroke segment [i..j] with linewidth lw, color rgb
  false 7 1 roll segmark
} bind def
/Fomark { % i j r g b Fomark
  % fill segment [i..j] with color rgb
  % should precede drawbases
  1 4 1 roll true 7 1 roll segmark
} bind def
/BFmark{ % i j k l r g b BFmark
  % fill block between pairs (i,j) and (k,l) with color rgb
  % should precede drawbases
  gsave
  setrgbcolor
  newpath
  currentdict (cpr) known
  {
    dup 1 sub coor exch get aload pop moveto % move to l
    dup 1 sub 4 -1 roll dup 5 1 roll 1 sub 1 exch
    { coor exch get aload pop lineto } for % lines from l to j
    3 -1 roll 4 -1 roll dup 5 1 roll arccoords curveto % curve from j to i
    exch dup 4 -1 roll 1 sub exch 1 sub 1 exch
    { coor exch get aload pop lineto } for % lines from i to k
    exch arccoords curveto% curve from k to l
  }
  {  exch 4 3 roll exch 1 sub exch 1 sub dup
     coor exch get aload pop moveto
     exch 1 exch { coor exch get aload pop lineto } for
     exch 1 sub exch 1 sub dup
     coor exch get aload pop lineto
     exch 1 exch { coor exch get aload pop lineto } for
  } ifelse
    closepath fill stroke
   grestore
} bind def
/hsb {
  dup 0.3 mul 1 exch sub sethsbcolor
} bind def
/colorpair { % i j hue sat colorpair
  % draw basepair i,j in color
  % 1 index 0.00 ne {
  gsave
  newpath
  hsb
  fsize setlinewidth
  currentdict (cpr) known
  {
    exch dup
    coor  exch 1 sub get aload pop moveto
    exch arccoords curveto
  }
  { 1 sub coor exch get aload pop moveto
    1 sub coor exch get aload pop lineto
  } ifelse
   stroke
   grestore
   % } if
} bind def
end

%%EndProlog
RNAplot begin
% data start here
/sequence (\
ACCAUCCUUUUCUUGGGGUUGCACUACUGUCCAAUGAGCACAUAGUGAGGGCAGUACUGCUAACGCCUACACAACACACCCACAUCAACUAGAGCUUUGC\
) def
/coor [
[102.77672577 319.04476929]
[90.46199799 310.08557129]
[82.86160278 296.88882446]
[81.29235077 281.74096680]
[86.02611542 267.26647949]
[96.24275970 255.97311401]
[110.17218018 249.81752014]
[110.17218018 234.81752014]
[110.17218018 219.81752014]
[110.17218018 204.81752014]
[99.49130249 194.49984741]
[99.27762604 179.28770447]
[110.17218018 168.15458679]
[110.17218018 153.15458679]
[110.17218018 138.15458679]
[106.02764893 123.73851776]
[98.06128693 111.02880096]
[89.89822388 98.44451141]
[81.54043579 85.98868561]
[73.18265533 73.53286743]
[64.63217163 61.20853424]
[55.89105606 49.01866531]
[47.14994049 36.82879639]
[32.82023239 30.12281990]
[31.69130898 15.27105904]
[22.95019341 3.08119035]
[14.20907784 -9.10867786]
[5.46796179 -21.29854774]
[-3.27315354 -33.48841476]
[-12.01426888 -45.67828369]
[-20.75538445 -57.86815262]
[-29.49650002 -70.05802155]
[-40.43203354 -69.10051727]
[-50.66823959 -72.83345032]
[-58.30468369 -80.49013519]
[-61.95487976 -90.58245850]
[-60.99773407 -101.18975830]
[-55.68206024 -110.32431030]
[-63.24930573 -123.27563477]
[-78.33963013 -128.72189331]
[-83.35356903 -143.96131897]
[-74.44485474 -157.30351257]
[-58.44750214 -158.51351929]
[-47.63329697 -146.66308594]
[-50.29797745 -130.84288025]
[-42.73073578 -117.89155579]
[-23.69388771 -114.56418610]
[-12.84335899 -98.21372986]
[-17.30663109 -78.79914093]
[-8.56551647 -66.60926819]
[0.17559953 -54.41939926]
[8.91671467 -42.22953033]
[17.65783119 -30.03966331]
[26.39894676 -17.84979439]
[35.14006042 -5.65992498]
[43.88117599 6.52994347]
[57.58565903 12.36401939]
[59.33980942 28.08768082]
[68.08092499 40.27754974]
[76.82203674 52.46741867]
[83.39369965 56.13331604]
[85.63847351 65.17508698]
[93.99625397 77.63090515]
[102.35404205 90.08672333]
[109.22463226 94.59117126]
[110.77100372 103.06243134]
[118.73737335 115.77215576]
[120.40499115 100.86514282]
[126.48009491 87.15043640]
[136.39979553 75.89878845]
[149.24496460 68.15272522]
[163.82543945 64.62996674]
[178.79025269 65.65692139]
[192.75280762 71.13842010]
[204.41941833 80.56658936]
[212.70909119 93.06784058]
[216.85374451 107.48386383]
[216.46936035 122.47894287]
[211.59153748 136.66368103]
[202.67224121 148.72378540]
[190.53790283 157.54182434]
[176.31283569 162.30076599]
[161.31506348 162.55963135]
[146.93423462 158.29446411]
[134.50280762 149.90045166]
[125.17218018 138.15458679]
[125.17218018 153.15458679]
[125.17218018 168.15458679]
[136.06672668 179.28770447]
[135.85304260 194.49984741]
[125.17218018 204.81752014]
[125.17218018 219.81752014]
[125.17218018 234.81752014]
[125.17218018 249.81752014]
[139.10159302 255.97311401]
[149.31823730 267.26647949]
[154.05200195 281.74096680]
[152.48275757 296.88882446]
[144.88235474 310.08557129]
[132.56762695 319.04476929]
] def
/pairs [
[7 94]
[8 93]
[9 92]
[10 91]
[13 88]
[14 87]
[15 86]
[16 67]
[17 66]
[18 64]
[19 63]
[20 62]
[21 60]
[22 59]
[23 58]
[25 56]
[26 55]
[27 54]
[28 53]
[29 52]
[30 51]
[31 50]
[32 49]
[38 46]
[39 45]
] def

init

% Start Annotations
7 94 0.0 0.6 colorpair
8 93 0.0 1 colorpair
9 92 0.0 1 colorpair
10 91 0.0 1 colorpair
13 88 0.0 1 colorpair
14 87 0.0 1 colorpair
15 86 0.0 1 colorpair
16 67 0.0 1 colorpair
17 66 0.16 1 colorpair
18 64 0.0 1 colorpair
19 63 0.0 1 colorpair
20 62 0.0 1 colorpair
21 60 0.0 1 colorpair
22 59 0.0 1 colorpair
23 58 0.16 1 colorpair
25 56 0.0 1 colorpair
26 55 0.0 1 colorpair
27 54 0.0 1 colorpair
28 53 0.0 1 colorpair
29 52 0.0 1 colorpair
30 51 0.0 1 colorpair
31 50 0.0 1 colorpair
32 49 0.16 1 colorpair
38 46 0.0 1 colorpair
39 45 0.32 1 colorpair

% End Annotations
% switch off outline pairs or bases by removing these lines
drawoutline
drawpairs
drawbases
% Start Annotations
7 94 1 gmark
66 cmark
23 cmark
32 cmark
39 cmark
45 cmark

% End Annotations
% show it
showpage
end
%%EOF