kpwhri / heartsteps

Heart Steps 2.0 Application
8 stars 1 forks source link

Participants unavailable for message randomization if more than 2,000 steps in 2 hours #74

Closed Sabina321 closed 5 years ago

Sabina321 commented 5 years ago

Request to update the definition of availability. This involves adding one condition to when people are un -available.

The current definitions are that people are unavailable if: 1) They have walked more than 150 steps in the last 40 minutes 2) A message was sent(received?) in the last hour

Now there will be this additional definition: 3) The user took more than 2000 steps in the last 2 hours.

nickdotreid commented 5 years ago

@Sabina321 This should be an easy change. Do you mind if I re-write the ticket a little?

We would be using the watch-app as the data source for this information, correct?

How should we handle times that we don't have "complete" data? By "complete," I mean we have less than 2 hours of step counts -- which could be caused by lack of connectivity, or not wearing the watch.

samurphy11 commented 5 years ago

Hi Nick, I am not sure how to respond to these github tickets so I included your email address on this response!

Yes, watch-app is source of data to determine availability:

NOT-Available if They have walked more than 150 steps in the last 40 minutes OR A message was sent in the last hour OR The user took more than 2000 steps in the last 2 hours.

You asked " How should we handle times that we don't have "complete" data? By "complete," I mean we have less than 2 hours of step counts -- which could be caused by lack of connectivity, or not wearing the watch"

I suggest to use the same procedure that is used to determine if the user has walked more than 150 steps in the last 40 min. Please remind me what this procedure is! Best Susan

On Wed, Jul 31, 2019 at 4:23 PM Nick Reid notifications@github.com wrote:

@Sabina321 https://github.com/Sabina321 This should be an easy change. Do you mind if I re-write the ticket a little?

We would be using the watch-app as the data source for this information, correct?

How should we handle times that we don't have "complete" data? By "complete," I mean we have less than 2 hours of step counts -- which could be caused by lack of connectivity, or not wearing the watch.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/kpwhri/heartsteps/issues/74?email_source=notifications&email_token=ADTRRQMM7CNK3LAMABYNLELQCHYCJA5CNFSM4IIKA3Q2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD3IOFAY#issuecomment-517005955, or mute the thread https://github.com/notifications/unsubscribe-auth/ADTRRQIC5VHISH7PZTCC5BTQCHYCJANCNFSM4IIKA3QQ .

--


Susan A. Murphy Professor of Statistics, Radcliffe Alumnae Professor at the Radcliffe Institute and Professor of Computer Science at the Harvard John A. Paulson School of Engineering and Applied Sciences Harvard University website: http://people.seas.harvard.edu/~samurphy/ http://people.seas.harvard.edu/~samurphy/


samurphy11 commented 5 years ago

HI All, Pedja please comment on the idea below: Answers to Nick''s questions:

Yes, watch-app is source of data to determine availability:

NOT-Available if They have walked more than 150 steps in the last 40 minutes OR A message was sent in the last hour OR The user took more than 2000 steps in the last 2 hours.

Nick asked " How should we handle times that we don't have "complete" data? By "complete," I mean we have less than 2 hours of step counts -- which could be caused by lack of connectivity, or not wearing the watch" My understanding is that every 5 min. google app engine server checks last 40 min of fitbit step (impute 0 at all minutes with no data) on cloud. I suggest to use these same imputations of 0 for no data.

Pedja this will cause problems if person is not wearing watch in last 2 hours as then the user will definitely have less than 2000 steps.

We can change availability to include whether person is wearing the watch but this is your call. I think too complicated with too many chances for software bugs..... susan

On Thu, Aug 1, 2019 at 8:46 AM susan murphy samurphy11@gmail.com wrote:

Hi Nick, I am not sure how to respond to these github tickets so I included your email address on this response!

Yes, watch-app is source of data to determine availability:

NOT-Available if They have walked more than 150 steps in the last 40 minutes OR A message was sent in the last hour OR The user took more than 2000 steps in the last 2 hours.

You asked " How should we handle times that we don't have "complete" data? By "complete," I mean we have less than 2 hours of step counts -- which could be caused by lack of connectivity, or not wearing the watch"

I suggest to use the same procedure that is used to determine if the user has walked more than 150 steps in the last 40 min. Please remind me what this procedure is! Best Susan

On Wed, Jul 31, 2019 at 4:23 PM Nick Reid notifications@github.com wrote:

@Sabina321 https://github.com/Sabina321 This should be an easy change. Do you mind if I re-write the ticket a little?

We would be using the watch-app as the data source for this information, correct?

How should we handle times that we don't have "complete" data? By "complete," I mean we have less than 2 hours of step counts -- which could be caused by lack of connectivity, or not wearing the watch.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/kpwhri/heartsteps/issues/74?email_source=notifications&email_token=ADTRRQMM7CNK3LAMABYNLELQCHYCJA5CNFSM4IIKA3Q2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD3IOFAY#issuecomment-517005955, or mute the thread https://github.com/notifications/unsubscribe-auth/ADTRRQIC5VHISH7PZTCC5BTQCHYCJANCNFSM4IIKA3QQ .

--


