X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=corraxescommand.cpp;h=c4454a5181c719302011e6e98410408826183735;hb=c9a311f0c621a2e88abf7b2efbe74e9aa1e88a8d;hp=f8083cc01c10a23b4626c6ea2ccd285a15f59c87;hpb=49d2b7459c5027557564b21e9487dadafbbbdc96;p=mothur.git diff --git a/corraxescommand.cpp b/corraxescommand.cpp index f8083cc..c4454a5 100644 --- a/corraxescommand.cpp +++ b/corraxescommand.cpp @@ -925,16 +925,11 @@ int CorrAxesCommand::getMetadata(){ m->openInputFile(metadatafile, in); string headerLine = m->getline(in); m->gobble(in); - istringstream iss (headerLine,istringstream::in); - - //read the first label, because it refers to the groups - string columnLabel; - iss >> columnLabel; m->gobble(iss); + vector pieces = m->splitWhiteSpace(headerLine); //save names of columns you are reading - while (!iss.eof()) { - iss >> columnLabel; m->gobble(iss); - metadataLabels.push_back(columnLabel); + for (int i = 1; i < pieces.size(); i++) { + metadataLabels.push_back(pieces[i]); } int count = metadataLabels.size();