class Bio::SiRNA::ShRNA
Bio::SiRNA::ShRNA
¶ ↑
Designing shRNA.
Attributes
Public Class Methods
Source
# File lib/bio/util/sirna.rb 235 def initialize(pair) 236 @pair = pair 237 end
Input is a Bio::SiRNA::Pair
object (the target sequence).
Public Instance Methods
Source
# File lib/bio/util/sirna.rb 252 def block_it(method = 'piGENE') 253 top = Bio::Sequence::NA.new('CACC') # top_strand_shrna_overhang 254 bot = Bio::Sequence::NA.new('AAAA') # bottom_strand_shrna_overhang 255 fwd = @pair.sense 256 rev = @pair.sense.complement 257 258 case method 259 when 'BLOCK-iT' 260 # From BLOCK-iT's manual 261 loop_fwd = Bio::Sequence::NA.new('CGAA') 262 loop_rev = loop_fwd.complement 263 when 'piGENE' 264 # From piGENE document 265 loop_fwd = Bio::Sequence::NA.new('GTGTGCTGTCC') 266 loop_rev = loop_fwd.complement 267 else 268 raise NotImplementedError 269 end 270 271 if /^G/i =~ fwd 272 @top_strand = top + fwd + loop_fwd + rev 273 @bottom_strand = bot + fwd + loop_rev + rev 274 else 275 @top_strand = top + 'G' + fwd + loop_fwd + rev 276 @bottom_strand = bot + fwd + loop_rev + rev + 'C' 277 end 278 end
same as design(‘BLOCK-iT’). method can be one of ‘piGENE’ (default) and ‘BLOCK-iT’.
Source
# File lib/bio/util/sirna.rb 240 def design(method = 'BLOCK-iT') 241 case method 242 when 'BLOCK-iT' 243 block_it 244 else 245 raise NotImplementedError 246 end 247 end
only the ‘BLOCK-iT’ rule is implemented for now.
Source
# File lib/bio/util/sirna.rb 281 def report 282 # raise NomethodError for compatibility 283 raise NoMethodError if !defined?(@top_strand) || !@top_strand 284 report = "### shRNA\n".dup 285 report << "Top strand shRNA (#{@top_strand.length} nt):\n" 286 report << " 5'-#{@top_strand.upcase}-3'\n" 287 report << "Bottom strand shRNA (#{@bottom_strand.length} nt):\n" 288 report << " 3'-#{@bottom_strand.reverse.upcase}-5'\n" 289 end
human readable report