Susan A. Murphy Professor of Statistics, Radcliffe Alumnae Professor at the Radcliffe Institute and Professor of Computer Science at the Harvard John A. Paulson School of Engineering and Applied Sciences Harvard University website: http://people.seas.harvard.edu/~samurphy/ http://people.seas.harvard.edu/~samurphy/


--


Susan A. Murphy Professor of Statistics, Radcliffe Alumnae Professor at the Radcliffe Institute and Professor of Computer Science at the Harvard John A. Paulson School of Engineering and Applied Sciences Harvard University website: http://people.seas.harvard.edu/~samurphy/ http://people.seas.harvard.edu/~samurphy/


nickdotreid commented 5 years ago

Currently, it doesn't seem that we check if step count data for a time range is complete or contiguous.

For example: If you took 20 steps, then took off you watch for 30 minutes and ran a marathon, and finally put your watch back on and took another 20 steps -- HeartSteps would call you sedentary.

Question for the group: What is the intention behind adding this availability check?

-- nick --

On Thu, Aug 1, 2019 at 8:31 AM Susan A Murphy notifications@github.com wrote:

HI All, Pedja please comment on the idea below: Answers to Nick''s questions:

Yes, watch-app is source of data to determine availability:

NOT-Available if They have walked more than 150 steps in the last 40 minutes OR A message was sent in the last hour OR The user took more than 2000 steps in the last 2 hours.

Nick asked " How should we handle times that we don't have "complete" data? By "complete," I mean we have less than 2 hours of step counts -- which could be caused by lack of connectivity, or not wearing the watch" My understanding is that every 5 min. google app engine server checks last 40 min of fitbit step (impute 0 at all minutes with no data) on cloud. I suggest to use these same imputations of 0 for no data.

Pedja this will cause problems if person is not wearing watch in last 2 hours as then the user will definitely have less than 2000 steps.

We can change availability to include whether person is wearing the watch but this is your call. I think too complicated with too many chances for software bugs..... susan

On Thu, Aug 1, 2019 at 8:46 AM susan murphy samurphy11@gmail.com wrote:

Hi Nick, I am not sure how to respond to these github tickets so I included your email address on this response!

Yes, watch-app is source of data to determine availability:

NOT-Available if They have walked more than 150 steps in the last 40 minutes OR A message was sent in the last hour OR The user took more than 2000 steps in the last 2 hours.

You asked " How should we handle times that we don't have "complete" data? By "complete," I mean we have less than 2 hours of step counts -- which could be caused by lack of connectivity, or not wearing the watch"

I suggest to use the same procedure that is used to determine if the user has walked more than 150 steps in the last 40 min. Please remind me what this procedure is! Best Susan

On Wed, Jul 31, 2019 at 4:23 PM Nick Reid notifications@github.com wrote:

@Sabina321 https://github.com/Sabina321 This should be an easy change. Do you mind if I re-write the ticket a little?

We would be using the watch-app as the data source for this information, correct?

How should we handle times that we don't have "complete" data? By "complete," I mean we have less than 2 hours of step counts -- which could be caused by lack of connectivity, or not wearing the watch.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub < https://github.com/kpwhri/heartsteps/issues/74?email_source=notifications&email_token=ADTRRQMM7CNK3LAMABYNLELQCHYCJA5CNFSM4IIKA3Q2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD3IOFAY#issuecomment-517005955 , or mute the thread < https://github.com/notifications/unsubscribe-auth/ADTRRQIC5VHISH7PZTCC5BTQCHYCJANCNFSM4IIKA3QQ

.

--


Susan A. Murphy Professor of Statistics, Radcliffe Alumnae Professor at the Radcliffe Institute and Professor of Computer Science at the Harvard John A. Paulson School of Engineering and Applied Sciences Harvard University website: http://people.seas.harvard.edu/~samurphy/ http://people.seas.harvard.edu/~samurphy/


--


Susan A. Murphy Professor of Statistics, Radcliffe Alumnae Professor at the Radcliffe Institute and Professor of Computer Science at the Harvard John A. Paulson School of Engineering and Applied Sciences Harvard University website: http://people.seas.harvard.edu/~samurphy/ http://people.seas.harvard.edu/~samurphy/


— You are receiving this because you were assigned. Reply to this email directly, view it on GitHub https://github.com/kpwhri/heartsteps/issues/74?email_source=notifications&email_token=AAFBJ675CNHP2LOR7EERORLQCL6U5A5CNFSM4IIKA3Q2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD3K7J4Y#issuecomment-517338355, or mute the thread https://github.com/notifications/unsubscribe-auth/AAFBJ67QSLPG65ZCYZVPUVTQCL6U5ANCNFSM4IIKA3QQ .

klasnja commented 5 years ago

Hi all,

My take on this is that if we don’t have enough data to determine the step count for the prior two-hour period, but we do have a valid decision point (i.e., the person is wearing the watch right now), we should consider the person available on the 2-hour criterion and determine availability with the remaining rules (i.e., the ones that are currently implemented). The key issue is what we would mean by “enough data.” Basically, I was thinking of a pretty simple rule here:

Does this make sense?

Thanks, Pedja

On August 1, 2019 at 8:31:31 AM, Susan A Murphy (notifications@github.com) wrote:

HI All, Pedja please comment on the idea below: Answers to Nick''s questions:

Yes, watch-app is source of data to determine availability:

