jimitpatel / electricsleep

Automatically exported from code.google.com/p/electricsleep
Other
0 stars 0 forks source link

feature: zoom on data graph #28

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
Is it possible to make a zoom function on the graphs? because sometimes when i 
sleep for over 12 hours it's hard to see the smaller differences.

Original issue reported on code.google.com by cras...@gmail.com on 6 Dec 2010 at 2:03

GoogleCodeExporter commented 8 years ago
When you save sleep, a smoothing procedure is run over the sleep data. In 
0.4.0, this means that either a sleep graph will have exactly 200 points of 
data, or it will not be saved at all. Therefore, whether you slept for an hour, 
6 hours, or 10 days, the end result would look roughly the same (for comparison 
purposes.)

I originally had zooming enabled, but removed it because I didn't think it was 
useful or necessary.

Original comment by jondwil...@gmail.com on 6 Dec 2010 at 4:20

GoogleCodeExporter commented 8 years ago
[deleted comment]
GoogleCodeExporter commented 8 years ago
I am also interested in zooming into various periods of recorded data.  Is 
smoothing necessary?  I'd rather have the raw data available instead of only 
200 "smoothed" points.
Perhaps this could be a selectable opinion?

Original comment by pegbat...@gmail.com on 6 Dec 2010 at 9:22

GoogleCodeExporter commented 8 years ago
This would help in analysis..am I always almost waking up at the same time in 
the middle of the night?  If the data is smoothed that kind of fidelity will be 
lost.

Original comment by pegbat...@gmail.com on 6 Dec 2010 at 9:24

GoogleCodeExporter commented 8 years ago
The data is smoothed, but not without discretion. For instance, if you move and 
the movement is >= the alarm sensitivity, that value will be kept. Otherwise, 
the non-maximum values are run through a moving average filter.

In short, I reduce the number of points for readability and to prevent 
excessive lag when reviewing sleep. 

~12 points of data are collected every minute, throughout a night that can last 
up to about half a day. Your android device doesn't have enough pixels to 
display that amount of data. I'll re-experiment with not smoothing the data, 
but I don't know if it will make it into a public release.

Original comment by jondwil...@gmail.com on 7 Dec 2010 at 3:16

GoogleCodeExporter commented 8 years ago

Original comment by jondwil...@gmail.com on 7 Dec 2010 at 3:24

GoogleCodeExporter commented 8 years ago
I can understand s smoothing for display purposes  because of the limiration in 
pixels.   The zoom function, though, would allow zooming in to greater fidelity 
in the areas of interest.  Keep all the data and smooth when displaying.  Like 
zooming into a google map.

Original comment by pegbat...@gmail.com on 7 Dec 2010 at 11:52

GoogleCodeExporter commented 8 years ago
I've played around with zooming. It is messy. The only way I can see myself 
implementing it will be something like pegbates5 recommended.

On the plus side, the updated charting library I use now has full support for 
zooming/panning.

Original comment by jondwil...@gmail.com on 13 Jan 2011 at 1:57