code: def get_N50(readlengths):
      
      return readlengths[np.where(np.cumsum(readlengths) >= 0.5 * np.sum(readlengths))[0][0]]
docs: Calculate read length N50.
  
      Based on https://github.com/PapenfussLab/Mungo/blob/master/bin/fasta_stats.py