NOT-Available if They have walked more than 150 steps in the last 40 minutes OR A message was sent in the last hour OR The user took more than 2000 steps in the last 2 hours.

Nick asked " How should we handle times that we don't have "complete" data? By "complete," I mean we have less than 2 hours of step counts -- which could be caused by lack of connectivity, or not wearing the watch" My understanding is that every 5 min. google app engine server checks last 40 min of fitbit step (impute 0 at all minutes with no data) on cloud. I suggest to use these same imputations of 0 for no data.

Pedja this will cause problems if person is not wearing watch in last 2 hours as then the user will definitely have less than 2000 steps.

We can change availability to include whether person is wearing the watch but this is your call. I think too complicated with too many chances for software bugs..... susan

On Thu, Aug 1, 2019 at 8:46 AM susan murphy samurphy11@gmail.com wrote:

Hi Nick, I am not sure how to respond to these github tickets so I included your email address on this response!

Yes, watch-app is source of data to determine availability:

NOT-Available if They have walked more than 150 steps in the last 40 minutes OR A message was sent in the last hour OR The user took more than 2000 steps in the last 2 hours.

You asked " How should we handle times that we don't have "complete" data? By "complete," I mean we have less than 2 hours of step counts -- which could be caused by lack of connectivity, or not wearing the watch"

I suggest to use the same procedure that is used to determine if the user has walked more than 150 steps in the last 40 min. Please remind me what this procedure is! Best Susan

On Wed, Jul 31, 2019 at 4:23 PM Nick Reid notifications@github.com wrote:

@Sabina321 https://github.com/Sabina321 This should be an easy change. Do you mind if I re-write the ticket a little?

We would be using the watch-app as the data source for this information, correct?

How should we handle times that we don't have "complete" data? By "complete," I mean we have less than 2 hours of step counts -- which could be caused by lack of connectivity, or not wearing the watch.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub < https://github.com/kpwhri/heartsteps/issues/74?email_source=notifications&email_token=ADTRRQMM7CNK3LAMABYNLELQCHYCJA5CNFSM4IIKA3Q2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD3IOFAY#issuecomment-517005955 , or mute the thread < https://github.com/notifications/unsubscribe-auth/ADTRRQIC5VHISH7PZTCC5BTQCHYCJANCNFSM4IIKA3QQ

.

--


Susan A. Murphy Professor of Statistics, Radcliffe Alumnae Professor at the Radcliffe Institute and Professor of Computer Science at the Harvard John A. Paulson School of Engineering and Applied Sciences Harvard University website: http://people.seas.harvard.edu/~samurphy/ http://people.seas.harvard.edu/~samurphy/


--


Susan A. Murphy Professor of Statistics, Radcliffe Alumnae Professor at the Radcliffe Institute and Professor of Computer Science at the Harvard John A. Paulson School of Engineering and Applied Sciences Harvard University website: http://people.seas.harvard.edu/~samurphy/ http://people.seas.harvard.edu/~samurphy/


— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/kpwhri/heartsteps/issues/74?email_source=notifications&email_token=ADTZF7PXGXVSNT2CRJQJVCTQCL6U5A5CNFSM4IIKA3Q2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD3K7J4Y#issuecomment-517338355, or mute the thread https://github.com/notifications/unsubscribe-auth/ADTZF7LNWIED5ASZBATYR5TQCL6U5ANCNFSM4IIKA3QQ .

nickdotreid commented 5 years ago

Nick,

What we noticed—particularly in my data—is that after longer periods of activity (e.g., a two or three-hour bike ride), HeartSteps is very likely to send an anti-sedentary message as soon as the 40 minutes of inactivity is reached. This produces a pretty crappy experience. You just did a bunch of activity, and soon after you stop you get a “Been sitting for too long?” message. So, this new criterion is supposed to address those situations, so we don’t bother people too soon after they stopped exercising.

On August 1, 2019 at 9:46:45 AM, Nick Reid (nickreid@gmail.com) wrote:

Currently, it doesn't seem that we check if step count data for a time range is complete or contiguous.

For example: If you took 20 steps, then took off you watch for 30 minutes and ran a marathon, and finally put your watch back on and took another 20 steps -- HeartSteps would call you sedentary.

Question for the group: What is the intention behind adding this availability check?

-- nick --

On Thu, Aug 1, 2019 at 8:31 AM Susan A Murphy notifications@github.com wrote:

HI All, Pedja please comment on the idea below: Answers to Nick''s questions:

Yes, watch-app is source of data to determine availability:

NOT-Available if They have walked more than 150 steps in the last 40 minutes OR A message was sent in the last hour OR The user took more than 2000 steps in the last 2 hours.

Nick asked " How should we handle times that we don't have "complete" data? By "complete," I mean we have less than 2 hours of step counts -- which could be caused by lack of connectivity, or not wearing the watch" My understanding is that every 5 min. google app engine server checks last 40 min of fitbit step (impute 0 at all minutes with no data) on cloud. I suggest to use these same imputations of 0 for no data.

Pedja this will cause problems if person is not wearing watch in last 2 hours as then the user will definitely have less than 2000 steps.

We can change availability to include whether person is wearing the watch but this is your call. I think too complicated with too many chances for software bugs..... susan

On Thu, Aug 1, 2019 at 8:46 AM susan murphy samurphy11@gmail.com wrote:

