Sign in to follow this  
spmmohan123

How to draw trend line

Recommended Posts

Hi ,

 I am using scatter  chart.In my xml likes below:

<graph caption=""  formatNumberScale='0' adjustDiv='0'  canvasBgColor="FFFFFF" numDivLines="9" yAxisName="Reading" xAxisName="Date" rotateNames="0" showLegend="1" showNames="1" xAxisMaxValue="132" xAxisMinValue="11" yAxisMinValue="142" yAxisMaxValue="542" decimalPrecision="0">

<categories verticalLineColor="666666" verticalLineThickness="1"><category name="0" x="0" showVerticalLine="1" showToolTip = "1"/>

<category name="APR04" x="15" showVerticalLine="1"/>

<category name="OCT04" x="30" showVerticalLine="1"/>

<category name="APR05" x="45" showVerticalLine="1"/>

<category name="OCT05" x="60" showVerticalLine="1"/>

<category name="APR06" x="75" showVerticalLine="1"/>

<category name="OCT06" x="90" showVerticalLine="1"/>

<category name="APR07" x="105" showVerticalLine="1"/>

<category name="OCT07" x="120" showVerticalLine="1"/>

<category name="APR08" x="135" showVerticalLine="1"/></categories>

<dataSet seriesName="Valid" anchorSides="6" color="#0000FF" anchorRadius="6" anchorBgColor="#0000FF"  anchorBorderColor="#000000">

<set y="152"x="15.0"  tooltext= "08APR04 , 152"/><application> <apply toObject='TOOLTIP'/></application>

</dataSet><dataSet anchorSides="6" anchorRadius="6" anchorBgColor="#0000FF"  anchorBorderColor="#000000">

<set y="177"x="30.0"  tooltext= "11OCT04 , 177"/><application> <apply toObject='TOOLTIP'/></application>

</dataSet><dataSet anchorSides="6" anchorRadius="6" anchorBgColor="#0000FF"  anchorBorderColor="#000000">

<set y="198"x="45.0"  tooltext= "06APR05 , 198"/><application> <apply toObject='TOOLTIP'/></application>

</dataSet><dataSet anchorSides="6" anchorRadius="6" anchorBgColor="#0000FF"  anchorBorderColor="#000000">

<set y="216"x="60.0"  tooltext= "07OCT05 , 216"/><application> <apply toObject='TOOLTIP'/></application>

</dataSet><dataSet seriesName="Estimate" anchorSides="6" color="#C0C0C0" anchorRadius="6" anchorBgColor="#C0C0C0"  anchorBorderColor="#000000">

<set y="220"x="62.5"  tooltext= "13NOV05 , 220"/><application> <apply toObject='TOOLTIP'/></application>

</dataSet><dataSet anchorSides="6" anchorRadius="6" anchorBgColor="#0000FF"  anchorBorderColor="#000000">

<set y="241"x="75.0"  tooltext= "04APR06 , 241"/><application> <apply toObject='TOOLTIP'/></application>

</dataSet><dataSet anchorSides="6" anchorRadius="6" anchorBgColor="#0000FF"  anchorBorderColor="#000000">

<set y="288"x="90.0"  tooltext= "16OCT06 , 288"/><application> <apply toObject='TOOLTIP'/></application>

</dataSet><dataSet anchorSides="6" anchorRadius="6" anchorBgColor="#0000FF"  anchorBorderColor="#000000">

<set y="304"x="97.5"  tooltext= "10JAN07 , 304"/><application> <apply toObject='TOOLTIP'/></application>

</dataSet><dataSet anchorSides="6" anchorRadius="6" anchorBgColor="#0000FF"  anchorBorderColor="#000000">

<set y="304"x="105.0"  tooltext= "11APR07 , 304"/><application> <apply toObject='TOOLTIP'/></application>

</dataSet><dataSet seriesName="ToValidate" anchorSides="6" color="#FFFF00" anchorRadius="6" anchorBgColor="#FFFF00"  anchorBorderColor="#000000">

<set y="500"x="122.5"  tooltext= "26NOV07 , 500"/><application> <apply toObject='TOOLTIP'/></application>

</dataSet>

<vTrendlines>

<line startValue="0" endValue="36" alpha="5" color="00FF00" />

<line startValue="36" endValue="116" alpha="15" color="FFFF00" />

<line startValue="116" endValue="132" alpha="15" color="FF0000" />

</vTrendlines>

</graph>

What property needs to be add for dispaly the trend line  like attached doc red color trend line.

Pls refer the atached doc for your reference.

Thanks,

Mohan

sample graph.doc

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this