Changeset 3342


Ignore:
Timestamp:
Nov 6, 2014, 6:26:24 AM (7 years ago)
Author:
Peter
Message:

merge 0.12.2 into trunk

Location:
trunk
Files:
8 edited
1 copied

Legend:

Unmodified
Added
Removed
  • trunk

  • trunk/NEWS

    r3306 r3342  
    1212
    1313yat 0.12.x series from http://dev.thep.lu.se/yat/svn/branches/0.12-stable
     14
     15version 0.12.2 (released 6 November 2014)
     16  - Fixed bug in Aligner that internal data was not cleared between
     17    alignments resulting in incorrect CIGAR (see bug #820)
     18  - Fixed QuantileNormalizer seqfault when input had more columns than
     19    rows (see bug #815)
     20
     21  A complete list of closed tickets can be found here [[br]]
     22  http://dev.thep.lu.se/yat/query?status=closed&milestone=yat+0.12.2
    1423
    1524version 0.12.1 (released 21 August 2014)
  • trunk/m4/version.m4

    r3306 r3342  
    7878# yat-0.12   9:0:0
    7979# yat-0.12.1 9:1:0
     80# yat-0.12.2 9:2:0
    8081#
    8182# *Accidently, the libtool number was not updated for yat 0.5
  • trunk/test/Makefile.am

    r3329 r3342  
    4848  test/bam_pair_iterator.test \
    4949  test/cigar.test \
     50  test/cigar2.test \
    5051  test/cigar_iterator.test \
    5152  test/codon.test test/commandline.test \
  • trunk/test/normalization.cc

    r3330 r3342  
    293293{
    294294  suite.err() << "Testing QuantileNormalizer\n";
    295  
    296295  utility::Matrix m(2,2);
    297296  m(0,0) = 0;
     
    309308  suite.err() << "Testing m(1,1)\n";
    310309  suite.add(suite.equal(m(1,1), 2));
     310
     311  // testing with landscape-shaped data matrix
     312  m.resize(2, 10);
     313  qn(m, m);
    311314}
    312315
  • trunk/yat/normalizer/QuantileNormalizer.cc

    r2992 r3342  
    44  Copyright (C) 2005, 2006 Jari Häkkinen, Markus Ringnér
    55  Copyright (C) 2007, 2008 Jari Häkkinen, Peter Johansson
    6   Copyright (C) 2012 Peter Johansson
     6  Copyright (C) 2012, 2014 Peter Johansson
    77
    88  This file is part of the yat library, http://dev.thep.lu.se/yat
     
    4343    assert(data.columns()==result.columns());
    4444
    45     std::vector<std::vector<size_t> > index(data.rows());
    46     for (size_t column=0; column<data.columns(); ++column)
     45    std::vector<std::vector<size_t> > index(data.columns());
     46    for (size_t column=0; column<data.columns(); ++column) {
     47      assert(column<index.size());
    4748      utility::sort_index(index[column], data.column_const_view(column));
    48      
     49    }
     50
    4951    for (size_t rank=0; rank<data.rows(); ++rank) {
    5052      statistics::Averager a;
    51       for (size_t column=0; column<data.columns(); ++column)
     53      for (size_t column=0; column<data.columns(); ++column) {
     54        assert(column<index.size());
     55        assert(rank<index[column].size());
    5256        a.add(data(index[column][rank], column));
     57      }
    5358      double mean = a.mean();
    54       for (size_t column=0; column<data.columns(); ++column)
     59      for (size_t column=0; column<data.columns(); ++column) {
     60        assert(column<index.size());
    5561        result(index[column][rank], column) = mean;
     62      }
    5663    }
    5764  }
  • trunk/yat/utility/Aligner.cc

    r3330 r3342  
    7878
    7979    columns_ = x.columns();
    80     alignment_.resize(columns_*x.rows(), none);
     80    alignment_.assign(columns_*x.rows(), none);
    8181
    8282    for (size_t i=1; i<x.rows(); ++i)
  • trunk/yat/utility/SmithWaterman.h

    r3205 r3342  
    9696       Calculate a dot-matrix of size query_end-query_begin X
    9797       reference_end-reference_begin where the element ij is 1.0 if
    98        query_begin[i] == reference_begin[j] and -mismatch otherwise.
     98       reference_begin[i] == query_begin[j] and -mismatch otherwise.
    9999     */
    100100    template<typename RandomAccessIterator1, typename RandomAccessIterator2>
    101     double operator()(RandomAccessIterator1 query_begin,
    102                       RandomAccessIterator1 query_end,
    103                       RandomAccessIterator2 reference_begin,
    104                       RandomAccessIterator2 reference_end,
     101    double operator()(RandomAccessIterator1 reference_begin,
     102                      RandomAccessIterator1 reference_end,
     103                      RandomAccessIterator2 query_begin,
     104                      RandomAccessIterator2 query_end,
    105105                      double mismatch=0);
    106106
Note: See TracChangeset for help on using the changeset viewer.