Hi Nick, I am not sure how to respond to these github tickets so I included your email address on this response!

Yes, watch-app is source of data to determine availability:

NOT-Available if They have walked more than 150 steps in the last 40 minutes OR A message was sent in the last hour OR The user took more than 2000 steps in the last 2 hours.

You asked " How should we handle times that we don't have "complete" data? By "complete," I mean we have less than 2 hours of step counts -- which could be caused by lack of connectivity, or not wearing the watch"

I suggest to use the same procedure that is used to determine if the user has walked more than 150 steps in the last 40 min. Please remind me what this procedure is! Best Susan

On Wed, Jul 31, 2019 at 4:23 PM Nick Reid notifications@github.com wrote:

@Sabina321 https://github.com/Sabina321 This should be an easy change. Do you mind if I re-write the ticket a little?

We would be using the watch-app as the data source for this information, correct?

How should we handle times that we don't have "complete" data? By "complete," I mean we have less than 2 hours of step counts -- which could be caused by lack of connectivity, or not wearing the watch.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub < https://github.com/kpwhri/heartsteps/issues/74?email_source=notifications&email_token=ADTRRQMM7CNK3LAMABYNLELQCHYCJA5CNFSM4IIKA3Q2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD3IOFAY#issuecomment-517005955 , or mute the thread < https://github.com/notifications/unsubscribe-auth/ADTRRQIC5VHISH7PZTCC5BTQCHYCJANCNFSM4IIKA3QQ

.

--


Susan A. Murphy Professor of Statistics, Radcliffe Alumnae Professor at the Radcliffe Institute and Professor of Computer Science at the Harvard John A. Paulson School of Engineering and Applied Sciences Harvard University website: http://people.seas.harvard.edu/~samurphy/ http://people.seas.harvard.edu/~samurphy/


--


Susan A. Murphy Professor of Statistics, Radcliffe Alumnae Professor at the Radcliffe Institute and Professor of Computer Science at the Harvard John A. Paulson School of Engineering and Applied Sciences Harvard University website: http://people.seas.harvard.edu/~samurphy/ http://people.seas.harvard.edu/~samurphy/


— You are receiving this because you were assigned. Reply to this email directly, view it on GitHub https://github.com/kpwhri/heartsteps/issues/74?email_source=notifications&email_token=AAFBJ675CNHP2LOR7EERORLQCL6U5A5CNFSM4IIKA3Q2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD3K7J4Y#issuecomment-517338355, or mute the thread https://github.com/notifications/unsubscribe-auth/AAFBJ67QSLPG65ZCYZVPUVTQCL6U5ANCNFSM4IIKA3QQ .

nickdotreid commented 5 years ago

If we are trying to not send a message when a participant has recently completed an activity, wouldn't it make more sense to see if Fitbit has tracked any activities in the past 2 hours?

If there is a 40 minute window for Fitbit to update data, I'm pretty certain heartsteps will have an updated list of activities

On Thu, Aug 1, 2019 at 9:54 AM Predrag Klasnja klasnja@umich.edu wrote:

Nick,

What we noticed—particularly in my data—is that after longer periods of activity (e.g., a two or three-hour bike ride), HeartSteps is very likely to send an anti-sedentary message as soon as the 40 minutes of inactivity is reached. This produces a pretty crappy experience. You just did a bunch of activity, and soon after you stop you get a “Been sitting for too long?” message. So, this new criterion is supposed to address those situations, so we don’t bother people too soon after they stopped exercising.

On August 1, 2019 at 9:46:45 AM, Nick Reid (nickreid@gmail.com) wrote:

Currently, it doesn't seem that we check if step count data for a time range is complete or contiguous.

For example: If you took 20 steps, then took off you watch for 30 minutes and ran a marathon, and finally put your watch back on and took another 20 steps -- HeartSteps would call you sedentary.

Question for the group: What is the intention behind adding this availability check?

-- nick --

On Thu, Aug 1, 2019 at 8:31 AM Susan A Murphy notifications@github.com wrote:

HI All, Pedja please comment on the idea below: Answers to Nick''s questions:

Yes, watch-app is source of data to determine availability:

NOT-Available if They have walked more than 150 steps in the last 40 minutes OR A message was sent in the last hour OR The user took more than 2000 steps in the last 2 hours.

Nick asked " How should we handle times that we don't have "complete" data? By "complete," I mean we have less than 2 hours of step counts -- which could be caused by lack of connectivity, or not wearing the watch" My understanding is that every 5 min. google app engine server checks last 40 min of fitbit step (impute 0 at all minutes with no data) on cloud. I suggest to use these same imputations of 0 for no data.

Pedja this will cause problems if person is not wearing watch in last 2 hours as then the user will definitely have less than 2000 steps.

We can change availability to include whether person is wearing the watch but this is your call. I think too complicated with too many chances for software bugs..... susan

On Thu, Aug 1, 2019 at 8:46 AM susan murphy samurphy11@gmail.com wrote:

Hi Nick, I am not sure how to respond to these github tickets so I included your email address on this response!

Yes, watch-app is source of data to determine availability:

NOT-Available if They have walked more than 150 steps in the last 40 minutes OR A message was sent in the last hour OR The user took more than 2000 steps in the last 2 hours.

