From: Bo Li Date: Thu, 25 Aug 2011 14:35:18 +0000 (-0500) Subject: rsem v1.1.11, allow spaces appear in field seqname and attributes gene_id, transcript... X-Git-Url: https://git.donarmstrong.com/?p=rsem.git;a=commitdiff_plain;h=90df7a1408511063de96e29658ffa289d43cc0bb rsem v1.1.11, allow spaces appear in field seqname and attributes gene_id, transcript_id in GTF files --- diff --git a/BamWriter.h b/BamWriter.h index fd0b8b7..b39400f 100644 --- a/BamWriter.h +++ b/BamWriter.h @@ -479,7 +479,7 @@ void BamWriter::work(HitWrapper wrapper, Transcripts& transcripts) bam_destroy1(b); bam_destroy1(b2); - if (verbose) { printf("Bam output file is generated!"); } + if (verbose) { printf("Bam output file is generated!\n"); } } void BamWriter::tr2chr(const Transcript& transcript, int sp, int ep, int& pos, int& n_cigar, std::vector& data) { diff --git a/Transcript.h b/Transcript.h index 8d7be7a..90f6e67 100644 --- a/Transcript.h +++ b/Transcript.h @@ -113,7 +113,10 @@ void Transcript::read(std::ifstream& fin) { int s; std::string tmp; - fin>>transcript_id>>gene_id>>seqname>>tmp>>length; + getline(fin, transcript_id); + getline(fin, gene_id); + getline(fin, seqname); + fin>>tmp>>length; assert(tmp.length() == 1 && (tmp[0] == '+' || tmp[0] == '-')); strand = tmp[0]; structure.clear(); @@ -130,7 +133,10 @@ void Transcript::read(std::ifstream& fin) { void Transcript::write(std::ofstream& fout) { int s = structure.size(); - fout<