The values displayed on the y-axis are are mix of float and int. The chart
displays int values on the y-axis if I use only one cfchartseries tag. The code
below calculates the value for the gridlines and scaleto attributes.
[code]
<cfset scTo=evaluate(ArrayMax(ListToArray(valuelist(qJobsLogged.JOBSCOUNT)))+1)>
[/code]
When I output this variable, the value returned is 88 and when I execute the
below code I get the following on the y-axis:
6 ,18, 30, 42, 54, 66, 78
[code]
<cfchart show3d="yes" gridlines="#evaluate(scTo+1)#" yaxistype="scale"
labelformat="number" scalefrom="0" scaleto="#scTo#" format="jpg"
xAxisTitle="log date" yAxisTitle="jobs logged" chartheight="300"
chartwidth="450" sortxaxis="no" showborder="yes"
showxgridlines="yes" showygridlines="yes" seriesplacement="stacked"
font="Arial" fontsize="12" fontbold="yes">
<cfchartseries type="bar" serieslabel="Critical" query="qJobsLogged"
itemcolumn="DTLOGGED" valuecolumn="JOBSCOUNT">
<cfif qJobsLogged.jobPriority eq 1>
<cfchartdata item="#qJobsLogged.DTLOGGED#"
value="#qJobsLogged.JOBCOUNT#">
</cfif>
</cfchartseries>
</cfchart>
[/code]
However, when I add 3 more chartseries tag to the above code, I get
27.7, 83, 138.4, 193.8, 249.1, 304.5
[code]
<cfset scTo=evaluate(ArrayMax(ListToArray(valuelist(qJobsLogged.JOBCOUNT)))+1)>
<cfchart show3d="yes" gridlines="#evaluate(scTo+1)#" yaxistype="scale"
labelformat="number" scalefrom="0" scaleto="#scTo#" format="jpg"
xAxisTitle="log date" yAxisTitle="jobs logged" chartheight="300"
chartwidth="450" sortxaxis="no" showborder="yes"
showxgridlines="yes" showygridlines="yes" seriesplacement="stacked"
font="Arial" fontsize="12" fontbold="yes">
<cfchartseries type="bar" serieslabel="Critical" query="qJobsLogged"
itemcolumn="DTLOGGED" valuecolumn="JOBSCOUNT">
<cfif qJobsLogged.jobPriority eq 1>
<cfchartdata item="#qJobsLogged.DTLOGGED#"
value="#qJobsLogged.JOBCOUNT#">
</cfif>
</cfchartseries>
<cfchartseries type="bar" serieslabel="Urgent" query="qJobsLogged"
itemcolumn="DTLOGGED" valuecolumn="JOBCOUNT">
<cfif qJobsLogged.jobPriority eq 2>
<cfchartdata item="#qJobsLogged.DTLOGGED#"
value="#qJobsLogged.JOBCOUNT#">
</cfif>
</cfchartseries>
<cfchartseries type="bar" serieslabel="Normal" query="qJobsLogged"
itemcolumn="DTLOGGED" valuecolumn="JOBCOUNT">
<cfif qJobsLogged.jobPriority eq 3>
<cfchartdata item="#qJobsLogged.DTLOGGED#"
value="#qJobsLogged.JOBCOUNT#">
</cfif>
</cfchartseries>
<cfchartseries type="bar" serieslabel="Other" query="qJobsLogged"
itemcolumn="DTLOGGED" valuecolumn="JOBCOUNT">
<cfif qJobsLogged.jobPriority gt 3>
<cfchartdata item="#qJobsLogged.DTLOGGED#"
value="#qJobsLogged.JOBCOUNT#">
</cfif>
</cfchartseries>
</cfchart>
[/code]
Can any mathematician help please
Regards
cfcoder
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Logware (www.logware.us): a new and convenient web-based time tracking
application. Start tracking and documenting hours spent on a project or with a
client with Logware today. Try it for free with a 15 day trial account.
http://www.houseoffusion.com/banners/view.cfm?bannerid=67
Message: http://www.houseoffusion.com/lists.cfm/link=i:4:198820
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54