JFreeCharts is the way I have done this previously. It hasn't been updated in a while, but should still work. https://appstore.home.mendix.com/link/app/3011/TimeSeries/JFree-Charts-(.png-images)
why dont you use the print pdf screen, and making report as a mendix form and using chart widget
chart: https://appstore.home.mendix.com/link/app/105695/
print pdf: https://appstore.home.mendix.com/link/app/27069/