[BioRuby-cvs] bioruby/lib/bio/appl/mafft report.rb,1.3,1.4

Katayama Toshiaki k at pub.open-bio.org
Wed Sep 7 21:22:12 EDT 2005


Update of /home/repository/bioruby/bioruby/lib/bio/appl/mafft
In directory pub.open-bio.org:/tmp/cvs-serv9021/lib/bio/appl/mafft

Modified Files:
	report.rb 
Log Message:
* expanded tab at the line head


Index: report.rb
===================================================================
RCS file: /home/repository/bioruby/bioruby/lib/bio/appl/mafft/report.rb,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** report.rb	4 Mar 2005 04:48:41 -0000	1.3
--- report.rb	8 Sep 2005 01:22:10 -0000	1.4
***************
*** 30,47 ****
  
        def initialize(ary, seqclass = nil)
! 	@data = ary
! 	@align = nil
! 	case seqclass
! 	when /PROTEIN/i
! 	  @seqclass = Bio::Sequence::AA
! 	when /[DR]NA/i
! 	  @seqclass = Bio::Sequence::NA
! 	else
! 	  if seqclass.is_a?(Module) then
! 	    @seqclass = seqclass
! 	  else
! 	    @seqclass = Bio::Sequence
! 	  end
! 	end
        end
        attr_reader :data
--- 30,47 ----
  
        def initialize(ary, seqclass = nil)
!         @data = ary
!         @align = nil
!         case seqclass
!         when /PROTEIN/i
!           @seqclass = Bio::Sequence::AA
!         when /[DR]NA/i
!           @seqclass = Bio::Sequence::NA
!         else
!           if seqclass.is_a?(Module) then
!             @seqclass = seqclass
!           else
!             @seqclass = Bio::Sequence
!           end
!         end
        end
        attr_reader :data
***************
*** 49,72 ****
  
        def align
! 	do_parse() unless @align
! 	@align
        end
        alias :alignment :align
  
        def to_fasta(*arg)
! 	align.to_fasta(*arg)
        end
  
        def to_a
! 	@data
        end
  
        private
        def do_parse
! 	return nil if @align
! 	@align = Bio::Alignment.new(@data) do |x|
! 	  [ @seqclass.new(x.seq), x.definition ]
! 	end
! 	nil
        end
  
--- 49,72 ----
  
        def align
!         do_parse() unless @align
!         @align
        end
        alias :alignment :align
  
        def to_fasta(*arg)
!         align.to_fasta(*arg)
        end
  
        def to_a
!         @data
        end
  
        private
        def do_parse
!         return nil if @align
!         @align = Bio::Alignment.new(@data) do |x|
!           [ @seqclass.new(x.seq), x.definition ]
!         end
!         nil
        end
  



More information about the bioruby-cvs mailing list