You asked " How should we handle times that we don't have "complete" data? By "complete," I mean we have less than 2 hours of step counts -- which could be caused by lack of connectivity, or not wearing the watch"

I suggest to use the same procedure that is used to determine if the user has walked more than 150 steps in the last 40 min. Please remind me what this procedure is! Best Susan

On Wed, Jul 31, 2019 at 4:23 PM Nick Reid notifications@github.com wrote:

@Sabina321 https://github.com/Sabina321 This should be an easy change. Do you mind if I re-write the ticket a little?

We would be using the watch-app as the data source for this information, correct?

How should we handle times that we don't have "complete" data? By "complete," I mean we have less than 2 hours of step counts -- which could be caused by lack of connectivity, or not wearing the watch.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub < https://github.com/kpwhri/heartsteps/issues/74?email_source=notifications&email_token=ADTRRQMM7CNK3LAMABYNLELQCHYCJA5CNFSM4IIKA3Q2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD3IOFAY#issuecomment-517005955 , or mute the thread < https://github.com/notifications/unsubscribe-auth/ADTRRQIC5VHISH7PZTCC5BTQCHYCJANCNFSM4IIKA3QQ

.

--


Susan A. Murphy Professor of Statistics, Radcliffe Alumnae Professor at the Radcliffe Institute and Professor of Computer Science at the Harvard John A. Paulson School of Engineering and Applied Sciences Harvard University website: http://people.seas.harvard.edu/~samurphy/ http://people.seas.harvard.edu/~samurphy/


--


Susan A. Murphy Professor of Statistics, Radcliffe Alumnae Professor at the Radcliffe Institute and Professor of Computer Science at the Harvard John A. Paulson School of Engineering and Applied Sciences Harvard University website: http://people.seas.harvard.edu/~samurphy/ http://people.seas.harvard.edu/~samurphy/


— You are receiving this because you were assigned. Reply to this email directly, view it on GitHub https://github.com/kpwhri/heartsteps/issues/74?email_source=notifications&email_token=AAFBJ675CNHP2LOR7EERORLQCL6U5A5CNFSM4IIKA3Q2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD3K7J4Y#issuecomment-517338355, or mute the thread https://github.com/notifications/unsubscribe-auth/AAFBJ67QSLPG65ZCYZVPUVTQCL6U5ANCNFSM4IIKA3QQ .

klasnja commented 5 years ago

I am not sure we need to not intervene if one just took, say, a 10 minute walk 2 hours ago. I am much more concerned about a substantial exercise bout. Which is why I tried to operationalized it this way. But if we could do something similar with Fitbit server data, I guess, but we would want to have a threshold of something like at least 20 active minutes in the last two hours. Would that be easier to implement?

On August 1, 2019 at 10:01:01 AM, Nick Reid (notifications@github.com) wrote:

If we are trying to not send a message when a participant has recently completed an activity, wouldn't it make more sense to see if Fitbit has tracked any activities in the past 2 hours?

If there is a 40 minute window for Fitbit to update data, I'm pretty certain heartsteps will have an updated list of activities

On Thu, Aug 1, 2019 at 9:54 AM Predrag Klasnja klasnja@umich.edu wrote:

Nick,

What we noticed—particularly in my data—is that after longer periods of activity (e.g., a two or three-hour bike ride), HeartSteps is very likely to send an anti-sedentary message as soon as the 40 minutes of inactivity is reached. This produces a pretty crappy experience. You just did a bunch of activity, and soon after you stop you get a “Been sitting for too long?” message. So, this new criterion is supposed to address those situations, so we don’t bother people too soon after they stopped exercising.

On August 1, 2019 at 9:46:45 AM, Nick Reid (nickreid@gmail.com) wrote:

Currently, it doesn't seem that we check if step count data for a time range is complete or contiguous.

For example: If you took 20 steps, then took off you watch for 30 minutes and ran a marathon, and finally put your watch back on and took another 20 steps -- HeartSteps would call you sedentary.

Question for the group: What is the intention behind adding this availability check?

-- nick --

On Thu, Aug 1, 2019 at 8:31 AM Susan A Murphy notifications@github.com wrote:

HI All, Pedja please comment on the idea below: Answers to Nick''s questions:

Yes, watch-app is source of data to determine availability:

NOT-Available if They have walked more than 150 steps in the last 40 minutes OR A message was sent in the last hour OR The user took more than 2000 steps in the last 2 hours.

Nick asked " How should we handle times that we don't have "complete" data? By "complete," I mean we have less than 2 hours of step counts -- which could be caused by lack of connectivity, or not wearing the watch" My understanding is that every 5 min. google app engine server checks last 40 min of fitbit step (impute 0 at all minutes with no data) on cloud. I suggest to use these same imputations of 0 for no data.

Pedja this will cause problems if person is not wearing watch in last 2 hours as then the user will definitely have less than 2000 steps.

We can change availability to include whether person is wearing the watch but this is your call. I think too complicated with too many chances for software bugs..... susan

On Thu, Aug 1, 2019 at 8:46 AM susan murphy samurphy11@gmail.com wrote:

Hi Nick, I am not sure how to respond to these github tickets so I included your email address on this response!

Yes, watch-app is source of data to determine availability:

NOT-Available if They have walked more than 150 steps in the last 40 minutes OR A message was sent in the last hour OR The user took more than 2000 steps in the last 2 hours.

