Josh Miller
For this week, a part of my job was to continue my work on the app's data visuals. Last week, I had added multiple new graphs across several activities and fragments, but they were lacking an important feature: a user-selectable date range.
In order to add this, I first had to add the element to the app's interface. I did this by adding a spinner with date ranges to the xml files for each activity that required one. This, however, was the easier part. Next, I had to interpret what choice the user selected and convert it to an actual set of Java Date objects. This was done by using another Java datatype to subtract a predetermined amount of time from the current date to create a second object.
Next, I extracted the number of milliseconds from both dates in order to create a linear scale to use along the x-axis, and set the minimum and maximum values of the axis to the new date values.