1) Use the latest LM2 form Sourceforge.
2) Assuming we have the Linkage file already done the pipeline the creates the maps for the chromosomes is:
2a) java -cp /bin/ Filtering data=data.linkage >data_f.linkage #default dataTolerance is 0.01
2b) java -cp /bin/ SeparateChromosomes data=data_f.linkage lodLimit=20 sizeLimit=10 >map.txt
2c) java -cp /bin/ JoinSingles map.txt lodLimit=10 data=data_f.linkage >map_js.txt
then we create the order for each chromosome by:
2d) for male and female recombination:
java -cp /bin/ OrderMarkers data=data_f.linkage map=map_js.txt alpha=0.1 polishWindow=100 filterWindow=10 chromosome=1 >chr1.MF.txt
2e) for sex averaged recombination
java -cp /bin/ OrderMarkers data=data_f.linkage alpha=0.1 evaluateOrder=chr1.MF.txt sexAveraged=1 improveOrder=0 >chr1.SA.txt
(the same for all the chromosomes, changing the chromosome=X option).
So far, so good. Now important debugging stuff.
3) Debugging.
3a) If a LG does not show any recombination in the male or the female one can run JoinSingle again:
java -cp /bin/ JoinSingles map_js.txt lodLimit=10 data=data_f.linkage >map_js2.txt
java -cp /bin/ JoinSingles map_js2.txt lodLimit=10 data=data_f.linkage >map_js3.txt
... (as long as you want or until the result does not change)
Then use map..._jsX.txt for Ordering step. Alternatively you can change the value for lodLimit in step (2b): java -cp /bin/ SeparateChromosomes data=data_f.linkage lodLimit=30 sizeLimit=10 >map.txt (now the LOD limit is 30 not 20).
3b) if this kind of situation appears:
#java OrderMarkers data=data_f.linkage map=map_js.txt alpha=0.1 polishWindow=100 filterWindow=10 chromosome=20
#*** LG = 20 likelihood = -882.5463 with alpha penalty = -921.9463
#marker_number male_position female_position ( error_estimate )[ duplicate*]
33865 0.00 0.00 ( 0 )
11057 0.00 1.10 ( 0.0065 )
25019 0.00 2.20 ( 0.0065 )
...
...
...
*** LG = 20.1
16935 0.00 0.00 ( 0.0715 )
17625 1.48 0.00 ( 0.0002 )
10433 3.51 0.00 ( 0 )
it is because recombination rate becomes 0.5 (or very close) so the map distance becomes inf. Typically there are only a few markers in the short gap that could be removed. One can run the OrderMarkers a few times and not all solutions will have these gaps. One can compare the difference in likelihood of removing markers vs. putting then in the middle of the map (with likely high error estimates).