Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Merge branch 'develop'

  • Loading branch information...
commit 2bb2e402ae578daf0fed692590275fd4d3cce075 2 parents a1c1423 + ca3525f
Michael Barton authored
58 Gemfile.lock
... ... @@ -0,0 +1,58 @@
  1 +GEM
  2 + remote: http://rubygems.org/
  3 + specs:
  4 + adsf (1.1.1)
  5 + rack (>= 1.0.0)
  6 + colored (1.2)
  7 + cri (2.3.0)
  8 + colored (>= 1.2)
  9 + execjs (1.4.0)
  10 + multi_json (~> 1.0)
  11 + fssm (0.2.10)
  12 + haml (4.0.0)
  13 + tilt
  14 + json (1.7.7)
  15 + listen (0.7.2)
  16 + multi_json (1.6.1)
  17 + nanoc (3.5.0)
  18 + cri (~> 2.2)
  19 + nokogiri (1.5.6)
  20 + rack (1.5.2)
  21 + rack-contrib (1.1.0)
  22 + rack (>= 0.9.1)
  23 + rainpress (1.0)
  24 + rake (10.0.3)
  25 + rb-fsevent (0.9.3)
  26 + rdiscount (2.0.7)
  27 + rubypants (0.2.0)
  28 + sass (3.2.5)
  29 + tilt (1.3.3)
  30 + typogruby (1.0.15)
  31 + rubypants
  32 + uglifier (1.3.0)
  33 + execjs (>= 0.3.0)
  34 + multi_json (~> 1.0, >= 1.0.2)
  35 + w3c_validators (1.2)
  36 + json
  37 + nokogiri
  38 +
  39 +PLATFORMS
  40 + ruby
  41 +
  42 +DEPENDENCIES
  43 + adsf (~> 1.1.0)
  44 + fssm (~> 0.2.0)
  45 + haml (~> 4.0.0)
  46 + listen (~> 0.7.2)
  47 + nanoc (~> 3.5.0)
  48 + nokogiri (~> 1.5.0)
  49 + rack (~> 1.5.0)
  50 + rack-contrib (~> 1.1.0)
  51 + rainpress (~> 1.0.0)
  52 + rake (~> 10.0.0)
  53 + rb-fsevent (~> 0.9.1)
  54 + rdiscount (~> 2.0.0)
  55 + sass (~> 3.2.0)
  56 + typogruby (~> 1.0.15)
  57 + uglifier (~> 1.3.0)
  58 + w3c_validators (~> 1.2.0)
5 config.yaml
@@ -10,11 +10,14 @@ site:
10 10 analytics_token: "UA-1362555-4"
11 11 navigation:
12 12 'about': "/"
13   - 'install': "/install/"
14 13 'scaffold format': "/scaffold-format/"
15 14 'troubleshooting': "/troubleshooting/"
16 15 'mailing list': "/mailing-list/"
17 16 'contribute': "/contribute/"
  17 + guides:
  18 + 'installing': "/install/"
  19 + 'genome annotations': "/managing-annotations/"
  20 + 'a simple genome': "/a-simple-genome/"
18 21 author:
19 22 url: "http://www.michaelbarton.me.uk"
20 23 name: "Michael Barton"
5 content/markup/a-simple-genome.markdown
Source Rendered
... ... @@ -0,0 +1,5 @@
  1 +---
  2 + title: Completing a simple genome
  3 +---
  4 +
  5 +<%= youtube 'jVn62pMnIRA' %>
