Jump to content
Server Maintenance This Week. ×

Simple Pie Chart Problem


adyf

This topic is 4250 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Suppose field A is a calculation field that has a value of 4, and field B is a calculation field that has a value of 1, should I expect a pie chart that shows these two values to show A = 80% and B = 20%? If so, I'm not. The chart is formatted to show data from current record (delimited) as the chart is on a layout that is set to form view. I'm not sure whether the chart works out the percentages automatically or I need to define calculation fields to do this. Thanks in advance.

Link to comment
Share on other sites

Thanks Comment. The reason why it was failing is below. I had both fields as entries in the values, didn't realise they needed to be combined by calcaulation even though the label data is done that way. Leads me to ask why you can add multiple value data and only one label?

ChartIssue.jpg

A little issue I've noticed is that when I use the 'Select Year' pop up menu to choose the year, the chart doesn't refresh even though the values that the chart is based on change straight away. Do I somehow need to trigger a script to refresh window (Train Driving Instances table) and flush cache join results? I've uploaded my file.

Management Staff - Train Driving.zip

Link to comment
Share on other sites

why you can add multiple value data and only one label?

That's not an an accurate observation. The labels data calculation returns two return-delimited values - and so does the values data calculation.

I use the 'Select Year' pop up menu to choose the year, the chart doesn't refresh

I guess it's because the chart doesn't "know" it depends on the YearID field. Try changing the values data calculation to =


Let ( 

trigger = Management Staff::YearID

;

Management Staff::Driving Instances Required & ¶ &  Management Staff::Total Driving Instances

)

Link to comment
Share on other sites

That's not an an accurate observation. The labels data calculation returns two return-delimited values - and so does the values data calculation.

Could you add some more instances of value data to your original attached file to show me please?

Link to comment
Share on other sites


Let (

trigger = Management Staff::YearID

;

Management Staff::Driving Instances Required & ¶ & Management Staff::Total Driving Instances

)

Worked a treat, thank you. Would this be a custom function? How does it work?

Do you mean like this?

I didn't quite mean that. In the value data window, you can use the + button to add more entries to the window. I just wondered when you would have multiple entries.

Link to comment
Share on other sites

Would this be a custom function? How does it work?

No, it works by referencing the YearID field - thus forcing a redraw when the field is modified.

In the value data window, you can use the + button to add more entries to the window. I just wondered when you would have multiple entries.

With a pie chart, never.

Link to comment
Share on other sites

No, it works by referencing the YearID field - thus forcing a redraw when the field is modified.

With a pie chart, never.

What type of chart then?

Link to comment
Share on other sites

Any type that supports multiple series (in version 11, this means any type except pie chart). See the attached example.

Thanks for the explanation :smile:

Link to comment
Share on other sites

I've been playing with your series example again. I guess series means multiple values in the same field seperated by a carriage return? If I remove all the values but one then the lines on the chart disappear. Therefore can the line chart only be used with series data?

Link to comment
Share on other sites

I guess series means multiple values in the same field seperated by a carriage return?

Series means multiple values that describe one line in a line chart. A line chart can have multiple lines, and each series describes one line.

A series can be return-delimited values, or values of the found set or the related set - as defined in the chart setup.

Link to comment
Share on other sites

Series means multiple values that describe one line in a line chart. A line chart can have multiple lines, and each series describes one line.

A series can be return-delimited values, or values of the found set or the related set - as defined in the chart setup.

Current record, with one value in one field wont be series will it?

In your example, using one field to store multiple values wouldn't be regarded as standard good database practice would it? In theory would you obtain this by using the List function across the required set of records?

Link to comment
Share on other sites

Current record, with one value in one field wont be series will it?

Well, one value can only describe a point, not a line.

using one field to store multiple values wouldn't be regarded as standard good database practice would it?

It depends.

In theory would you obtain this by using the List function across the required set of records?

The List() function will only work across a related set of records - and the same effect can be achieved by pointing the chart to the related set directly. But if you wanted, for example, to chart the related set against a set of return-delimited values, then List() could be a good choice.

Link to comment
Share on other sites

Well, one value can only describe a point, not a line.

cPlanned Occurrences and cActual Occurrences are both summary fields based on a count. Two values to give a line but both in seperate fields, should this work on a line chart?

Link to comment
Share on other sites

This topic is 4250 days old. Please don't post here. Open a new topic instead.

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
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.