protected BlockStats getBlockStats(final boolean logDetails) { final BlockStats stats = new BlockStats(); for (final Map.Entry<String, ChrIndex> elt : chrIndices.entrySet()) { final List<Block> blocks = elt.getValue().getBlocks(); if (blocks != null) { final int nBlocks = blocks.size(); int nEmptyBlocks = 0; for (final Block b : elt.getValue().getBlocks()) { if (b.getSize() == 0) nEmptyBlocks++; } stats.empty += nEmptyBlocks; stats.total += nBlocks; if (logDetails) System.out.println(String.format(" %s => %d blocks, %d empty, %.2f", elt.getKey(), nBlocks, nEmptyBlocks, (100.0 * nEmptyBlocks) / nBlocks)); } } return stats; }
protected BlockStats getBlockStats(final boolean logDetails) { final BlockStats stats = new BlockStats(); for (final Map.Entry<String, ChrIndex> elt : chrIndices.entrySet()) { final List<Block> blocks = elt.getValue().getBlocks(); if (blocks != null) { final int nBlocks = blocks.size(); int nEmptyBlocks = 0; for (final Block b : elt.getValue().getBlocks()) { if (b.getSize() == 0) nEmptyBlocks++; } stats.empty += nEmptyBlocks; stats.total += nBlocks; if (logDetails) System.out.println(String.format(" %s => %d blocks, %d empty, %.2f", elt.getKey(), nBlocks, nEmptyBlocks, (100.0 * nEmptyBlocks) / nBlocks)); } } return stats; }
protected BlockStats getBlockStats(final boolean logDetails) { final BlockStats stats = new BlockStats(); for (final Map.Entry<String, ChrIndex> elt : chrIndices.entrySet()) { final List<Block> blocks = elt.getValue().getBlocks(); if (blocks != null) { final int nBlocks = blocks.size(); int nEmptyBlocks = 0; for (final Block b : elt.getValue().getBlocks()) { if (b.getSize() == 0) nEmptyBlocks++; } stats.empty += nEmptyBlocks; stats.total += nBlocks; if (logDetails) System.out.println(String.format(" %s => %d blocks, %d empty, %.2f", elt.getKey(), nBlocks, nEmptyBlocks, (100.0 * nEmptyBlocks) / nBlocks)); } } return stats; }