195 content/markup/getting-started.markdown
Source Rendered
... ... @@ -1,195 +0,0 @@
1   ----
2   - title: "Getting Started"
3   ----
4   -
5   -This page provides a quick introduction to installing scaffolder and creating
6   -a simple scaffold from three nucleotide sequences. Scaffolder has been tested
7   -on Debian and OS X but there may differences on Windows. If you have any
8   -questions or comments feel free to ask on the [scaffolder mailing list][email].
9   -
10   -### Installation
11   -
12   -Scaffolder requires both [Ruby][] and [RubyGems][] to run. These are usually
13   -already installed or can be installed easy on Mac OS X and Linux distributions.
14   -The software can be tested by running the following commands on the console or
15   -terminal (excluding the '$' sign):
16   -
17   -<%= highlight %>
18   -
19   -$ ruby -v
20   -$ gem -v
21   -
22   -<%= endhighlight %>
23   -
24   -If both of these return without error, scaffolder can be installed via RubyGems
25   -using the following command:
26   -
27   -<%= highlight %>
28   -
29   -$ gem install scaffolder scaffolder-tools
30   -
31   -<%= endhighlight %>
32   -
33   -The install can be tests by running the following command. This should print
34   -the list of available scaffolder options.
35   -
36   -<%= highlight %>
37   -
38   -$ scaffolder
39   -
40   -<%= endhighlight %>
41   -
42   -If this fails or returns an error the RubyGems executable directory may not be
43   -in your shell path. The location of this can found using the following command,
44   -the result of which should be added to the $PATH variable in your shell login
45   -script. Examples of updating the shell path are available [for OS X][osx_path]
46   -and [for Linux][linux_path]
47   -
48   -<%= highlight %>
49   -
50   -# Add the output of this your $PATH
51   -$ gem env | grep "EXECUTABLE DIRECTORY" | cut -d : -f 2
52   -
53   -<%= endhighlight %>
54   -
55   -### Creating a simple scaffold
56   -
57   -To begin creating a scaffold, create a text file named 'sequences.fna'
58   -containing the following nucleotide sequences. These will be our example
59   -sequences which we wish to build a scaffold with. The following steps will
60   -progress through creating a simple scaffold.
61   -
62   -<%= highlight %>
63   -
64   ->sequence1
65   -AAAAAAAAAAAA
66   ->sequence2
67   -TTTTTTTTTTTT
68   ->sequence3
69   -GGGGG
70   -
71   -<%= endhighlight %>
72   -
73   -Create the file 'scaffold.yml' and add the content below. This is the scaffold
74   -file specifying how our nucleotide sequences should be joined together.
75   -
76   -<%= highlight %>
77   -
78   ----
79   - - sequence:
80   - source: 'sequence1'
81   -
82   -<%= endhighlight %>
83   -
84   -The scaffold is written in the [YAML][] format. YAML is data serialisation
85   -format which is useful to pass information between computer software but which
86   -also can be easily edited by hand. YAML formatted documents should begin with
87   -three dashes ('---'). The scaffold file is represented as a list of sequence
88   -entries. Using the YAML format each entry is defined by starting with a dash
89   -('-') then indented by two spaces for the remaining lines of the entry.
90   -
91   -As you can see in the code above this scaffold file has only one entry. The
92   -'sequence' tag specifies that this entry is a sequence. The 'source' tag
93   -identifies the name of the sequence to use. The source tag should match the
94   -first space delimited word in the corresponding sequence fasta header.
95   -
96   -The sequence for this simple scaffold is produced by running the scaffolder
97   -sequence command giving the locations of the two files we have just created.
98   -
99   -<%= highlight %>
100   -
101   -$ scaffolder sequence scaffold.yml sequences.fna
102   -
103   -<%= endhighlight %>
104   -
105   -This returns the nucleotide sequence of sequence1. This is as expected as the
106   -scaffold only contains one sequence entry.
107   -
108   -<%= highlight %>
109   -
110   ->.
111   -AAAAAAAAAAAA
112   -
113   -<%= endhighlight %>
114   -
115   -### Adding additional sequences to the scaffold
116   -
117   -A scaffold with only a single sequence is rather simple. Update the scaffold
118   -file so that it now resembles the text below. Here we have added a second
119   -sequence from the fasta file and an unknown region between these two sequences.
120   -
121   -<%= highlight %>
122   -
123   ----
124   - - sequence:
125   - source: 'sequence1'
126   - - unresolved:
127   - length: 5
128   - - sequence:
129   - source: 'sequence2'
130   -
131   -<%= endhighlight %>
132   -
133   -Running the scaffolder command again will generate following super sequence.
134   -This contains the two sequences joined by the 5bp region of 'N' characters we
135   -specified. These unresolved regions can be used for joining contigs by
136   -approximate distances.
137   -
138   -<%= highlight %>
139   -
140   ->.
141   -AAAAAAAAAAAANNNNNTTTTTTTTTTTT
142   -
143   -<%= endhighlight %>
144   -
145   -### Replacing regions of sequence in the scaffold
146   -
147   -Imagine there is a region in sequence1 which we wish to replace. For example
148   -the start of region on is poor quality or it is an already scaffolded set of
149   -contigs containing gaps. Performing PCR would determine the correct sequence in
150   -this area but we need a way to update sequence1 in the scaffold. We can do this
151   -by updating the scaffold file as follows:
152   -
153   -<%= highlight %>
154   -
155   ----
156   - - sequence:
157   - source: 'sequence1'
158   - inserts:
159   - - source: 'sequence3'
160   - open: 3
161   - close: 5
162   - - unresolved:
163   - length: 5
164   - - sequence:
165   - source: 'sequence2'
166   -
167   -<%= endhighlight %>
168   -
169   -Here we have added an insert to sequence1 using the "inserts" tag. This
170   -replaces the region in the range 3...5 (specified by the open and close
171   -coordinates) with sequence3. Running the scaffolder command again we can see
172   -that this is now the case where four guanine bases have been inserted
173   -
174   -<%= highlight %>
175   -
176   ->.
177   -AAGGGGGAAAAAAANNNNNTTTTTTTTTTTT
178   -
179   -<%= endhighlight %>
180   -
181   -This is a brief tutorial for creating a simple scaffold. More complex scaffolds
182   -can be created by adding further sequences and inserts to the scaffold. More
183   -details about the scaffolder format can be found at [the scaffolder API][api]
184   -and the [scaffolder-format man page][format]. Details on the available
185   -scaffolder commands can be found on [the man pages][man].
186   -
187   -[Ruby]: http://www.ruby-lang.org/
188   -[RubyGems]: http://rubygems.org/
189   -[osx_path]: http://stackoverflow.com/questions/135688/setting-environment-variables-in-os-x
190   -[linux_path]: http://www.troubleshooters.com/linux/prepostpath.htm
191   -[man]: /man
192   -[api]: http://rubydoc.info/gems/scaffolder/0.4.1/Scaffolder
193   -[email]: http://groups.google.com/group/scaffolder
194   -[yaml]: http://www.yaml.org/
195   -[format]: /man/scaffolder-format/
5 content/markup/managing-annotations.markdown
Source Rendered
... ... @@ -0,0 +1,5 @@
  1 +---
  2 + title: Managing genome annotations
  3 +---
  4 +
  5 +<%= youtube 'U3HnVWMUb90' %>
