lib/bio/db/primer3.rb in bio-polyploid-tools-0.9.5 vs lib/bio/db/primer3.rb in bio-polyploid-tools-0.9.6
- old
+ new
@@ -59,10 +59,11 @@
attr_accessor :snp_from
attr_accessor :regions
attr_accessor :primer3_errors
attr_accessor :repetitive
attr_accessor :hit_count
+ attr_accessor :snp_type
def line_1_name
"#{gene}:#{position}#{original}>#{snp} #{line_1}}"
end
@@ -123,13 +124,12 @@
@values << "#{original}#{position}#{snp}"
@values << template_length
@values << snp_from.chromosome
@values << regions.size
@values << regions.join("|")
+ @values << snp_type
if primer3_line_1 and primer3_line_2
- @values << primer3_line_1.polymorphism
-
#Block that searches both if both pairs have a TM
primer_2 = primer3_line_2.left_primer_with_coordinates(primer3_line_1.left_coordinates, primer3_line_1.orientation)
primer_2_tm = find_left_primer_temp(primer_2)
primer_1 = primer3_line_1.left_primer_with_coordinates(primer3_line_2.left_coordinates, primer3_line_2.orientation)
primer_1_tm = find_left_primer_temp(primer_1)
@@ -211,11 +211,10 @@
@values << first_candidate.best_pair.product_size
end
end
elsif primer3_line_1
- @values << primer3_line_1.polymorphism
@values << primer3_line_1.left_primer
@values << primer3_line_1.left_primer_snp(self)
@values << primer3_line_1.right_primer
@values << primer3_line_1.type.to_s
@values << primer3_line_1.orientation.to_s
@@ -224,11 +223,10 @@
@values << primer3_line_1.best_pair.right.tm
@values << "first+"
@values << primer3_line_1.best_pair.product_size
elsif primer3_line_2
- @values << primer3_line_2.polymorphism
@values << primer3_line_2.left_primer_snp(self)
@values << primer3_line_2.left_primer
@values << primer3_line_2.right_primer
@values << primer3_line_2.type.to_s
@values << primer3_line_2.orientation.to_s
@@ -767,9 +765,10 @@
snp.position = snp_in.position
snp.snp = snp_in.snp
snp.repetitive = snp_in.repetitive
#puts snp_in.inspect
snp.hit_count = snp_in.hit_count
+ snp.snp_type = snp_in.snp_type
snp.line_1 = @line_1
snp.line_2 = @line_2
snp.snp_from = snp_in
snp.regions = snp_in.exon_list.values.collect { |x| x.collect {|y| y.target_region.to_s }}
@snp_hash[snp.to_s] = snp