What are some best practices for labeling and annotating graphs in PHP, particularly when displaying data per month?

When displaying data per month on a graph in PHP, it is important to label and annotate the x-axis with the corresponding month names. One way to achieve this is by using the `DateTime` class to generate a list of month names for the x-axis labels. This can be done by iterating over the months and formatting them accordingly.

// Generate month labels for x-axis
$months = [];
for ($i = 1; $i <= 12; $i++) {
    $month = DateTime::createFromFormat('!m', $i);
    $months[] = $month->format('F');
}

// Use the generated month labels in your graph
// Example: assuming $data is an array of data points
// and $months is the array of month names
// $chart->setXAxisLabels($months);