I have a Col Series chart which has a separation per month. For each month there are three bars displaying different numbers.
What I want is to have, for each month, a line that shows the sum of the three numbers. But I cannot find a way to display the sum as a line. Is it possible to display both bars and lines in the same chart?
As an extra question, how to do a comparison with the previous month? I can create a virtual column to calculate the current month based on the existing data, but I don’t know how to do (currentMonth - pastMonth)
A mixed chart, incorporating both bar and line elements, may be developed using quickchart.ioNo-Code Chart Maker tool. For your reference, a comprehensive list of compatible data integrations is available here: Integrations.
For detailed technical guidance on implementing this tool within your application, please refer to the following documentation: Using QuickChart in AppSheet
For this , you may wish to share your table structure of relavant columns.
For example, is there one row in the table per month or multiple rows. And how you are currently adding the per month rows for a total. We presume there will be a date or date time column by default for each row
Using multi row expressions such as a SELECT() or FILTER() in a VC is not a very good idea in Appsheet as it can impact the app’s sync time.
Thank you.
Is the month column a pure text column manually entered or created from date type column using TEXT() functions.
Also what should be shown in the month of January, because previous months will roll over to the previous year’s December. How the table segregates or identifies between month values of different years?
Based on your response to the above questions, we could opine if and how best an economical expression can be created for your requirement.
Create a column called say [Difference_Previous_Month] of decimal type.
The solution assumes it is an update only table with fixed number of rows , basically one row for each month as you mentioned below
The solution also assumes you have a monthly total column called something like [Monthly_total] of decimal type that adds values Value1, Value2 and Value3
Please create a reference action on the table and make that action as an event save action on form save.
The reference rows expression of the main action will be
The condition for this action will be [Month]<>“Jan” . This will ensure the action does not run for the month “Jan” because there is no previous month to compare.
The referenced action that sets the [Difference_Previous_Month] will be of type “Data: Set the values of some columns in this row”. The expression for this action will be something like
So, whenever a value in any month is changed, the reference action sets the value of the [Difference_Previous_Month] by subtracting current monthly total with the previous one.