You asked " How should we handle times that we don't have "complete" data? By "complete," I mean we have less than 2 hours of step counts -- which could be caused by lack of connectivity, or not wearing the watch"

I suggest to use the same procedure that is used to determine if the user has walked more than 150 steps in the last 40 min. Please remind me what this procedure is! Best Susan

On Wed, Jul 31, 2019 at 4:23 PM Nick Reid notifications@github.com wrote:

@Sabina321 https://github.com/Sabina321 This should be an easy change. Do you mind if I re-write the ticket a little?

We would be using the watch-app as the data source for this information, correct?

How should we handle times that we don't have "complete" data? By "complete," I mean we have less than 2 hours of step counts -- which could be caused by lack of connectivity, or not wearing the watch.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub <

https://github.com/kpwhri/heartsteps/issues/74?email_source=notifications&email_token=ADTRRQMM7CNK3LAMABYNLELQCHYCJA5CNFSM4IIKA3Q2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD3IOFAY#issuecomment-517005955

,

or mute the thread <

https://github.com/notifications/unsubscribe-auth/ADTRRQIC5VHISH7PZTCC5BTQCHYCJANCNFSM4IIKA3QQ

.

--


Susan A. Murphy Professor of Statistics, Radcliffe Alumnae Professor at the Radcliffe Institute and Professor of Computer Science at the Harvard John A. Paulson School of Engineering and Applied Sciences Harvard University website: http://people.seas.harvard.edu/~samurphy/ http://people.seas.harvard.edu/~samurphy/


--


Susan A. Murphy Professor of Statistics, Radcliffe Alumnae Professor at the Radcliffe Institute and Professor of Computer Science at the Harvard John A. Paulson School of Engineering and Applied Sciences Harvard University website: http://people.seas.harvard.edu/~samurphy/ http://people.seas.harvard.edu/~samurphy/


— You are receiving this because you were assigned. Reply to this email directly, view it on GitHub < https://github.com/kpwhri/heartsteps/issues/74?email_source=notifications&email_token=AAFBJ675CNHP2LOR7EERORLQCL6U5A5CNFSM4IIKA3Q2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD3K7J4Y#issuecomment-517338355 , or mute the thread < https://github.com/notifications/unsubscribe-auth/AAFBJ67QSLPG65ZCYZVPUVTQCL6U5ANCNFSM4IIKA3QQ

.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/kpwhri/heartsteps/issues/74?email_source=notifications&email_token=ADTZF7IWLATB5WPU22EWIHLQCMJEPA5CNFSM4IIKA3Q2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD3LH4QI#issuecomment-517373505, or mute the thread https://github.com/notifications/unsubscribe-auth/ADTZF7MXDNRXJ6JEXMBC7ZTQCMJEPANCNFSM4IIKA3QQ .

nickdotreid commented 5 years ago

@klasnja I don't think there is much of a difference in terms of implementation cost between using step count as a proxy for activity, or using fitbit activities.

My argument for why to use fitbit activities rather than step count is that a an "activity" is a better proxy for the intent of the availability condition we are trying to capture.

A solid counter argument, is that we don't get "real time" fitbit activities, while watch-app steps counts are what drive the system, so that metric is more reliable.

Please let me know if you have a preference of one metric or the other.

samurphy11 commented 5 years ago

Hi All, I vote to use step count from watch as then we maintain consistency and reduce confusion... So

Participants unavailable for message randomization if more than 2,000 steps in 2 hours; the number of steps comes from the watch; if no data from watch then 0 is imputed for this minute. Thanks, susan

On Sun, Aug 4, 2019 at 2:31 PM Nick Reid notifications@github.com wrote:

@klasnja https://github.com/klasnja I don't think there is much of a difference in terms of implementation cost between using step count as a proxy for activity, or using fitbit activities.

My argument for why to use fitbit activities rather than step count is that a an "activity" is a better proxy for the intent of the availability condition we are trying to capture.

A solid counter argument, is that we don't get "real time" fitbit activities, while watch-app steps counts are what drive the system, so that metric is more reliable.

Please let me know if you have a preference of one metric or the other.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/kpwhri/heartsteps/issues/74?email_source=notifications&email_token=ADTRRQIVQE2F4DAZHMBUOCTQC4OAFA5CNFSM4IIKA3Q2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD3QHDLI#issuecomment-518025645, or mute the thread https://github.com/notifications/unsubscribe-auth/ADTRRQPZAE3DSAUV6C3ZW4TQC4OAFANCNFSM4IIKA3QQ .

--


Susan A. Murphy Professor of Statistics, Radcliffe Alumnae Professor at the Radcliffe Institute and Professor of Computer Science at the Harvard John A. Paulson School of Engineering and Applied Sciences Harvard University website: http://people.seas.harvard.edu/~samurphy/ http://people.seas.harvard.edu/~samurphy/


klasnja commented 5 years ago

Nick and I just talked and, after thinking through this, we think that this should be an availability condition for both walking suggestions anti-sedentary suggestions. If the intent is not to bother people if they have been recently active, this is equally applicable to both types of activity suggestions. Please let me know if you disagree.

samurphy11 commented 5 years ago

