; REVERSE ORDER, SEVEN COLUMNS ; ; NOTE: Starting with SPIDER version 19, DOC SORT can reverse order fr ?input doc to be reversed?[input_unreversed_doc] fr ?output reversed doc?[output_reversed_doc] fr l [temp_incore]tmp_incore ; get #rows (x39) ud n,x39 [input_unreversed_doc] ; prepare in-core file sd ic new [temp_incore] (7,x39) ; #columns, #rows ; loop through rows do lb3 x30 = 1,x39 ; count from end [from-end] = x39-x30+1 ; read temp doc ud ic [from-end],x31,x32,x33,x34,x35,x36,x37 [input_unreversed_doc] ; write to output sd ic x30,x31,x32,x33,x34,x35,x36,x37 [temp_incore] lb3 ; end particle-loop ; clean up ud ice [input_unreversed_doc] ; copy to disk sd ic copy [temp_incore] [output_reversed_doc] ; close in-core doc sd ic e [temp_incore] re