+ public MsaProperties( final Msa msa, final String removed_seq, final boolean calculate_normalized_shannon_entropy ) {
+ _number_of_sequences = msa.getNumberOfSequences();
+ _length = msa.getLength();
+ _gap_ratio = MsaMethods.calcGapRatio( msa );
+ _removed_seq = removed_seq;
+ _avg_number_of_gaps = MsaMethods.calcNumberOfGapsStats( msa ).arithmeticMean();
+ if ( calculate_normalized_shannon_entropy ) {
+ _entropy7 = MsaMethods.calcNormalizedShannonsEntropy( 7, msa );
+ _entropy21 = MsaMethods.calcNormalizedShannonsEntropy( 21, msa );
+ }
+ else {
+ _entropy7 = -1;
+ _entropy21 = -1;
+ }
+ }
+
+ public final double getEntropy21() {
+ return _entropy21;
+ }
+
+ public final double getEntropy7() {
+ return _entropy7;