This is fine by me. Peng, where is the latest protocol for heartsteps v2? In https://www.dropbox.com/sh/73eiewmo4n67767/AAB8eOTItYiHh2vyN1YVEReha?dl=0 ? Please tell me where to find this protocol. Best, Susan

On Tue, Aug 6, 2019 at 7:18 PM klasnja notifications@github.com wrote:

Nick and I just talked and, after thinking through this, we think that this should be an availability condition for both walking suggestions anti-sedentary suggestions. If the intent is not to bother people if they have been recently active, this is equally applicable to both types of activity suggestions. Please let me know if you disagree.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/kpwhri/heartsteps/issues/74?email_source=notifications&email_token=ADTRRQOQMFAV4NF5BAHQ6I3QDIBEVA5CNFSM4IIKA3Q2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD3WXJMI#issuecomment-518878385, or mute the thread https://github.com/notifications/unsubscribe-auth/ADTRRQPKU7JALAHMWAWJYI3QDIBEVANCNFSM4IIKA3QQ .

--


Susan A. Murphy Professor of Statistics, Radcliffe Alumnae Professor at the Radcliffe Institute and Professor of Computer Science at the Harvard John A. Paulson School of Engineering and Applied Sciences Harvard University website: http://people.seas.harvard.edu/~samurphy/ http://people.seas.harvard.edu/~samurphy/


klasnja commented 5 years ago

We should add the availability specification to the Application Architecture document in Google Drive: https://docs.google.com/document/d/1UsdR3xgVDtPpmmskc6mGsm7YJNCXJlhmE-qGk96isQw/edit?usp=sharing

I just checked and we don’t have it there, but that seems like the right place for this to live. Unless, Nick, you have another place you are documenting these kinds of decisions?

Thanks, Pedja

On August 7, 2019 at 3:01:41 PM, Susan A Murphy (notifications@github.com) wrote:

This is fine by me. Peng, where is the latest protocol for heartsteps v2? In https://www.dropbox.com/sh/73eiewmo4n67767/AAB8eOTItYiHh2vyN1YVEReha?dl=0 ? Please tell me where to find this protocol. Best, Susan

On Tue, Aug 6, 2019 at 7:18 PM klasnja notifications@github.com wrote:

Nick and I just talked and, after thinking through this, we think that this should be an availability condition for both walking suggestions anti-sedentary suggestions. If the intent is not to bother people if they have been recently active, this is equally applicable to both types of activity suggestions. Please let me know if you disagree.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub < https://github.com/kpwhri/heartsteps/issues/74?email_source=notifications&email_token=ADTRRQOQMFAV4NF5BAHQ6I3QDIBEVA5CNFSM4IIKA3Q2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD3WXJMI#issuecomment-518878385 , or mute the thread < https://github.com/notifications/unsubscribe-auth/ADTRRQPKU7JALAHMWAWJYI3QDIBEVANCNFSM4IIKA3QQ

.

--


Susan A. Murphy Professor of Statistics, Radcliffe Alumnae Professor at the Radcliffe Institute and Professor of Computer Science at the Harvard John A. Paulson School of Engineering and Applied Sciences Harvard University website: http://people.seas.harvard.edu/~samurphy/ http://people.seas.harvard.edu/~samurphy/


— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/kpwhri/heartsteps/issues/74?email_source=notifications&email_token=ADTZF7OADYLDQHS77YILAADQDNA4DA5CNFSM4IIKA3Q2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD3Z2TUQ#issuecomment-519285202, or mute the thread https://github.com/notifications/unsubscribe-auth/ADTZF7LCDBFUE2RLOIOCLETQDNA4DANCNFSM4IIKA3QQ .

nickdotreid commented 5 years ago

@klasnja "generally" I think documentation of code should be as close to the code as possible.

But I think there are generally two types of documentation:

I feel the application architecture document worked well at a high level -- but the technical details didn't work well there.

What has been working is keeping the walking suggestion service technical documentation in git (along with the code).

Soooooo, I just made a stub of the heartsteps-server's walking suggestion documentation. This is where availability is defined, so, the exact definition should live here.

I can make a pass at updating the technical documentation, and then the application architecture document. (then y'all can tell me what's wrong ;-)

samurphy11 commented 5 years ago

Hi All, Nick I think your idea of updating the technical documentation, https://github.com/kpwhri/heartsteps/blob/master/server/walking_suggestions/README.md and then the application architecture document. https://docs.google.com/document/d/1UsdR3xgVDtPpmmskc6mGsm7YJNCXJlhmE-qGk96isQw/edit is a great idea. I am concerned that we don't always understand exactly what is going on or there is confusion in communication. So Pedja if this is ok re Nick's limited time, I think this is great. I want to avoid poor science coming out of this! Thanks much, Susan

On Wed, Aug 7, 2019 at 8:55 PM Nick Reid notifications@github.com wrote:

@klasnja https://github.com/klasnja "generally" I think documentation of code should be as close to the code as possible.

But I think there are generally two types of documentation:

  • "Technical" documentation -- ie how and what happens
  • "Actual" documentation -- ie why and what happens

I feel the application architecture document https://docs.google.com/document/d/1UsdR3xgVDtPpmmskc6mGsm7YJNCXJlhmE-qGk96isQw/edit#heading=h.u47zdsejc6s1 worked well at a high level -- but the technical details didn't work well there.

