-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
46 analysis tool visuals #54
Conversation
I fixed some small problems with your PR, you probably mistakenly had a submodule to the tts-be, the constants weren't declared using the regular Python way (all caps at the beginning of the file), you didn't include a valid example for the statistics, and I just added a folder so that the graphs would be saved in a specific place. Further from that the script worked as accordingly, gj! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed folder system: separated cache from statistics examples
Why was this necessary
To create a more effective and appealing visualization of the JSON output generated by the different courses usage of TTS tool.
How was it done
The statistics api is fetched and kept in variable
stats
, then matplotlib functions are used in the created python functionpie_chart
,bar_chart
,line_chart
, to create visually appealing and readable charts that represent the key (course_name):value(usage) pair effectively.After being generated, the chart figures are saved in the
./django/university
directory. PS: the images reference were added to.gitignore
.How was it tested
This was tested in two ways, the 1st one by retrieving the stats information directly from the endpoint
https://ni.fe.up.pt/tts/api/statistics/
and the 2nd by way of previously generated JSON files during the beginning of the UP’s Second Semester (usually one of the peak seasons in terms of TTS usage). In both of those cases the program ran successfullyand the charts were well built.