# Analysis of Data Sets and Graph Curves

This topic is 3167 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

## Recommended Posts

Hi all, haven't been around for a good while. I'm currently working on a small app for Weight & Diet Management. The users can insert their weight daily, along other things, their food intake, physical activities, heart beat rate in rest, gut measurement, BMI, TBW, bowel movements (to track people with serious fiber decencies or intestinal movement problems), stress level, amount of sleep, etc... I have 2 specific questions: 1) Can I run some sort of math equation over the Weight Graph to reach some time of conclusion regarding weight loss rate? If anyone has ever seen a graph of a person's weight taken daily, it's always going slightly up and down. I want to run some sort of math function over this data set to get the true "intention" of the weight curve. Is it going down, up, and at what rate? 2) Having determined that we are either gaining weight, or losing it, and having a lot of input data, as seen above, is there some sort of math function I can use to determine what has been most responsible for weight loss/gain in a certain week? In other words, on week 7 there was a good amount of weight loss of 1.8Kg. I have caloric intake per day, amount of physical exercise done in calories, sleep in hours, etc, can I run some sort of math function over these data sets to determine the biggest contributor to the weight loss? I guess I'm looking into some sort of math algorithms here. Thanks for any input on these issues, and suggestions on how can I can improve data analysis, to give the User more control over his regime. Thanks.

##### Share on other sites
Oh, I know of the website called FitDay that does something like this.

Quote:
 Original post by Prozak1) Can I run some sort of math equation over the Weight Graph to reach some time of conclusion regarding weight loss rate? If anyone has ever seen a graph of a person's weight taken daily, it's always going slightly up and down. I want to run some sort of math function over this data set to get the true "intention" of the weight curve. Is it going down, up, and at what rate?

I can think of three approaches, and I've seen them all being used:
i) Take the difference between the last value and the value a certain time before (2 weeks, perhaps).
ii) Smooth out the data by computing a moving average, or perhaps an exponential filter.
iii) Select a range of data points and fit a straight line to the data, minimizing the sum of squares of the differences.

Quote:
 2) Having determined that we are either gaining weight, or losing it, and having a lot of input data, as seen above, is there some sort of math function I can use to determine what has been most responsible for weight loss/gain in a certain week? In other words, on week 7 there was a good amount of weight loss of 1.8Kg. I have caloric intake per day, amount of physical exercise done in calories, sleep in hours, etc, can I run some sort of math function over these data sets to determine the biggest contributor to the weight loss?

If you have input from a lot of people, you can try to make a model for what your weight is going to be based on the other inputs. The model probably should be linear, or close to linear, so you'll be able to indicate the partial derivative of the weight with respect to each of the inputs. For instance, you could say that you would be 1oz slimmer if you had ran 4 miles more, or if you had eaten 400 Kcal less, etc.

In my experience and that of people around me, simple tools work best. In particular, I like a simple plot of weight over time. Drawing a line between where your weight is and where you want it to be, with a flat line after that is a very good motivator. Every week (or day, I guess) you make a new measurement and you see your progress. This gives the user pretty quick feedback to know if they are making good progress or not.

EDIT: Oh, also be aware that giving medical advice could be a liability. Someone could follow your advice, get diabetes and then sue you. This may not be a real concern in Portugal, but in the US I would be very careful. Gotta hate lawyers...

1. 1
2. 2
Rutin
18
3. 3
khawk
15
4. 4
A4L
14
5. 5

• 10
• 13
• 26
• 10
• 11
• ### Forum Statistics

• Total Topics
633745
• Total Posts
3013667
×