diff --git a/include/tracker.h b/include/tracker.h
index e536fec9ccf7b1977de8bab1fc75d3189796ab92..0798fe8d0641fead153f2285ed8f35bc74cab93a 100644
--- a/include/tracker.h
+++ b/include/tracker.h
@@ -357,13 +357,12 @@ inline QTextStream& operator>>(QTextStream& s, TrackPerson& tp)
     trjInfoLine >> col;
     tp.setColor(col);
     //cout << " col: " << tp.color();
-    trjInfoLine >> n; // size of list
-
     if (Petrack::trcVersion > 3)
     {
         trjInfoLine >> markerID;
         tp.setMarkerID(markerID);
     }
+    trjInfoLine >> n; // size of list
     if (Petrack::trcVersion > 2) // Reading the comment line
     {
         //s.skipWhiteSpace(); // skip white spaces for reading the comment line without this the reading makes some problems
@@ -386,15 +385,13 @@ inline QTextStream& operator>>(QTextStream& s, TrackPerson& tp)
 
 inline QTextStream& operator<<(QTextStream& s, const TrackPerson& tp)
 {
+    s << tp.nr() << " " << tp.height() << " " << tp.firstFrame() << " " << tp.lastFrame() << " " << tp.colCount() << " " << tp.color();
     if (Petrack::trcVersion > 3)
     {
-        s << tp.nr() << " " << tp.height() << " " << tp.firstFrame() << " " << tp.lastFrame() << " " << tp.colCount() << " " << tp.color() << " " << tp.size() << " " << tp.getMarkerID()<< endl;
+        s << " " <<tp.getMarkerID();
     }
-    else if (Petrack::trcVersion <= 3)
-    {
-        s << tp.nr() << " " << tp.height() << " " << tp.firstFrame() << " " << tp.lastFrame() << " " << tp.colCount() << " " << tp.color() << " " << tp.size() << endl;
-    }
-    s << tp.comment() << endl;
+    s << " " << tp.size();
+    s << endl << tp.comment() << endl;
     for (int i = 0; i < tp.size(); ++i)
         s << tp.at(i) << endl;
     return s;
@@ -402,15 +399,13 @@ inline QTextStream& operator<<(QTextStream& s, const TrackPerson& tp)
 
 inline std::ostream& operator<<(std::ostream& s, const TrackPerson& tp)
 {
+    s << tp.nr() << " " << tp.height() << " " << tp.firstFrame() << " " << tp.lastFrame() << " " << tp.colCount() << " " << tp.color();
     if(Petrack::trcVersion > 3)
     {
-        s << tp.nr() << " " << tp.height() << " " << tp.firstFrame() << " " << tp.lastFrame() << " " << tp.colCount() << " " << tp.color() << " " << tp.size() << " " << tp.getMarkerID()<< endl;
-    }
-    else if (Petrack::trcVersion <= 3)
-    {
-        s << tp.nr() << " " << tp.height() << " " << tp.firstFrame() << " " << tp.lastFrame() << " " << tp.colCount() << " " << tp.color() << " " << tp.size() << endl;
+        s <<  " " << tp.getMarkerID();
     }
-        s << tp.comment() << endl;
+    s << " " << tp.size();
+    s << endl << tp.comment() << endl;
     for (int i = 0; i < tp.size(); ++i)
         s << tp.at(i) << endl;
     return s;