def report_read_counts(self, filename, grp_wise=False, reorder='<STR_LIT>', notes=None):
expected_read_counts = self.probability.sum(axis=APM.Axis.READ)<EOL>if grp_wise:<EOL><INDENT>lname = self.probability.gname<EOL>expected_read_counts = expected_read_counts * self.grp_conv_mat<EOL><DEDENT>else:<EOL><INDENT>lname = self.probability.lname<EOL><DEDENT>total_read_counts = expected_read_counts.sum(axis=<NUM_LIT:0>)<EOL>if reorder == '<STR_LIT>':<EOL><INDENT>report_order = np.argsort(total_read_counts.flatten())<EOL>report_order = report_order[::-<NUM_LIT:1>]<EOL><DEDENT>elif reorder == '<STR_LIT>':<EOL><INDENT>report_order = np.argsort(total_read_counts.flatten())<EOL><DEDENT>elif reorder == '<STR_LIT>':<EOL><INDENT>report_order = np.arange(len(lname))  <EOL><DEDENT>cntdata = np.vstack((expected_read_counts, total_read_counts))<EOL>fhout = open(filename, '<STR_LIT:w>')<EOL>fhout.write("<STR_LIT>" + "<STR_LIT:\t>".join(self.probability.hname) + "<STR_LIT>")<EOL>if notes is not None:<EOL><INDENT>fhout.write("<STR_LIT>")<EOL><DEDENT>fhout.write("<STR_LIT:\n>")<EOL>for locus_id in report_order:<EOL><INDENT>lname_cur = lname[locus_id]<EOL>fhout.write("<STR_LIT:\t>".join([lname_cur] + list(map(str, cntdata[:, locus_id].ravel()))))<EOL>if notes is not None:<EOL><INDENT>fhout.write("<STR_LIT>" % notes[lname_cur])<EOL><DEDENT>fhout.write("<STR_LIT:\n>")<EOL><DEDENT>fhout.close()<EOL>
Exports expected read counts

:param filename: File name for output
:param grp_wise: whether the report is at isoform level or gene level
:param reorder: whether the report should be either 'decreasing' or 'increasing' order or just 'as-is'
:return: Nothing but the method writes a file