The dayOfYear() method returns the day of year for the specified date.
DayPilot.Date.dayOfYear();
A number specifying the day of year. January 1 returns 1.
var dayOfYear = new DayPilot.Date("2020-01-04").dayOfYear(); // 4