1  content/stylesheets/styles.css
@@ -320,6 +320,7 @@ section {
320 320 /* Footer */
321 321
322 322 footer {
  323 + font-size: 12px;
323 324 width:170px;
324 325 float:left;
325 326 position:fixed;
2  layouts/_footer.haml
... ... @@ -1,4 +1,4 @@
7 layouts/_title.haml
@@ -10,3 +10,10 @@
10 10 %a{:href => navigation_link(href)}
11 11 %li
12 12 = name
  13 + %p.header
  14 + = "Video Guides"
  15 + %ul
  16 + - @site.config[:site][:guides].each do |name,href|
  17 + %a{:href => navigation_link(href)}
  18 + %li
  19 + = name
4 lib/content.rb
@@ -5,3 +5,7 @@ def increase_markdown_header(line)
5 5 def anchor(text,id)
6 6 "<h3 id='#{id}'>#{text}</h3>"
7 7 end
  8 +
  9 +def image(url,width=400)
  10 + "<img src='#{relative_path_to(url)}' width=#{width}>"
  11 +end
12 lib/default.rb
... ... @@ -1,14 +1,2 @@
1 1 include Nanoc3::Helpers::Rendering
2 2 include Nanoc3::Helpers::LinkTo
3   -
4   -def highlight
5   - "<pre class=\"class=prettyprint\">"
6   -end
7   -
8   -def endhighlight
9   - "</pre>"
10   -end
11   -
12   -def image(url,width=400)
13   - "<img src='#{relative_path_to(url)}' width=#{width}>"
14   -end
2  lib/header.rb
@@ -39,5 +39,5 @@ def favicon
39 39 end
40 40
41 41 def site_title
42   - [@item[:title],@site.config[:site][:title],@site.config[:author][:name]].compact.uniq * " | "
  42 + @site.config[:site][:title] + " &middot; " + @item[:title]
43 43 end

0 comments on commit 2bb2e40

Please sign in to comment.
Something went wrong with that request. Please try again.