ojRecalculate(); totalImages=ojNImages(); ojNumCheck=newArray(totalImages); for (i=1;i<=totalImages;i++){ first=ojFirstObject(i); last=ojLastObject(i); ojNumCheck[i-1]=last-first+1; } for (i=1;i0 ) { if(markerNameCodes=="") type=markers[i]; else{ type=List.get( markers[i]); List.set(type,markers[i]); } } //print("n"+n+" imageoffset "+imageOffset+" test="+test+" type="+type); } if (type==""){exit("Something is wrong with the columns in your object file. They may not match the names of your markers");} setResult("Final S"+session,n-1,type); setResult("S "+session,n-1,type); if(markerNameCodes=="") { X=round(ojResult(type+"_xpos",n+imageOffset)); Y=round(ojResult(type+"_ypos",n+imageOffset)); Z=round(ojResult(type+"_zpos",n+imageOffset)); }else{ //print(n+imageOffset); X=round(ojResult(List.get(type)+"_xpos",n+imageOffset)); Y=round(ojResult(List.get(type)+"_ypos",n+imageOffset)); Z=round(ojResult(List.get(type)+"_zpos",n+imageOffset)); } setResult("xpos S"+session, n-1, X); setResult("ypos S"+session, n-1, Y); setResult("zpos S"+session, n-1, Z); //blank by default setResult("Original S"+session,n-1," "); setResult("Checked S"+session,n-1," "); if (ojColumnNumber("OrigType")>0){ //check if the track changes mode is on temp=ojResultString("OrigType",n+imageOffset); setResult("Original S"+session,n-1,List.get(temp)); } if (ojColumnNumber("CheckedType")>0){ temp=ojResultString("CheckedType",n+imageOffset); setResult("Checked S"+session,n-1,List.get(temp)); } } } updateResults(); saveAs("results",path+name+".csv"); if (startsWith(getInfo("os.name"), "Windows")){ // forward slash is an escape character btw. need those quotations //print("copy "+ "\""+ojGetProjectPath()+"*.csv\" "+"\""+ojGetProjectPath()+"CombinedResults.csv\""); //print("cmd.exe /C type NUL > "+"\""+ojGetProjectPath()+"CombinedResults.csv\""); exec("cmd.exe /C type NUL > "+"\""+ojGetProjectPath()+"CombinedResults.csv\""); exec("cmd.exe /C copy /y "+ "\""+ojGetProjectPath()+"*.csv\" "+"\""+ojGetProjectPath()+"CombinedResults.csv\""); // below is messy but gets rid of other headers open(ojGetProjectPath()+"CombinedResults.csv"); updateResults(); delArray=newArray(); for(n=0;n