<?xml version="1.0" encoding="ASCII" standalone="yes"?>
<!-- phaser_mr report template -->
<report xmlns:xrt="http://www.ccp4.ac.uk/xrt">

<xrt:results>

<xrt:ifnot select="//solutionsFound">
<text>Phaser failed to find any solutions.</text>
</xrt:ifnot>

<xrt:if select="//solutionsFound">

<p><b><text>There were </text>
<xrt:text select="//numSolutions"/>
<text>solutions found in spacegroup: </text>
<xrt:text select="//spaceGroup"/></b></p>

<p><b><text>Target contains </text>
<xrt:text select="//Target/TotalComps"/>
<text>components of </text>
<xrt:text select="//Target/CompTypes"/>
<text>type(s).</text></b></p>

<xrt:loop select="//Solutions/Solution">

<p><text>Solution</text>
<xrt:text select="ISOL"/>
<text>has</text>
<xrt:text select="NCOMPONENTS"/>
<text>components located.</text></p>

<xrt:table select="Component">
<xrt:data title="Rot Func Z-score" select="RFZ" />
<xrt:data title="Trans Func Z-score" select="TFZ" />
<xrt:data title="Packing clashes" select="PAK" />
<xrt:data title="Log likelihood gain" select="LLG" />
<xrt:data title="Trans Func Z-score equivalent" select="refTFZ" />
</xrt:table>

<p><text>Final refined scores: Log likelihood gain = </text>
<xrt:text select="overallLLG"/>
<text>TFZ-equivalent = </text>
<xrt:text select="overallTFZ"/>
</p>

</xrt:loop>

<xrt:graph title="Solutions from Phaser" select="//Solutions/Solution">
<xrt:data title="Solution" select="ISOL" />
<xrt:data title="Components_found" select="NCOMPONENTS" />
<xrt:data title="Overall_LLG" select="overallLLG" />
<xrt:data title="Overall_TFZ" select="overallTFZ" />
<xrt:plot>
<title>Overall LLG</title>
<plottype>xy</plottype>
<plotline xcol="1" ycol="3" label="Overall LLG">
<colour>blue</colour>
</plotline>
</xrt:plot>
<xrt:plot>
<title>Overall TFZ-equivalent</title>
<plottype>xy</plottype>
<plotline xcol="1" ycol="4" label="Overall TFZ">
<colour>blue</colour>
</plotline>
</xrt:plot>
<xrt:plot>
<title>Number of components found</title>
<plottype>xy</plottype>
<plotline xcol="1" ycol="2" label="Components found">
<colour>blue</colour>
</plotline>
</xrt:plot>
</xrt:graph>

<xrt:picture label="Final structure" >
<xrt:insertXrt filename="$CCP4I2/tasks/phaser_mr/phaser_mr_1.scene.xml"/>
</xrt:picture>

</xrt:if>

</xrt:results>

</report>