What has been working is keeping the walking suggestion service technical documentation https://github.com/kpwhri/heartsteps/blob/master/walking-suggestion-service/README.md in git (along with the code).

Soooooo, I just made a stub of the heartsteps-server's walking suggestion documentation. https://github.com/kpwhri/heartsteps/blob/master/server/walking_suggestions/README.md This is where availability is defined, so, the exact definition should live here.

I can make a pass at updating the technical documentation, https://github.com/kpwhri/heartsteps/blob/master/server/walking_suggestions/README.md and then the application architecture document. https://docs.google.com/document/d/1UsdR3xgVDtPpmmskc6mGsm7YJNCXJlhmE-qGk96isQw/edit (then y'all can tell me what's wrong ;-)

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/kpwhri/heartsteps/issues/74?email_source=notifications&email_token=ADTRRQN7522DJDGM53XVRDTQDNVJFA5CNFSM4IIKA3Q2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD32DMCY#issuecomment-519321099, or mute the thread https://github.com/notifications/unsubscribe-auth/ADTRRQJGECXCMJJZ5FQIDVTQDNVJFANCNFSM4IIKA3QQ .

--


Susan A. Murphy Professor of Statistics, Radcliffe Alumnae Professor at the Radcliffe Institute and Professor of Computer Science at the Harvard John A. Paulson School of Engineering and Applied Sciences Harvard University website: http://people.seas.harvard.edu/~samurphy/ http://people.seas.harvard.edu/~samurphy/


nickdotreid commented 5 years ago

@samurphy11 -- I have the same concern about communication getting confused, and then leading to some bad science....

I will put more effort into building out the technical documentation -- it will be bad at first, but with some feedback I'm sure the documentation will get better.

nickdotreid commented 5 years ago

@klasnja @samurphy11

I've added recently active as an availability criteria, and have added a draft of activity suggestion availability documentation, here. I have also edited the application architecture document a little.

This new unavailable reason has been added to the nightly export.

@pengliao You asked me a question yesterday on g-chat that I didn't get to, but I figured it made sense to respond on this ticket, since it was related to better documenting availability. I tried to write the availability documentation to answer your question.

For reference, Peng's question was: why don't an activity suggestion's sedentary attribute always match the "unavailable_not_sedentary" column?

image

From the data you sent, this happens because there are two factors that influence if a participant is sedentary:

Currently, if there is no step count data, we are not marking the participant as sedentary. Please let me know if we want to change that logic.

PS Peng: I had trouble figuring out exactly which data points you were referring to as being incorrect. From the screenshot you sent me, I didn't notice a specific row that was incorrect.

pengliao commented 5 years ago

@nickdotreid

Hi Nick, I have some questions to clarify some details about the unavailable reasons you listed in the document. Would you please review the following and add the details in the document?

nickdotreid commented 5 years ago

@pengliao -- I've updated the documentation

I put a much more detailed description of availability in the Khttps://docs.google.com/document/d/1UsdR3xgVDtPpmmskc6mGsm7YJNCXJlhmE-qGk96isQw/edit#heading=h.c59jvo1jffp2(in the activity suggestions description). I did this because explanations of what is happening makes more sense at a higher level. I feel the technical documentation should give more of an overview, and refer to parts of the actual code.

@klasnja @samurphy11 Please read the activity-suggestion section in the application architecture document. Parts of it are still "drafty" -- but a few questions and comments will help tighten it up.

I am closing this ticket, because it appears this feature is working.

samurphy11 commented 5 years ago

Hi All, I went through the application architecture https://docs.google.com/document/d/1UsdR3xgVDtPpmmskc6mGsm7YJNCXJlhmE-qGk96isQw/edit#heading=h.53wgirkk3lt5document and put some comments about availability. Also there are a number of questions that have not been answered and I'm wondering if some of the plans are no longer possible. For example in this document we discuss the good morning message timing out, but I have the impression this is no longer possible on the apple OS. Thanks! Susan

On Wed, Aug 14, 2019 at 12:46 PM Nick Reid notifications@github.com wrote:

@pengliao https://github.com/pengliao -- I've updated the documentation

I put a much more detailed description of availability in the HeartSteps Application Architecture (in the activity suggestions description). I did this because explanations of what is happening makes more sense at a higher level. I feel the technical documentation should give more of an overview, and refer to parts of the actual code.

@klasnja https://github.com/klasnja @samurphy11 https://github.com/samurphy11 Please read the activity-suggestion section in the application architecture document. Parts of it are still "drafty" -- but a few questions and comments will help tighten it up.

I am closing this ticket, because it appears this feature is working.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/kpwhri/heartsteps/issues/74?email_source=notifications&email_token=ADTRRQI5DDGWGIYQ4BSK523QEQZGZA5CNFSM4IIKA3Q2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD4JMYVY#issuecomment-521325655, or mute the thread https://github.com/notifications/unsubscribe-auth/ADTRRQO5W22LP7Z23NZWXUTQEQZGZANCNFSM4IIKA3QQ .

--


Susan A. Murphy Professor of Statistics, Radcliffe Alumnae Professor at the Radcliffe Institute and Professor of Computer Science at the Harvard John A. Paulson School of Engineering and Applied Sciences Harvard University website: http://people.seas.harvard.edu/~samurphy/ http://people.seas.harvard.edu/~samurphy/