Display total events in the header

How can I display a sum of values of cells in the folder content?
For example, take a look at the picture below -

If you take a look at the second column, I wish to display a sum of all the values from the folder content.
Please let me know how can I do this.

Currently, this is how I format the timeline date scale, will I have to add something here? How can I load a similar marker from below and display that above “First Shift” or “Second Shift”

        scheduler.templates.timeline_scale_date = function(date){
        if (date.getHours()== 0)
            return "First Shift"

        return "Second Shift"
    }

Hello @krushika29,

You should use getEvents method to calculate events sum that occur during the specified period
https://docs.dhtmlx.com/scheduler/api__scheduler_getevents.html

Here is a simple example that demonstrates hot to display the sum on the X-scale:
http://snippet.dhtmlx.com/216dc0174

Worked, thank you !!