Stand & Move at Work: A Group Randomized Trial
Phase: NA
Conditions: Obesity, Hypertension, Diabetes
Sponsor: Arizona State University

 
 
 
The Stand and Move at Work (SMW) Study 
 
MANUAL OF PROCEDURES 
 
Version 2.0 September 25, 2015 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
Prepared by the University of Minnesota School of Public Health and Arizona State University 
College of Health Solutions 
 

SMW Study Manual of Procedures 
 
 
  
 
1.
Introduction......................................................................................................................................4 
2.
Study Organization..........................................................................................................................4 
2.1.
Study Setting......................................................................................................................4 
2.2.
Study Site Teams................................................................................................................5 
3.
Training and Documentation............................................................................................................5 
4.
Worksite Enrollment Process...........................................................................................................5 
4.1.
Identifying Potential Worksites............................................................................................5 
4.2.
Timeline..............................................................................................................................5 
4.3.
Worksite-level Inclusion Criteria..........................................................................................6 
4.4.
Screening............................................................................................................................6 
4.5.
Employee Interest Survey...................................................................................................6 
4.6.
Memorandum of Understanding/Agreement to Participate.................................................6 
5.
Participant Enrollment Process........................................................................................................6 
5.1.
Town Hall Presentations.....................................................................................................6 
5.2.
Participant-level Inclusion Criteria.......................................................................................7 
5.3.
Participant Eligibility Survey................................................................................................7 
5.4.
Consent...............................................................................................................................7 
6.
Randomization.................................................................................................................................7 
7.
The Study Interventions...................................................................................................................7 
7.1.
Intervention Overview.........................................................................................................7 
7.2.
Intervention Components………………………………………………………………………..8 
7.2.1.
Policy-level components........................................................................................8 
7.2.2.
Environmental-level components...........................................................................9 
7.2.3.
Individual-and social-level components...............................................................10 
7.3.
Difference between Intervention Arms..............................................................................11 
8.
Collecting Worksite Data................................................................................................................12 
9.
Collecting Participant Data.............................................................................................................12 
2 

SMW Study Manual of Procedures 
 
 
  
 
10.
Measures.......................................................................................................................................12 
10.1.
Blood Pressure.................................................................................................................13 
10.2.
Anthropometrics............................................................................................................... 13 
10.3.
ActivPAL...........................................................................................................................14 
10.4.
Venipuncture.....................................................................................................................14 
11.
Data Management.........................................................................................................................15 
11.1.
In-person Visit Data..........................................................................................................15 
11.2.
Survey Data......................................................................................................................15 
11.3.
ActivPAL Data...................................................................................................................15 
11.4.
Data Integrity.....................................................................................................................15 
12.
Data Analysis Plan.........................................................................................................................15 
12.1.
Data Analysis....................................................................................................................15 
12.2.
Power Analysis.................................................................................................................16 
13.
Adverse Event Reporting and Recording.......................................................................................17 
 
Appendix  
1.
ActivPAL processes…………………………………………………………..…....……....…………….18 
1.1.
ActivPAL Waterproofing and Taping.................................................................................18 
1.2.
Initialization.......................................................................................................................18 
1.3.
Handout instructions for reaffixing activPAL.....................................................................21 
1.4.
Data download and processing.........................................................................................21 
 
 
 
 
 
 
3 

SMW Study Manual of Procedures 
 
 
  
 
1. Introduction  
Stand & Move at Work is a two-arm group-randomized trial. Worksites (N = 24) of small to 
moderate size (20–50 employees enrolled; N=720 employees across the 24 sites) will be 
randomized to one of two interventions: (a) ​MOVE​+, a multi-level behavioral intervention 
targeting increases in LPA at the worksite; or (b) ​STAND​+, the multi-level ​MOVE​+ intervention 
along with the installation of sit-stand workstations to allow workers to stand at their desks while 
working. Both worksite interventions are expected to reduce sitting and increase LPA over 12 
months and improve cardiometabolic risk and work performance outcomes. We hypothesize the 
effects to favor the ​STAND​+ study arm because the additional sit-stand workstation 
enhancement will provide a robust environmental stimulus to reduce sitting and provide 
a unique catalyst for LPA in the workplace. The ​MOVE​+ arm will receive sit-stand workstations 
at 12 months and both arms will be assessed for follow-up at 24 months. 
 
Primary Aim:  
To evaluate the relative efficacy of ​MOVE​ and ​STAND​+​MOVE​ interventions on LPA and sitting 
behaviors over 12 months, with process measures at 3 months and maintenance measures at 
24 months. The ​STAND​+​MOVE​ intervention, relative to the MOVE intervention, will: (H1) 
increase LPA at work and (H2) reduce sitting time at work over 12 months. Additional process 
outcomes at 3 months and maintenance outcomes at 24 months will be collected. 
Secondary Aims:  
To evaluate the relative efficacy of ​MOVE​ and ​STAND​+​MOVE​ interventions on cardiometabolic 
risk (composite measure of fasting glucose, insulin, triglycerides, HDL-cholesterol, and blood 
pressure) over 12 months, with additional follow-up to 24 months. The ​STAND​+​MOVE 
intervention, relative to the ​MOVE​ intervention, will (H3) lower cardiometabolic risk over 12 
months 
 
2. Study Organization 
The study was funded by the National Cancer Institute at the National Institutes of Health. The 
trial is managed collaboratively by the Principal Investigators (PI) at both study sites (i.e. Arizona 
State University and the University of Minnesota, Twin Cities).  
 
2.1 Study Setting 
Worksites will be enrolled in the greater Phoenix, AZ, USA and Minneapolis, MN, USA 
metropolitan regions. Twelve worksites will be randomized in each region. Selected worksites 
will be drawn from three distinct work sectors: higher education, industry/healthcare (e.g., law 
firms, health insurance providers), and government (e.g., state departments). Worksites will be 
equally selected in each sector across each region (n= 4/sector/region worksites). 
 
Each site will be responsible for recruiting participating worksites and participating individuals 
within the worksties. A single digit site ID will be incorporated as the first digit of the three digit 
worksite ID that each enrolling worksite will be assigned. 
 
2.2 Study Site Teams 
4 

SMW Study Manual of Procedures 
 
 
  
 
The PI of each site will be responsible for his own staff and will secure IRB approval prior to the 
start of the study team. A research coordinator at each site will work with the PI to ensure the 
study stays on the scheduled timeline, and that data collection and study activities are 
implemented according to study protocols. 
 
3. Training and Documentation 
All staff will complete IRB-required training, including human subjects, in advance of the study. 
In addition, all data collection staff will be trained on the collection of anthropometric and blood 
pressure measures. Phlebotomists collecting biospecimens (i.e. venous blood samples) will 
have completed all necessary training for the collection and handling of biospecimens. 
 
4. Worksite Enrollment Process 
The worksite enrollment process refers to the tasks that each site undertakes to initiate 
Worksite accrual, beginning with identifying potential worksites, screening and consenting, 
and randomizing. 
 
4.1. Identifying Potential Worksites 
We will recruit worksites that meet our inclusion criteria and then recruit individual 
employees within each of the worksites (see Section 5). We aim to recruit 24 small to moderate 
sized worksites across our two geographical areas – Phoenix, AZ and Minneapolis/St. Paul, MN 
(12 worksites in Arizona and 12 in Minnesota; see inclusion criteria in Section 4.3). Partnerships 
with large companies from our preliminary studies will be leveraged to help identify participating 
worksites, although we will avoid recruiting individual worksites that have been involved in our 
past studies. We will also leverage others in our professional networks, including individuals 
involved in workplace wellness, to help identify potential worksites.  In advance of the grant 
proposal, we garnered very strong and broad support from many employers and worksites of 
various sizes in both Arizona and Minnesota. We will be recruiting worksites from three different 
workplace sectors including academia, government, and healthcare to enable greater 
generalizability of study results.  
 
4.2. Timeline 
Participating worksites will be recruited as pairs within a single sector at each worksite utilizing a 
rolling recruitment method. We will also rotate the enrollment of sector pairs over the seasons of 
the full calendar year to help avoid seasonal effects, beginning with the first two pairs enrolled in 
January 2016 and the final two pairs enrolled in November 2016. Enrolling two pairs every other 
month will also alleviate logistical and labor burdens for recruitment, data collection, and 
intervention implementation. 
 
4.3. Worksite-level Inclusion Criteria 
Worksite level inclusion criteria include: 
(a) Size: small to moderate size worksite (20-60 employees) 
(b) Schedule: >80% of employees full-time 
5 

SMW Study Manual of Procedures 
 
 
  
 
(c) Occupation: seated office work, primarily computer- and telephone-based work, little 
movement or walking 
(d) Wellness environment: not currently undergoing a wellness program aimed at increasing 
activity at work 
(e) Workstations: willing to have sit-stand workstations installed at worksite 
(f) Willing to engage in worksite-level intervention activities 
(g) Willing to be randomized to either intervention condition 
 
4.4. Screening 
Worksites will be screened for eligibility by study questionnaires completed by worksite 
leadership and followed up with interviews by study personnel to verify eligibility. If a worksite 
meets the inclusion criteria, a general level of employee enthusiasm for the study will be 
assessed (see Section 4.4) 
 
 4.5. Employee Interest Survey 
At worksites where inclusion criteria have been met, an anonymous survey will be sent to 
employees to gauge interest in participating in a ​study looking to decrease sitting time and 
increase light-intensity activity at work (i.e. level of enthusiasm and likely participation)​, and 
additional questions to assess both  their physical workspace (whether the space could 
accommodate sit-stand desks)  and individual level questions (to determine generally whether 
the person would meet the individual level inclusion criteria). 
 
4.6. Memorandum of Understanding/Agreement to Participate 
Presuming a worksite has enough employee interest to move forward, a memorandum of 
understanding will be developed and signed by the worksite manager and study principal 
investigators to facilitate adherence to the study timeline and intervention.  As part of this 
process, both a study leader and study advocate(s) will be identified. 
 
5. Participant Enrollment Process 
This section details Participant enrollment, beginning with recruitment, screening and 
consenting, and randomizing. 
 
5.1. Town Hall Presentations  
All worksite employees will be invited to a Town Hall presentation(s) scheduled based on the 
suggestions of the worksite leader and/or advocates. Up to two town halls will be scheduled at 
any given worksite to allow for the greatest attendance. While in-person Town Halls are desired, 
electronic town halls will be made available as an option. For those unable to attend a Town 
Hall, al copy of the TownHall powerpoint presentation will also be provided. The purpose of the 
Town Hall meeting will be to allow the site PI to state the study goals, aims, methods, 
inclusion/exclusion criteria, and timeline.  Following the town hall, interested (or all, depending 
upon the preference of the worksite leader) employees will be emailed a description of the 
study, including a consent form, along with a link to complete the eligibility screener 
questionnaire.  
 
6 

SMW Study Manual of Procedures 
 
 
  
 
5.2. Participant-level Inclusion Criteria 
Participant eligibility criteria will be as follows:  
(a) 18 years or older;  
(b) generally good health and able to safely reduce sitting and increase LPA;  
(c) working full-time on-site (i.e. 30+ hours and at least 4 days in the office per week);  
(d) not currently pregnant; 
(e) predominant worksite occupation being seated office work;  
(f) not currently using a sit-stand workstation at their primary desk location at work;  
(g) willing to have a sit-stand workstation installed at their desk; and  
(h) willing to be randomized to either study arm. 
 
5.3. Participant Eligibility Survey 
An online eligibility survey will be distributed to each worksite employee following the 
informational sessions. All eligible participants will be invited to schedule a 30-minute slot during 
an assessment morning held at the worksite. 
 
5.4. Consent 
Those who are eligible and choose to attend the baseline assessment visit will be sent a copy of 
the consent form will be sent in advance and reviewed in person prior to commencing the visit. If 
the participant agrees to take part, they will provide written consent. Note: Participants from 
Minnesota government worksites will also be asked to sign a Tennessen agreement. 
 
6. Randomization 
Randomization to either the ​STAND+ ​or ​MOVE​+intervention arms of the trial will be at the level 
of the worksite. Randomization will be stratified on the three sectors nested within each of the 
two regions (Phoenix, AZ and Minneapolis/St. Paul, MN).Within each region, eligible worksites 
will be enrolled in pairs matched on sector, and each matched pair will be randomized so that 
one is randomized to receive the​ STAND​+ intervention with the other receiving the ​MOVE​+ 
intervention. This scheme will ensure a balanced design by both region and sector.  
 
Randomization will not occur until all four worksites in the recruitment wave (2 per region) have 
completed their baseline assessments. Therefore, a participant will be considered enrolled in 
the active intervention once they have consented, completed baseline assessments, and paired 
worksites have been randomized to study arm. Prior work by our research team has suggested 
that we should expect 40%–75% participation within the identified worksite, which based upon 
worksite size will approximate our target recruitment of N = 720 participants. 
 
7. Study Interventions 
7.1 Intervention Overview 
The ‘Stand & Move at Work’ interventions will be delivered over 12 months and is based upon 
both the social ecological framework and social cognitive theory principles. The intervention 
development team is comprised of behavioral scientists, exercise scientists, ergonomists, and 
worksite wellness coordinators. The primary behavioral target of the ​MOVE​+intervention is to 
7 

SMW Study Manual of Procedures 
 
 
  
 
accumulate 30 min or more additional LPA each day. The primary behavioral target of the 
STAND​+intervention is, in addition to the ​MOVE​+ target, to increase time spent standing to 50% 
of desk-based time during the workday (e.g. standing for 3 h out of 6 total desk-hours per day).  
 
Our approach will target intervention strategies at the individual, social, environmental, 
and organizational levels. 
 
All intervention materials will be manualized into the Stand & Move at Work “Toolkit.” The toolkit 
will be distributed to each worksite prior to the intervention start date. It is expected that each 
worksite and/or sector may differ in the time, resources, space, and personnel available 
to dedicate to the implementation of the intervention. The Toolkit will therefore be comprised of 
both “required” strategies (i.e., strategies that are required to be implemented by worksite staff 
during the intervention period) and “optional” strategies (i.e., strategies that worksite 
staff are encouraged to implement as are appropriate given the worksite context). Additional 
strategies generated by the worksite staff will also be encouraged. This approach ensures 
uniformity of the delivered interventions across worksites and allows flexibility and autonomy 
among worksites. Actual implementation of intervention strategies will be closely monitored 
through quarterly worksite audits and worksite leader interviews. 
 
To help facilitate these changes within the worksite, trained research staff met with worksite 
advocates quarterly to discuss implementation strategies for the upcoming quarter, as well as 
successes and barriers of implementation of the previous quarter. The worksite leader holds a 
higher level management position to which the department, division or unit employees report. 
This person will not be required to implement changes but will voice support, encourage 
participation and approve policy changes. Worksite advocate(s) plays an active role with 
program participants and will work to implement the selected changes. Considered a primary 
contact to link worksite employees and management. Advocate characteristics include: 
outgoing, ability to connect and engage with others, regular interaction with staff, good 
communicators.  
 
7.2 Intervention Components 
7.2.1. Policy-level components.  
The intervention framework is highly dependent on the identification and engagement of 
worksite administrators and managers to enact policy-level workplace modifications, 
implement robust environmental changes (e.g., sit-stand workstations), and to model and 
promote behavior change. Therefore, a required item will be to identify a worksite leader and 
advocate(s). A leader is defined as a person holding a higher-level management position 
to which the department, division, or unit employees report. The primary role of this individual 
will be to provide higher-level support for intervention strategies to be implemented. Primary 
responsibilities will be to determine appropriate Toolkit items, encourage participation in 
worksite initiatives, and approve potential policy changes. An advocate is defined as a person 
who plays an active role with study participants and will work closely with the Stand & Move at 
Work study team to implement the selected changes. Advocates will be considered the primary 
8 

SMW Study Manual of Procedures 
 
 
  
 
contact to link worksite employees,management, and the study team. Primary responsibilities 
will include 
aiding the implementation of strategies agreed upon by higher-level management. 
Organizational changes will be reinforced by the distribution of four quarterly support emails 
sent by the leader to employees in the workgroup. Templates will be provided to minimally 
include: (a) support for the program and employee participation; (b) a brief review of 
the previous quarter progress; (c) commendation of individuals who have shown high levels of 
engagement; and (d) an outline of new intervention initiatives for the upcoming quarter. Leaders 
will also formally agree to allow employees up to 5 min breaks every hour. Shared leader and 
advocate responsibilities will include quarterly meetings with an experienced behavioral science 
research team member who will be the designated worksite coordinator throughout the 
study to review past progress and plan for the coming quarter using the Toolkit as a guide. The 
aim of the research team member is to facilitate the intervention by ensuring all materials and 
concepts are explained fully explained, it is not to actively lead the intervention. As 
such, all team members will have extensive knowledge of the Stand and Move Toolkit to provide 
the leaders and advocates with support. Successes and challenges from the previous quarter 
will be discussed and each worksite will be encouraged to implement a new strategy to 
maintain or potentially increase employee interest in the program. Similarly, all worksite leaders 
and advocates will be invited to join a monthly ​STAND​+ and ​MOVE​+ conference call with the 
study principal investigators. Thesewill serve several purposes: (a) to provide opportunities 
for other worksites to share and learn from other worksites within the same randomized study 
arm; (b) to document worksite participation, progress, and new strategies; and (c) to provide 
insight into the breadth and scale of the study to reinforce participation from a scientific and 
health-based perspective. 
 
7.2.2. Environment-level components.  
The primary environmental difference between the ​STAND​+ and ​MOVE​+ study arms will be the 
installation of a sit-stand workstation for the​ STAND​+ arm only. The workstations will be 
installed by our trained research staff, as well as worksite-specific ergonomic and wellness 
professionals. The Ergotron sit-stand workstation Workfit-TL model (Ergotron, Inc., St. Paul, 
MN) has been selected because it is able to be retro-fitted for use with almost all workspaces, 
requires little or no installation as it is simply placed on the existing desk surface, is affordable 
relative to many alternatives, has more desk surface area then many alternatives on the market, 
it can be easily raised and lowered to a broad range of positions, and can accommodate one or 
two large computer monitors. The Workfit-TL transitions from seated to standing positions by 
holding two levers and providing minimal force. Prior to installation a workspace inventory will be 
conducted for each participant to identify any potential barriers to use such as overhead 
shelving, insufficient computer cabling, or fixed keyboard trays. To eliminate these barriers, 
overhead shelving will be moved by worksite facilities management, cable extenders added (if 
needed), and additional wireless keyboards will be provided to those with keyboard trays so that 
participants are not required to move their existing keyboards with each sit-stand transition. The 
same Ergotron Workfit-TL will be installed at the 12-month time point for all MOVE+arm 
participants. All participants will receive ergonomic instructions for both sitting and standing 
postures via the e-newsletter and will undergo a coaching session at the time of installation. 
9 

SMW Study Manual of Procedures 
 
 
  
 
Other required environmental changes will include a signage starter pack that is designed to (a) 
provide information about the behavior; (b) provide information on benefits of action (e.g., 
benefit of taking the stairs); (c) encourage goal setting (e.g., “make this a standing meeting”; 
(d) provide general encouragement (e.g., “we stand for health”); (e) provide instruction (e.g., 
walking routes around the office space);and (f) serve as visual cues. Signage will also 
demonstrate organizational support for the program and intent to change the cultural norm. 
Walking routes will be created for each worksite to reinforce the behavioral targets listed above. 
Typical routes will include alternative restrooms, centralized printing and trash can areas, and 
indoor and outdoor (if possible) perimeter routes. The distance per route and estimated 
number of steps will be provided on the signage. Advocates will be encouraged to place walking 
routes in communal and prominent areas throughout the worksite. All participants regardless of 
randomization will be provided with a footrest. The footrests will serve the following three 
purposes: (a) as a resting position for either foot while both seated and standing; (b) as 
a stretching aid (gastrocnemius and soleus); and (c) as a visual reminder regarding participation 
in the program. Leaders and advocates may also wish to implement additional optional 
environmental changes throughout the program via combined environmental, individual, and 
social strategies. For example, a prominent and interactive communal board to promote the 
Stand & Move at Work program (termed an “Ideaboard”) or implementing environmentally based 
worksite challenges (e.g., centralized printing only challenges). Ideaboard templates 
and example challenges will be provided in the Toolkit.  
 
7.2.3. Individual- and social-level components.  
An e-newsletter (The Insider) will provide a regular and direct medium for delivering individual- 
and social-level intervention content. The Insider will incorporate both individual (e.g., 
goal-setting) and social elements (e.g., quizzes and worksite social announcements). The 
Insider will be sent weekly during the first month of the intervention to facilitate transition and 
encourage early engagement. During months 2–12, the Insider will be sent bi-weekly, and a 
total of 26 newsletters will be sent. See Table 2 for a list of Insider topics. The content has been 
developed and designed by behavioral scientists and worksite wellness professionals to target 
25 out of the 26 components of the behavioral taxonomy wheel. Motivational interviewing will be 
the only component not targeted, given the need for face-to-face interaction. The Insider will be 
coordinated with and reinforced by additional complementary organizational, environmental, 
and social components. Other individual level strategies will include a 1-on-1 coaching session 
to identify specific goals and behavior change strategies relating to the key intervention 
messages. Using a goal setting sheet, participants will be encouraged to record and display 
their goals within daily eyesight. Participants will also receive instructions regarding the 
deskbased ergonomic set up (both ​MOVE​+ and​ STAND​+). The ​STAND​+ arm will receive 
specific instructions (guided by an experienced ergonomist) regarding their new sit-stand 
workstation set up. Key messages will include switching position regularly and gradually 
increasing standing or LPA time. Social strategies (i.e., formation of walking or stretching 
groups) may be endorsed by leaders via support emails, actively led by advocates, or promoted 
via additional signage and Ideaboard content. Due to the variation in worksite culture, job 
demands and environmental challenges, it is expected that new ideas and variations of the  
10 

SMW Study Manual of Procedures 
 
 
  
 
suggested Toolkit items will emerge. This will be discussed and documented during the 
quarterly meetings and quarterly audits. The required multi-level tactics show reinforcement of 
behavior change across the social-ecological spectrum, utilizing all aspects of the behavior 
change taxonomy wheel. This integrated approach shows promise for shifting the cultural norm 
within a workplace from reinforcing highly sedentary, seated behavior patterns to one where 
standing and moving is expected, rewarded, and celebrated. This cultural shift is necessary 
to produce sustainable, long lasting changes that are likely to impact health and well-being on a 
large scale. 
 
Both​ STAND​+ and ​MOVE​+ worksites received the same multi-component intervention toolkit 
targeting organizational, environmental, cultural, and social changes within the workplace. 
Examples organizational changes included: (a) installation of sit-stand workstations (b) quarterly 
support emails, (c) ergonomic support and (d) bi-weekly e-newsletters. Examples of 
Environmental changes included: walking routes, (b) signage, (c) waste and recycling bin 
reallocation, (d) use of centralized printing areas, (e) inviting stairways and an (g) ideaboard. 
Examples of cultural and social changes included (a) allowance of 5-min breaks every hour, (b) 
promotion of face-to-face interaction, rather than email, (c)  standing meetings, (d) walking 
meetings, (e) stretch breaks), (f) contests), and (g) social groups.  
 
7.3 Difference between Intervention Arms 
The primary study arm differences will be implemented at the environmental level with the 
provision of a sit-stand desk at the start of the intervention for the ​STAND​+group only. This 
primary difference will require small adaptations to other intervention strategies. First, participant 
goals will differ per arm to reflect the different arm intervention goals (i.e., increasing standing 
and LPA time for ​STAND​+ vs. increasing LPA only for ​MOVE​+). All participants will be 
encouraged to adhere to a ‘30-min rule’, however, the meaning of this target rule will differ per 
arm. For the ​STAND​+ group this will be communicated as achieving a 30:30-minute sit to stand 
ratio to ultimately replace half their sit time with a combination of standing and moving at work. 
For the MOVE+ group this will be communicated as replacing 30 min of sit time with an equal 
accumulation of moving more throughout the work day. The 1-on-1 sessions held at the start of 
the program will facilitate specific goal setting at the individual level to help achieve the 
‘30-minute rule’ per arm. Consequently, the strategies communicated during the 1-on-1 session 
and throughout the study duration will differ slightly per arm (see Table 3). 
 
Second, although the ​STAND​+ and ​MOVE​+ arms will be provided with an identical Stand & 
Move Toolkit and the same level of support to implement socio-ecological changes, it is likely 
that the application of the Toolkit will differ per arm to target the specific target intervention arm 
goals. Finally, in some instances, the e-newsletter topics will remain the same across arms but 
the content will be adjusted per arm to reduce contamination and ensure that information is 
specific to the intervention arm. For example, the ergonomically themed e-newsletter will include 
sit-stand desk information for the ​STAND​+ group, however, the ​MOVE​+ content will only include 
seated desk information. Stand & Move intervention support for ​STAND​+ will cease following 
the 12-month assessment period. However, ​MOVE​+ participants will receive a sit-stand desk 
and ergonomic advice at the 12-month time point, and after which no additional intervention 
11 

SMW Study Manual of Procedures 
 
 
  
 
support will continue post-installation. Both arms will still have access to the Toolkit during this 
follow-up period (12–24 months). 
 
8. Collecting Worksite Data 
Worksite level data will be collected in conjunction with in-person (or by phone as a last resort) 
Quarterly meetings held with each worksite. These meetings will be held at Baseline, prior to the 
start of the intervention, 3-months, 6-months, 9-months, and a final meeting at 12-months.  
Data collected at each of these time points will include: 
-
Planned intervention activities 
-
Completed intervention activities 
-
Successes or barriers of intervention activities 
-
Quarterly Audit Survey ​that asks about various organizational and individual level 
activities, events, resources, and facilities. 
 
9. Collecting Participant Data 
Participant level data will be collected in four time points, including baseline, 3-months, 
12-months, and 24-months. Participants will be scheduled for fasting visits held in the morning 
at their respective worksites. As two worksites will be recruited to start the intervention at the 
same time, with collection dates being within one week of each other, participants can opt to 
attend a visit at the other worksite. 
 
Data collected at the in-person fasting visit will include: 
-
Blood pressure 
-
Height (baseline only) 
-
Weight 
-
Pregnancy status (biologically females only) 
-
Fasting venous blood draw 
An activPAL will be affixed to the right leg of each participant at the visit; this placement will be 
rescheduled if the participant will be out of the office for the majority of the upcoming week.  
Daily surveys will be administered in conjunction with the activPAL wear. These logs will assess 
both daily sleep and work times and be sent via Qualtrics each morning for seven days. 
 
Along with the in-person visit and activPAL wear, a main study survey will be sent out during 
each assessment period (baseline, 3-months, 12-months and 24-months). This survey will be 
used to collect demographic characteristics as well as information regarding sleep, diet, physical 
activity, and overall health.  
 
10. Measures 
All measurements will be taken at baseline and 12 months, with additional interim measurement 
at 3months and follow-up at 24 months.All questionnaires will be administered via Qualtrics 
(Salt Lake City, UT) 
 
12 

SMW Study Manual of Procedures 
 
 
  
 
10.1 Blood Pressure 
Blood pressure will be measured with the Omron BP742 automated machine and the Omron 
HEM-RML30 cuff (Omron Healthcare Inc., Lake Forest, IL) three times following 5 min of quiet 
sitting, with 30 s in between each measurement. The lowest two measures of diastolic and 
systolic blood pressures will be averaged for final blood pressure values. 
 
10.2 Anthropometrics 
Standing height will be measured in centimeters (cm) using a portable height board (SECA). 
Prior to the height measurement the participant should remove his/her shoes. If the subject has 
a hair accessory or hairstyle that interferes with the measurement, she/he will be asked to 
remove the accessory or change her/his hairstyle (e.g. take out ponytail band) if possible (some 
hair styles/accessories are difficult to remove or costly to replace, and these styles may be left in 
place).  
(a) Participant must stand erect with his/her back towards the stadiometer. The weight of the 
participant must be evenly distributed on both feet and the arms hang freely by the sides 
of the body, palms facing the thighs. The participant should place the heels together, 
with both heels touching the base of the vertical board. The feet should point slightly 
outward, at about 60° angle. Note: If the subject has knock-knees, the feet are separated 
so that the medial borders of the knees are in contact but not overlapping. 
(b)  The subject’s head should be positioned in the Frankfurt Horizontal plane. In this 
position an imaginary line can be drawn from the bottom of the eye socket (orbital 
margin) to the external opening of the ear (external auditory canal). 
(c) The heels, shoulder blades, buttocks, and back of the head should be against the 
vertical surface. Note: The heels, buttocks, scapulae, and posterior aspect of the 
cranium (head) of some subject cannot be place in one vertical plane while maintaining a 
reasonable natural stance. These subjects are positioned so that only the buttocks and 
the heels or the cranium are in contact with the vertical board. 
(d) The participant should be asked to inhale deeply and hold his/her breath, while 
maintaining the erect position and without altering the load on the heels. Reposition the 
head in the Frankfurt plane, if necessary. The moveable headboard should be brought 
onto the highest point of the head, with sufficient pressure to compress the hair. 
(e) If the participant is notably taller than the study staff member responsible for recording 
the reading, she/he should use a step stool to view the measurement. 
(f) The measurement is recorded to the nearest 0.1 cm. The measurement is called out by 
the measurer as follows: “height, 162.5” and repeated “162.5” as he/she writes down the 
number on the Anthropometry Form. The participant is asked to step away and then step 
back into the same position for a second measurement. 
(g) Repeat the process and record the second measurement in the ‘Trial B’ column of the 
height section of the Anthropometry Form. 
(h) If the first and second measurements differ by >1 cm repeat the measurements, a third 
measurement will be taken.  
Any conditions or situations, which occur to make the measurement undependable on the 
bottom of the form. (e.g. subject couldn’t or refused to comply with the removal of hair 
accessory, wouldn’t remove shoes, etc.) will be noted.  
13 

SMW Study Manual of Procedures 
 
 
  
 
 
Body weight will be measured in kilograms (kg) using a Tanita TBF-300A Total Body 
Composition Analyzer.  The Tanita scale also allows for the calculation of percent body fat 
utilizing bioelectrical impedance.All participants will be queried about the presence of any 
medical device that would be impacted by the small electrical current. Only weight measures will 
be taken for those endorsing the presence of such devices. 
(a) The participant will be asked to remove shoes, any coat or cardigan, and empty his/her 
pockets. 
(b) The participant will stand in the center of scale, facing away from the balance, holding 
the head up. Body weight must be evenly distributed on both feet and the participant 
must have his/her hands hanging freely at his/her sides (i.e. make sure participant is not 
holding on to anything). 
(c) Weight is measured and recorded to the nearest 0.1 kg. 
(d) The body fat percentage will be displayed after a short pause, and should be recorded.  
(e) Have the participant step off the scale, and then repeat steps a-d, and record the second 
weight/body fat percentage. 
(f)  If the first and second measurements differ by > 0.2 kg repeat the measurements, a 
third measurement will be taken. 
Any conditions or situations, which occur to make the measurement undependable, should be 
noted on the bottom of the form​. 
 
10.3 ActivPAL 
Our primary outcomes, time spent sitting and LPA at work, will be assessed with the activPAL3 
micro accelerometer (PAL Technologies, Glasgow, United Kingdom) for seven consecutive days 
at each measurement time point. The activPAL will be waterproofed using medical grade 
adhesive covering and attached to the midline of the thigh using a breathable, hypoallergenic 
tape. This method allows for the monitor to be worn continuously for seven consecutive days 
without removing for bathing or other water-based activities (a valuable feature that reduces 
missing data). Additional adhesive dressing will be given to all participants for re-application as 
necessary. The primary outputs of the activPAL are time spent sitting, time spent upright, and 
time spent “stepping.” Participants concurrently will complete an online daily log where they will 
report their sleep/wake schedule and time arriving and departing their workplace. The daily logs 
will be used to filter time spent sitting and LPA during work hours. In addition, any uninterrupted 
sedentary bouts of more than 6 h that occur within reported wake times will be considered 
non-wear times and treated as missing data. Days with <10 h of monitor wear data or <4 hours 
of reported work time as monitor wear data will be excluded from analyses. Outcomes will be 
reported as a standardized 8 h workday to account for differences in total work time. Full details 
of activPAL initialization, wear, and download protocol are in Appendix 1. 
 
10.4 Venipuncture 
Participants will be instructed to fast for nine consecutive hours prior to each blood draw. Blood 
will be drawn from the antecubital vein into EDTA vacutainers, and plasma will be stored at 
−80C until analysis in batch. Samples from the Phoenix site will be shipped to UMN on dry ice 
periodically for batch-processing. Biomarker analyses will be conducted by the Advanced 
14 

SMW Study Manual of Procedures 
 
 
  
 
Research and Diagnostic Laboratory at the University of Minnesota, Minneapolis, MN, using a 
Roche COBAS 6000 chemistry analyzer (Roche Diagnostics, Indianapolis, IN). Plasma glucose 
will be measured by the hexokinase method (interassay CV = 1.3% at 97.2 mg/dL, 1.8% at 
223.3 mg/dL). Plasma HDL-C will be measured by the modified direct enzymatic approach 
(interassay CV = 3.2% at 27.0 mg/dL, 1.9% at 51.7 mg/dL). Plasma triglycerides 
will be measured with the GPO-Trinder kit (Roche Diagnostics, Indianapolis, IN; interassay CV = 
2.0% at 112.4 mg/dL, 2.3% at 195.8mg/dL). Plasma insulin will be measured with a sandwich 
immunoassay using electrochemilumincescence (Roche Diagnostics, Indianapolis, IN; 
interassay CV=3.1% at 121.2 pmol/L, 3.1% at 377.9 pmol/L). 
 
11.Data Management 
11.1 In-person Visit Data 
In person visit data, including anthropometrics, blood pressure,  and whether venous blood 
draws were successful will be collected on paper forms. These forms will be kept in secure, 
locked filing cabinets and entered into Qualtrics.  
 
11.2. Survey Data 
All survey data will be collected via Qualtrics. Qualtrics is a secure, web-based platform for 
designing, collecting, and securing survey data. All survey data will be stored on encrypted 
servers. 
 
11.3 ActivPAL Data 
ActivPAL data will be extracted and stored on secure study servers at each site. The University 
of Minnesota will upload this data to BOX for retrieval by ASU, who will be the primary site to 
compile, clean, and process this data. 
 
11.4 Data Integrity 
All clinical assessment data will be double entered. All blood data will be examined for 
computational value errors associated with out-of-range variables. All data will be examined for 
outliers and improbable values. 
 
12. Data Analysis Plan  
12.1 Data analysis. 
Threats to internal validity (e.g. contamination, envy) preclude randomization of individuals 
within the same worksite; hence, a group randomized trial is being conducted [54]. Such a trial 
involves randomization of worksites with members within a worksite being assigned to the same 
experimental condition. Hierarchical linear (or generalized linear) models will be used to provide 
valid estimates of the intervention effect and its variance (for generating the test of statistical 
significance). Because the number of sites is limited by feasibility, the asymptotic balance of all 
measured and unmeasured confounders is not applicable, and hence it is important to 
randomize worksites within small blocks (or pairs) of matched worksites with similar 
characteristics likely to affect the outcome measure. Because our goal is to enroll 12 worksites 
in the Phoenix area and 12 in the Minneapolis area, we will stratify the randomization scheme 
15 

SMW Study Manual of Procedures 
 
 
  
 
on geographical location so that we will not have any confounding by geographical location (AZ 
vs. MN). We will identify six pairs of sites in AZ and six pairs in MN, with the pair members 
having the same sector (academia, government, or healthcare/industry). Each pair will be 
randomized so that one worksite in each pair is assigned to the ​MOVE​+ intervention and the 
other in that pair assigned to the ​STAND​+intervention. One of the site PIs and a Biostatistician 
at the University of Minnesota will be responsible for the randomization. Randomization will 
occur immediately following the baseline data collection for both sites. The PI will notify the 
biostatistician when there are two matched worksites ready for randomization. The two 
worksites will be ordered as “First” and “Second” depending on the calendar dates of the 
baseline data collection. The statistician, with no knowledge of the worksites, will use a coin flip 
to assign the two worksites to the ​STAND​+ or ​MOVE​+ interventions. Initial analyses will provide 
descriptions of the baseline frequencies and means (SD) of characteristics by worksite and by 
experimental condition. Statistical testing of differences in baseline characteristics is not 
necessary, but will provide assurance that the randomization has not produced a grossly 
unbalanced assignment. If the distributions of our outcome variables are not normally 
distributed, we will log-transform the outcome data. Our primary hypotheses will be tested by 
invoking a repeated-measures hierarchical linear model of the experimental contrast between 
the two conditions of the 12-month measure of LPA (min/ 8-h) and sitting (min/8-h), respectively. 
Because total time is standardized to 8 h, we will also express our outcomes in percent of time 
in LPA and sitting. A repeated measures hierarchical analysis will be conducted. The covariates 
expected to include are age, sex, body mass index, and the baseline values of the dependent 
variables (e.g., sitting time, LPA, and metabolic risk score). The resulting estimate and its 
standard error provide a t-statistic based on 2(g-1) degrees of freedom (df), where g represents 
the number of worksites per experimental condition [54]. A similar analysis will examine the 
secondary hypothesis for the metabolic risk score. Other outcomes, including sit-stand 
transitions, will use hierarchical generalized linear models with a log link. The analysis approach 
for process (3 month) and maintenance (24 month) outcomes will be similar. In terms of missing 
data, sensitivity to member-dropout is small; if on average only 85% are followed, the detectable 
effect sizes increase by a factor 1.05. Worksite dropout would be a major threat to validity, but 
that is highly unlikely to occur. Baseline characteristics of those not providing follow-up data will 
be examined to assess whether these are non-informative missingness. Under the assumption 
that dropout is not related to the measures that would have been collected, the analysis of the 
data excluding dropouts is unbiased. 
 
12.2 Power Analysis  
We aim to enroll 24 worksites (N=12 per condition) evenly distributed across Arizona and 
Minnesota with on average 30 employees per worksite (Total N members = 720 employees). In 
a baseline-adjusted analysis, let D represent the minimal detectable intervention effect, g the 
number of worksites per experimental condition, m the average number of members per 
worksite, S​2 ​the member variance, T​2 ​the work-site level variance, r​m ​and r​g ​the member and 
work-site correlations over time respectively, and t(d,a/2) and t(d,p) the critical t-statistic values 
based on d df for a/2=Type I alpha level (2-sided) and p=power. Then the minimal detectable 
difference is ​D​2 ​= (t(d,a/2) + t(d,p))​2 ​(S​2​(1- r​2m​)/m+ T​2​(1-r2​g​))*2/g​. Dividing by S​2 ​yields the 
square of the Effect Size (ES)​ ​and T​2​/S​2 ​is the variance components ratio (VCR). In the unlikely 
16 

SMW Study Manual of Procedures 
 
 
  
 
situation where the g are unequal, replacing 2/g by (1/g​0​+1/g​1​) will lead to a minimal increase in 
D unless the g are grossly unequal. With g=12 (worksites per condition), d=22, and N=720, 
m=30; a/2 is set to 0.025 and power is set 80%. The detectable effect sizes for this trial range 
from 0.21 to 0.26 across the three outcomes, which are relatively small effects, and thus we are 
well powered in this study. On an absolute scale, as also shown in the table, we will be able to 
detect a difference between intervention arms as small as 12.2 min/8-hr work day of LPA and 
14.6 min/8-hr work day of sitting time. Our preliminary studies clearly demonstrate our ability to 
achieve these effects: (a) For LPA; the crossover study (12) showed a 38.4min/8-hr workday 
increase (other two studies did not target LPA or did not use a monitor designed to detect LPA); 
(b) for sitting, both the crossover and natural experiment showed >30min/8-hr workday 
reductions; and (c) for cardiometabolic risk, all 3 studies showed moderate to large effect sizes. 
This study is powered well to detect effects that are considerably smaller than what we have 
observed in our preliminary studies 
 
12. Adverse Event Reporting and Recording  
Adverse events will be monitored during the study to ensure timely detection of events that 
may affect safety or continued participation. Protocol defined adverse events, as well as any 
unanticipated adverse events deemed possibly or probably related to study procedure, must be 
immediately reported to the study PI and/or Project Coordinator. In the event an adverse event 
occurs, the PI will submit an adverse event report to the IRB within 24hrs. 
 
 
 
 
17 

SMW Study Manual of Procedures 
 
 
  
 
Appendix 1. ActivPAL processes 
 
Appendix 1.1 ActivPAL Waterproofing and Taping 
  
1. Wrap a finger cot around an initialized activPAL. 
 
2. On the finger cot, label the activPAL with participant’s ID number and an arrow going 
up (in the same direction as the human body on the activPAL). Ensuring orange side 
up, as pictured. 
3. Wrap a 12cm by ½ of the width of the wide opsite (clear) tape around the activPAL. 
Make sure the activPAL is thoroughly covered. This can be done efficiently by sticking 
one end of the opsite tape onto the edge of a table and rolling the activPAL up the 
length of the tape.  
4. Cut out a 6 by 6 cm piece of hypafix (white) tape and a 6 by 6 cm piece of opsite 
tape. 
5. Place the waterproofed activPAL in the center of the white side of the hypafix tape. 
6. Place the opsite tape over the activPAL to secure it to the white side of the hypafix 
tape. 
7. Use extra small opsite pieces of tape to ensure that the activPAL is secured to the 
hypafix tape. The activPAL should look like this: 
8. Do not peel off the back of the hypafix tape until it is time to place it on the 
participant’s leg. 
 
Appendix 1.2. Initialization 
18 

SMW Study Manual of Procedures 
 
 
  
 
 
1. To initialize, place your designated activPAL into the ‘PC INTERFACE’ port; the other ports 
only serve as a charging area. 
2. Plug in the activPAL dock to the computer/laptop using a micro USB cord.  
3. Open the activPAL software and select File, then ‘Connect to ActivPAL’ 
 
4.  Verify Battery Level is at least ​4.15 Volts 
5. Next select Setup – this is for initializing devices only. 
19 

SMW Study Manual of Procedures 
 
 
  
 
 
6. Select ‘​Future Time​,’ Enter in your participants de-identified 5 digit ID in the ​recording 
identifier​ section; choose your starting time (Stand and move is always ​10:00 am​); Choose 
your starting date; then select record for ​14 days​. Then hit program. 
 
7. Click OK. 
8. Remove the device. 
20 

SMW Study Manual of Procedures 
 
 
  
 
  
Appendix 1.3. Handout instructions for reaffixing activPAL 
 
Appendix 1.4. Data download and processing. 
1.
Load activPAL software. Double click Icon on Desktop. 
2.
Insert ActivPAL into dedicated port on dock labeled 'PC INTERFACE'. Then, connect 
dock to desktop tower via USB cable. 
3.
Select 'File' --> 'Connect to ActivPAL' 
4.
Select ‘Download’ from top left of the ‘PALconnect’ window (unless download screen 
opens first) 
5.
Verify Identifier to participant # in Database. 
6.
Click ‘Download Stored Data’ 
7.
To save recording data, Click New Folder 
8.
Select the appropriate folder. E.g., for Stand&move@work: X:\Buman Lab\Stand and 
Move ASU_UMN\Data\ActivPAL\Visit #\ParticipantID#; (Visit= T1, T2, T3, T4, etc. based 
on timeline for each site); Participant ID= 5 digit number as indicated in Participant 
Database  
9.
Check the folder where you saved the data to double check that the file has been 
correctly downloaded. (6 files uploaded for each participant). 
10. Once the data has been successfully downloaded, select view at the top of the activPAL 
software screen. Then select “view by week,” and open the corresponding pal file. This is 
what we will be sharing with participants as feedback. In order for the activPAL data to 
be considered valid, there needs to be ​four valid days​ with ​8hour/day​ of valid wear time 
per day. 
 
Example of valid data 
  
  
Example of invalid data 
21 

SMW Study Manual of Procedures 
 
 
  
 
 
 
11. Log the non-wear times (6 hours of consecutive sitting or standing) here: Z:\Buman 
Lab\Stand and Move ASU_UMN\Data\ActivPAL\Errors.xlsx 
12. To save the PAL file as a PDF, click the ‘print’ icon on the upper left corner of the 
activPAL screen. Click OK 
13. A screen will prompt you to save the file à Save the file on (X:\Research\Buman 
Lab\Stand and Move ASU_UMN\Data\Participant Feedback\T#\ID#_T#). 
14. The file should now be saved in the corresponding folder as a PDF. 
·         The PDF file can be sent to participants as feedback either by email or by printing. 
·         Refer to Sending activPal Feedback Protocol to email 
 
Appendix 1.4. activPAL processing SAS code. 
************************************************************************************************************/ 
*ActivPAL Procesing:
  
*
Outputs the following variables:
*
1. Long_sitbouts_dur - Total mins spent sitting > 30 mins bouts 
 
*
2. Long_sitbout_ct
- Number of long sitting bouts
 
*
3. Short_sitbout_dur
- Total mins spent sitting < 30 mins bouts
 
*
4. Short_sitbout_ct
- Number of short sitting bouts
 
*
5. Sit
- Total minutes spent sitting
 
*
6. Stand
- Total minutes spent standing
 
*
7. LPA
- Total minutes spent on LPA (stepping activitties 
with cadence <100 steps/mins) * 
*
8. MVPA
 Total minutes spent on MVPA(stepping activitties 
with cadence <100 steps/mins) * 
/**********************************************************************************************************/ 
 
 
/********************************/ 
/*Set libref                    */ 
22 

SMW Study Manual of Procedures 
 
 
  
 
/********************************/ 
 
LIBNAME SMASU 'P:\Sample_SMASU\'; 
Libname Track "X:\Buman Lab\Stand and Move 
ASU_UMN\Data\ActivPAL\ISO_TEST\SAS_FILES\DailyLogs"; 
 
LIBNAME ISO 'X:\Buman Lab\Stand and Move 
ASU_UMN\Data\ActivPAL\ISO_TEST\SAS_FILES\DATASETS'; 
 
 
*Create temnplate for daily summary; 
 
DATA iso.Report_Final; 
INPUT  
ID  
Mtime 
Date 
P1_Sitstand 
P1_long_sitbout_ct 
P1_long_sitbout_dur 
P1_short_sitbout_ct 
P1_short_sitbout_dur 
P1_min 
P1_Sit 
P1_Stand 
P1_LPA 
P1_MVPA 
P1_Step_min 
P1_Step_ct 
P1_step00_05 
P1_step05_10 
P1_step10_15 
P1_step15_30 
P1_step30_60 
P1_step60_90 
P1_step90_120 
P1_step120_up 
P1_nbouts_sed 
P1_alphasit 
P1_parm1_sit 
P1_x50_sit 
P1_min_t_sit 
P1_max_t_sit 
P1_totsed 
23 

SMW Study Manual of Procedures 
 
 
  
 
P1_nbouts_sed_tot 
P1_ginisit 
P1_mean_period 
P2_Sitstand 
P2_long_sitbout_ct 
P2_long_sitbout_dur 
P2_short_sitbout_ct 
P2_short_sitbout_dur 
P2_min 
P2_Sit 
P2_Stand 
P2_LPA 
P2_MVPA 
P2_Step_min 
P2_Step_ct 
P2_step00_05 
P2_step05_10 
P2_step10_15 
P2_step15_30 
P2_step30_60 
P2_step60_90 
P2_step90_120 
P2_step120_up 
P2_nbouts_sed 
P2_alphasit 
P2_parm1_sit 
P2_x50_sit 
P2_min_t_sit 
P2_max_t_sit 
P2_totsed 
P2_nbouts_sed_tot 
P2_ginisit 
P2_mean_period 
P3_min 
P3_Sitstand 
P3_long_sitbout_ct 
P3_long_sitbout_dur 
P3_short_sitbout_ct 
P3_short_sitbout_dur 
P3_Sit 
P3_Stand 
P3_LPA 
P3_MVPA 
P3_Step_min 
24 

SMW Study Manual of Procedures 
 
 
  
 
P3_Step_ct 
P3_step00_05 
P3_step05_10 
P3_step10_15 
P3_step15_30 
P3_step30_60 
P3_step60_90 
P3_step90_120 
P3_step120_up 
P3_nbouts_sed 
P3_alphasit 
P3_parm1_sit 
P3_x50_sit 
P3_min_t_sit 
P3_max_t_sit 
P3_totsed 
P3_nbouts_sed_tot 
P3_ginisit 
P3_mean_period 
P4_Sitstand 
P4_long_sitbout_ct 
P4_long_sitbout_dur 
P4_short_sitbout_ct 
P4_short_sitbout_dur 
P4_min 
P4_Sit 
P4_Stand 
P4_LPA 
P4_MVPA 
P4_Step_min 
P4_Step_ct 
P4_step00_05 
P4_step05_10 
P4_step10_15 
P4_step15_30 
P4_step30_60 
P4_step60_90 
P4_step90_120 
P4_step120_up 
P4_nbouts_sed 
P4_alphasit 
P4_parm1_sit 
P4_x50_sit 
P4_min_t_sit 
25 

SMW Study Manual of Procedures 
 
 
  
 
P4_max_t_sit 
P4_totsed 
P4_nbouts_sed_tot 
P4_ginisit 
P4_mean_period 
P5_Sitstand 
P5_long_sitbout_ct 
P5_long_sitbout_dur 
P5_short_sitbout_ct 
P5_short_sitbout_dur 
P5_min 
P5_Sit 
P5_Stand 
P5_LPA 
P5_MVPA 
P5_Step_min 
P5_Step_ct 
P5_step00_05 
P5_step05_10 
P5_step10_15 
P5_step15_30 
P5_step30_60 
P5_step60_90 
P5_step90_120 
P5_step120_up 
P5_nbouts_sed 
P5_alphasit 
P5_parm1_sit 
P5_x50_sit 
P5_min_t_sit 
P5_max_t_sit 
P5_totsed 
P5_nbouts_sed_tot 
P5_ginisit 
P5_mean_period; 
 
FORMAT Date date. waketime bedtime worktime offworktime datetime29.; 
DATALINES; 
RUN; 
 
*Pull all filenames from directory; 
 
filename DIRLIST pipe 'dir "X:\Buman Lab\Stand and Move 
ASU_UMN\Data\ActivPAL\ISO_TEST\SAS_FILES\taggedfiles\T1\*.csv" '; 
 
26 

SMW Study Manual of Procedures 
 
 
  
 
 
 
 
data dirlist ; 
 
infile dirlist lrecl=200 truncover; 
 
input line $200.; 
 
length file_name $ 130;  
if input(substr(line,1,10), ?? mmddyy10.) = . then delete;  
file_name="X:\Buman Lab\Stand and Move 
ASU_UMN\Data\ActivPAL\ISO_TEST\SAS_FILES\taggedfiles\T1\"|| substr(line,40); 
Mtime="1"; 
ID=substr(file_name,101,5); 
ID2=Id*1; 
Site=substr(id,1,3)*1; 
keep file_name ID Mtime site ID2; 
 
run; 
  
*Command to automatically create macro calls; 
 
data test; 
 
set  dirlist end=end;  
/*Where site>200;*/ 
/*where id2=10104;*/ 
count+1; 
 
  
call symput ('filepath'||left(count),left(trim(file_name))); 
call symputx ('ID'||left(count),ID); 
call symputx ('Mtime'||left(count),Mtime); 
if end then call symput('max',count); 
 
run; 
 
 
*Write log directly to the specified text file to prevent interuptions; 
 
proc printto log="X:\Buman Lab\Stand and Move 
ASU_UMN\Data\ActivPAL\ISO_TEST\AP_Processing_04.23.18.log"; 
run; 
 
 %let datetime_start = %sysfunc(TIME()) ; 
  %put START TIME: %sysfunc(datetime(),datetime14.);  
options mprint symbolgen;  
 
 
 
 
%MACRO APimport(filepath,ID,Mtime); 
%do i=1 %to &&max;  
27 

SMW Study Manual of Procedures 
 
 
  
 
*import AP event file; 
DATA import; 
INFILE "&&filepath&i" 
LRECL=32760 
 
ENCODING="WLATIN1" 
 
TERMSTR=crlf 
 
DLM=',' 
 
MISSOVER 
firstobs=2 
 
DSD ; 
INPUT Datetimevar 
Count 
Intervalold_s 
ActivityCode 
APCumulativeStepCount 
APActivityScoreMEThr 
validday_est 
Sleepbout 
ID 
Mtime 
; 
boutid = _N_; 
sasdatetimenumber = (Datetimevar - 21916)*86400;*convert exceldate to 
sasdatetime; 
CumulativeStepCount_i = APCumulativeStepCount; 
steps_n = APCumulativeStepCount - lag(CumulativeStepCount_i); 
if boutid = 1 then 
steps_n = APCumulativeStepCount; 
 
if Datetimevar in (0,.) then 
delete;
*remove rows of 0s from end of some activpal event files; 
if intervalold_s in (0,.) then delete; 
drop CumulativeStepCount_i;*non cumulative steps; 
if intervalold_s>=21600 then delete=1;else delete=0; 
 
RUN; 
 
 
*recalculate intervals as time between each bout -> more precise than the rounded data; 
proc Sort data =import; 
by id descending boutid; 
run; 
 
data events (drop= Datetimevar intervalold_s APcumulativestepcount); 
28 

SMW Study Manual of Procedures 
 
 
  
 
set import; 
boutidR = _N_; 
sasdatetimenumber_endbout = lag(sasdatetimenumber); 
 
if sasdatetimenumber_endbout = . & sasdatetimenumber ne . then 
sasdatetimenumber_endbout = sasdatetimenumber + Intervalold_s; 
Interval_s = sasdatetimenumber_endbout - 
sasdatetimenumber; 
basicdate = datepart(sasdatetimenumber); 
noondate = datepart(sasdatetimenumber + 43200); 
 
*dates at beginning of bout 
for day and for noon to noon window; 
format sasdatetimenumber sasdatetimenumber_endbout datetime26.6 basicdate 
noondate ddmmyy10.; 
run; 
 
proc Sort data =events; 
by id boutid; 
run; 
 
*Expand each event into 1-seconds epochs; 
 
DATA events2; SET events; 
If interval_s>=1 then interval_p=floor(interval_s); 
else if interval_s<1 then interval_p=interval_s; 
 
do _i_ = 0 to Interval_s-(Interval_s/interval_p) by (Interval_s/interval_p); *preserves elapsed 
time of non-whole number intervals; 
datetime3=sasdatetimenumber+_i_; 
output; 
end; 
format datetime3 datetime26.6 date date9.; 
Run; 
 
*recalcualte interval between each epoch; 
 
Proc sort data=events2; 
by descending datetime3; 
run; 
 
data events2;set events2; 
gap=lag(datetime3)-datetime3; 
if gap>=1 then p=floor(gap); 
29 

SMW Study Manual of Procedures 
 
 
  
 
else if gap<1 then p=gap; 
date=datepart(datetime3); 
if gap=. then delete; 
 
run; 
 
Proc sort data=events2; 
by datetime3; 
run; 
 
*pull log data; 
 
DATA windows3(drop=gap date noondate mtime); SET track.masterlogs2; 
WHERE ID=&&id&i*1; 
IF bedtime=. then delete; 
 
IF new_ootm=. then delete; 
RUN; 
 
*Merge logs with activpal data; 
 
PROC SQL; 
CREATE TABLE APwake AS 
SELECT
t1.id, 
t1.Mtime, 
 
t1.Datetime3, 
t1.sasdatetimenumber, 
t1.sasdatetimenumber_endbout, 
t1.validday_est, 
t1.basicdate, 
t1.noondate, 
t1.activitycode, 
t1.Count, 
t1.gap, 
t1.Interval_s, 
t1.Steps_n, 
t1.boutid, 
t1.delete, 
t2.new_ootm, 
t2.bedtime, 
t2.MTS, 
t2.Sleeptime, 
t2.wake_freq, 
t2.total_time_awake, 
30 

SMW Study Manual of Procedures 
 
 
  
 
t2.waketime, 
t2.ootm, 
t2.Workday, 
t2.MOT_to, 
t2.WorkTM, 
t2.OffWorkTM, 
t2.MOT_off, 
t2.Start, 
t2.End, 
t2.impute 
 
FROM events2 AS t1 
NATURAL JOIN windows3 AS t2 
WHERE t1.datetime3 BETWEEN t2.new_ootm AND t2.Bedtime 
ORDER BY t1.ID, t1.datetime3; 
 
QUIT; 
RUN; 
 
* export dataset to create intermediate files that can be re-analyzed for later use; 
 
Data "X:\Buman Lab\Stand and Move 
ASU_UMN\Data\ActivPAL\ISO_TEST\SAS_FILES\DATASETS\MetaData\APWake_&&id&i.._T
&&Mtime&i"; set ApWake; 
Run; 
 
*Calculate cadence; 
 
data step; set APwake; 
 
Activity_code2 = Activitycode; 
  
*calculating a 0/1 variable for whether the event is stepping (and relevant, to be included) or not; 
ActStep =0; 
if Activity_code2 =2 then ActStep = 1; 
if ActStep = 1 then newstepbout = 1; 
  
*calculating a 0/1 variable for whether the relevant stepping event is part of a new stepping bout 
or not; 
if ActStep = 1 & ActStep = lag(ActStep) then newstepbout = 0; 
newbout = 0; 
if Activity_code2 in (.,0,1) then newbout = 1; 
if Activity_code2 =2 & newstepbout=1 then newbout = 1; 
 
31 

SMW Study Manual of Procedures 
 
 
  
 
If delete=1 then delete;* remove potential non-wear: bouts>6 hrs; 
run; 
 
 
data step2; 
set step; 
by id; 
*numbering the stepping bouts [newboutid]; 
if first.id then newboutid = 0; 
if newbout = 1 then newboutid  + 1; 
run; 
 
proc means data = step2 noprint; 
by id newboutid; 
where ActStep = 1; 
output out=step3 min(sasdatetimenumber)=bs_dt max(sasdatetimenumber_endbout)=be_dt 
sum(steps_n)=steps_n; 
; 
run; 
  
data step3 (keep= ID newboutid cadence stepboutdur); 
set step3; 
*date the stepping bout began for later aggregation; 
  
basicdate = datepart (bs_dt); 
*duration of the stepping bout; 
stepboutdur = be_dt - bs_dt; 
  
*cadence; 
cadence = 2*steps_n/(stepboutdur/60);  
 
run; 
 
Proc SQL; 
Create table cadence as 
select a.*, 
b.Cadence, 
b.stepboutdur 
From step2 as a 
Left join step3 as b 
on a.ID=b.ID and a.newboutid=b.newboutid 
order by a.Datetime3; 
Quit; 
 
32 

SMW Study Manual of Procedures 
 
 
  
 
*categorize epochs into either SED STAND LPA MVPA; 
 
Data cadence2(drop=sasdatetimenumber);set cadence; 
if start<=datetime3<=end then delete; *Delete errors/non-wear time; 
 
date=datepart(datetime3); 
 
IF Workday=2 or WorkDay=0 THEN Status=1; /*nonworkday*/ 
IF Workday=1 AND WorkTM <= datetime3 <= OffWorkTM THEN Status=2;/*atwork*/ 
IF Workday=1 AND not (WorkTM <= datetime3 <= OffWorkTM) THEN 
Status=3;/*offwork*/ 
 
IF activitycode=2 AND cadence ge 100 THEN act_intensity=3; /*MVPA*/ 
ELSE IF activitycode=2 AND cadence lt 100 then act_intensity=2; /*LPA*/ 
ELSE IF activitycode=1 THEN act_intensity=1;/*Standing*/ 
ELSE IF activitycode=0 THEN act_intensity=0;/*Sitting*/ 
 
%MACRO PERIOD(tt); *Defines macro with variable (I chose to call it tt for time) that will be set 
to 1-5; 
%If &tt.=1 %then %do; 
%Let P=1; 
%end; 
%If &tt.=2 %then %do; 
%Let P=2; 
%end; 
%If &tt.=3 %then %do; 
%Let P=3; 
%end; 
%If &tt.=4 %then %do; 
%Let P=2 3; 
%end; 
%If &tt.=5 %then %do; 
%Let P=1 2 3; 
%end; 
IF status in (&P.) then P&TT.=gap; else P&TT.=0; 
IF status in (&P.) and act_intensity=0 then P&TT._Sit=gap; 
 
else P&TT._Sit=0; 
IF status in (&P.) and act_intensity ge 1 and lag(act_intensity)=0 then P&TT._Sitstand=1; 
else P&TT._SitStand=0; 
IF status in (&P.) and act_intensity=0 and interval_s>=1800 then 
P&TT._long_sitbout_ct=1/floor(interval_s);  
else P&TT._long_sitbout_ct=0; 
IF status in (&P.) and act_intensity=0 and interval_s<1800 then 
P&TT._short_sitbout_ct=1/floor(interval_s);  
33 

SMW Study Manual of Procedures 
 
 
  
 
else P&TT._short_sitbout_ct=0; 
IF status in (&P.) and act_intensity=0 and interval_s>=1800 then P&TT._long_sitbout_dur=gap;  
else P&TT._long_sitbout_dur=0; 
IF status in (&P.) and act_intensity=0 and interval_s<1800 then P&TT._short_sitbout_dur=gap;  
else P&TT._short_sitbout_dur=0; 
IF status in (&P.) and act_intensity=1 then P&TT._Stand=gap; 
 
else P&TT._Stand=0; 
IF status in (&P.) and act_intensity=2 then P&TT._LPA=gap; 
 
else P&TT._LPA=0; 
IF status in (&P.) and act_intensity=3 then P&TT._MVPA=gap; 
 
else P&TT._MVPA=0; 
IF status in (&P.) and activitycode=2 then P&tt._step_min=gap; 
 
else P&tt._step_min=0; 
IF status in (&P.) and activitycode=2 then P&tt._step_ct=1;  
else P&tt._step_ct=0; 
IF status in (&P.) and activitycode=2 then DO; 
if stepboutdur<5 then P&tt._step00_05=gap; 
 
else P&tt._step00_05=0; 
if 5<=stepboutdur<10 then P&tt._step05_10=gap;  
else P&tt._step05_10=0; 
if 10<=stepboutdur<15 then P&tt._step10_15=gap;  
else P&tt._step10_15=0; 
if 15<=stepboutdur<30 then P&tt._step15_30=gap;  
else P&tt._step15_30=0; 
if 30<=stepboutdur<60 then P&tt._step30_60=gap;  
else P&tt._step30_60=0; 
if 60<=stepboutdur<90 then P&tt._step60_90=gap;  
else P&tt._step60_90=0; 
if 90<=stepboutdur<120 then P&tt._step90_120=gap; 
 
else P&tt._step90_120=0; 
if stepboutdur>=120 then P&tt._step120_up=gap;  
else P&tt._step120_up=0; 
End; 
 
%MEND; *Ends macro; 
 
%PERIOD(1); *Runs for P1 variables; 
%PERIOD(2); *Runs for P2 variables; 
%PERIOD(3); 
%PERIOD(4); 
%PERIOD(5); 
 
 
 
34 

SMW Study Manual of Procedures 
 
 
  
 
Run; 
 
 
data Lis; 
set APwake; 
 
IF Workday=2 or WorkDay=0 THEN Status=1; /*nonworkday*/ 
IF Workday=1 AND WorkTM <= datetime3 <= OffWorkTM THEN Status=2;/*atwork*/ 
IF Workday=1 AND not (WorkTM <= datetime3 <= OffWorkTM) THEN 
Status=3;/*offwork*/ 
Run; 
 
 
%Macro Pattern(tt); 
%If &tt.=1 %then %do; 
%Let P=1; 
%end; 
%If &tt.=2 %then %do; 
%Let P=2; 
%end; 
%If &tt.=3 %then %do; 
%Let P=3; 
%end; 
%If &tt.=4 %then %do; 
%Let P=2 3; 
%end; 
%If &tt.=5 %then %do; 
%Let P=1 2 3; 
%end; 
 
 
Data Upright; Set Lis; 
where status in (&P.); 
dur_bout = gap/60; 
 
*set activity code to missing for any data that is not valid - 
-sleep: exclude 
-off time: exclude 
-not valid day  (for the type of day in question): exclude 
-not part of the time you are interested in as appropriate - eg not work hours; 
Activity_code2 = Activitycode; 
if delete=1|validday_est=0  then do; 
Activity_code2 = . ; 
dur_bout = .; 
35 

SMW Study Manual of Procedures 
 
 
  
 
end; 
 
*split the actual valid time into bouts of upright/ not; 
ActUpright =0; 
if Activity_code2 in (1,2) then ActUpright = 1; 
if ActUpright = 1 then newupbout = 1; 
if ActUpright = 1 & ActUpright = lag(ActUpright) then newupbout = 0; 
 
newbout = 0; 
if Activity_code2 in (.,0) then newbout = 1; 
if Activity_code2 in(1,2) & newupbout=1 then newbout = 1; 
run; 
 
data upright2; 
set upright; 
by ID; 
if first.ID then newboutid = 0; 
if newbout = 1 then newboutid  + 1; 
run; 
 
proc means data = upright2 noprint; 
by ID newboutid; 
where ActUpright = 1; 
output out=upright3 
sum (dur_bout) = dur_actbout 
; 
run; 
 
 
data upright3; 
set upright3; 
ln_dur_actbout = log(dur_actbout); 
drop _type_ _freq_; 
run; 
 
proc means data = upright3 noprint; 
by ID; 
output out=upright4 
mean(ln_dur_actbout) = mn_dur_actbout 
stddev(ln_dur_actbout) = sd_dur_actbout 
; 
run; 
 
*MEANPERIOD - mean of a lognormal distribution based on mle for a lognormal distribution; 
36 

SMW Study Manual of Procedures 
 
 
  
 
data upright4 (keep =ID P&tt._mean_period); 
set upright4; 
P&tt._mean_period = exp(mn_dur_actbout + ((sd_dur_actbout**2)/2)); 
run; 
 
*Recombine sedentary bouts; 
Data sedbt;set lis; 
if delete=1|validday_est=0 then delete; 
 
Run; 
 
proc means data=sedbt nonobs noprint; 
by id boutid; 
output out= sedbt2  
sum(gap)
= gap  
mean(status)
= status 
mean(activitycode)
= activitycode; 
Run; 
 
 
 
*** sedentary accumulation; 
data sed (keep = ID boutid dur_sed); 
Set sedbt2; 
where status in (&P.); 
if Activitycode =  0; 
 
dur_sed = gap/60; 
run; 
 
proc sort data = sed; 
by ID dur_sed; 
run; 
 
proc means data=sed noprint; 
by ID; 
output out=summary min(dur_sed)=P&tt._min_t_sit max(dur_sed)=P&tt._max_t_sit 
sum(dur_sed)=P&tt._totsed ; 
run; 
 
 
data sed; 
merge sed summary; 
by ID; 
37 

SMW Study Manual of Procedures 
 
 
  
 
*ln_tdivmint is used in calculating alpha - you can use the min setting in the AP software or the 
observed minimum. We use the observed minimum; 
ln_tdivmint = log(dur_sed/P&tt._min_t_sit); 
*ln_tdivmint = log(dur_sed/(10/60)); *alternative using the minimun setting in the AP software; 
 
rename _freq_ = P&tt._nbouts_sed_tot; 
drop  _type_; 
run; 
 
 
proc means data=sed noprint; 
by ID; 
output out=alpha sum(ln_tdivmint)=ln_tdivmint_sum; 
run; 
 
 
data alpha; 
set alpha; 
P&tt._alphasit = 1 + ( _freq_ * (1/ln_tdivmint_sum)); 
drop _type_; 
run; 
 
proc means data=sed noprint; 
by ID dur_sed; 
output out=bybout sum(dur_sed)=dur_sed_tot min(P&tt._totsed)=P&tt._totsed 
min(P&tt._nbouts_sed_tot)=P&tt._nbouts_sed_tot; 
run; 
 
proc sort data=bybout; 
by ID dur_sed; 
run; 
 
 
*calculating gini and x50 -> non linear regression; 
data accrual; 
set bybout; 
by ID; 
percent = 100*(_freq_/P&tt._nbouts_sed_tot); 
prop_totsed = (dur_sed_tot / P&tt._totsed); 
if first.ID then do; 
cum_dur_sed = 0; 
perpop=0; 
end; 
cum_dur_sed + dur_sed_tot; 
38 

SMW Study Manual of Procedures 
 
 
  
 
perpop + percent; 
cum_prop_sed = cum_dur_sed / P&tt._totsed; 
proppop = perpop /100; 
xlag = lag(proppop); 
ylag = lag(cum_prop_sed); 
if first.ID then do; 
xlag =0; 
ylag = 0; 
end; 
columna = (cum_prop_sed) * xlag; 
columnb = (proppop) * ylag; 
if first.PID then do; 
suma = 0; 
sumb = 0; 
end; 
suma + columna; 
sumb + columnb; 
P&tt._ginisit = suma - sumb; 
if last.ID then do; 
keepme=1; 
end; 
drop _type_; 
rename _freq_ = P&tt._nbouts_sed dur_sed = bout_length; 
*** cum_dursed is the cumulative sed time accrued at bouts that lenght or shorter  
perpop is the cumulative proportion of bouts that lenght or shorter....  
NOTE- not the cumulative % of total time accrued in bouts that length or shorter; 
run; 
*note that for x50 you only need  
bout_length [bout duration in minutes] and  
cum_prop_sed [cumulative proportion of sedentary in bouts <= each bout_length]; 
 
data gini (keep = ID P&tt._ginisit P&tt._nbouts_sed_tot); 
set accrual; 
if keepme =1; 
run; 
 
proc sort data = accrual; 
by ID bout_length; 
run; 
 
*nonlinear regression fitting curve to find x50; 
proc nlin data=accrual method=MARQUARDT noprint;  
by ID ; 
  parameters parm1=-5 to 5 by 0.1 x50=0 to 60 by 1;  
39 

SMW Study Manual of Procedures 
 
 
  
 
  bounds x50 >= 0; 
  model  cum_prop_sed= (bout_length**parm1) / ((bout_length**parm1)  + (x50**parm1));  
  output out=x_estimates_sit predicted = pred_sit l95=l95_sit u95=u95_sit parms=parm1 x50; 
run;  
quit; 
 
 
*x_estimates_sit: data at the level of each bout duration so as to plot accumulation curves if 
desired; 
data x_estimates_sit (keep = ID bout_length parm1_sit x50_sit pred_sit l95_sit u95_sit); 
set x_estimates_sit; 
rename parm1 = parm1_sit x50 = x50_sit; 
run; 
 
 
*x_person_sit: data at the level of each individual - the summary info to keep; 
 
proc means data=x_estimates_sit noprint; 
by ID; 
output out=x_person_sit min(parm1_sit)=P&tt._parm1_sit min(x50_sit)=P&tt._x50_sit; 
run; 
 
data x_person_sit; 
set x_person_sit; 
drop _type_ _freq_; 
run; 
 
 
data P&tt._sitpattern; 
merge alpha x_person_sit summary gini upright4; 
by ID; 
rename _FREQ_ = P&tt._nbouts_sed ; 
drop _type_ ln_tdivmint_sum; 
run; 
 
%Mend Pattern; 
 
%Pattern(1); 
%Pattern(2); 
%Pattern(3); 
%Pattern(4); 
%Pattern(5); 
 
Data AP_var; Merge P1_sitpattern P2_sitpattern P3_sitpattern P4_sitpattern P5_sitpattern; 
40 

SMW Study Manual of Procedures 
 
 
  
 
by ID; 
Run; 
 
PROC SQL ; 
  CREATE TABLE sittostand AS 
  SELECT 
ID, 
Mtime, 
Date, 
sum(P1_sitstand) 
as P1_Sitstand, 
round(sum(P1_long_sitbout_ct),1) 
as P1_long_sitbout_ct, 
sum(P1_long_sitbout_dur)/60 
as P1_long_sitbout_dur, 
round(sum(P1_short_sitbout_ct),1) as P1_short_sitbout_ct, 
sum(P1_short_sitbout_dur)/60
as P1_short_sitbout_dur, 
sum(P1)/60
 
as P1_min, 
sum(P1_Sit)/60
 
as P1_Sit, 
sum(P1_Stand)/60 
as P1_Stand, 
sum(P1_LPA)/60
 
as P1_LPA, 
sum(P1_MVPA)/60 
as P1_MVPA, 
sum(P1_step_min)/60
as P1_step_min, 
sum(P1_step_ct)
as 
P1_step_ct, 
sum(P1_step00_05)/60
as 
P1_step00_05, 
sum(P1_step05_10)/60
as 
P1_step05_10, 
sum(P1_step10_15)/60
as 
P1_step10_15, 
sum(P1_step15_30)/60
as 
P1_step15_30, 
sum(P1_step30_60)/60
as 
P1_step30_60, 
sum(P1_step60_90)/60
as 
P1_step60_90, 
sum(P1_step90_120)/60
as 
P1_step90_120, 
sum(P1_step120_up)/60
as 
P1_step120_up, 
sum(P2_sitstand) 
as P2_Sitstand, 
round(sum(P2_long_sitbout_ct),1) 
as P2_long_sitbout_ct, 
sum(P2_long_sitbout_dur)/60 
as P2_long_sitbout_dur, 
round(sum(P2_short_sitbout_ct),1)
as P2_short_sitbout_ct, 
sum(P2_short_sitbout_dur)/60
as P2_short_sitbout_dur, 
sum(P2)/60
 
as P2_min, 
sum(P2_Sit)/60
 
as P2_Sit, 
41 

SMW Study Manual of Procedures 
 
 
  
 
sum(P2_Stand)/60 
as P2_Stand, 
sum(P2_LPA)/60
 
as P2_LPA, 
sum(P2_MVPA)/60 
as P2_MVPA, 
sum(P2_step_min)/60
as P2_step_min, 
sum(P2_step_ct)
as 
P2_step_ct, 
sum(P2_step00_05)/60
as 
P2_step00_05, 
sum(P2_step05_10)/60
as 
P2_step05_10, 
sum(P2_step10_15)/60
as 
P2_step10_15, 
sum(P2_step15_30)/60
as 
P2_step15_30, 
sum(P2_step30_60)/60
as 
P2_step30_60, 
sum(P2_step60_90)/60
as 
P2_step60_90, 
sum(P2_step90_120)/60
as 
P2_step90_120, 
sum(P2_step120_up)/60
as 
P2_step120_up, 
sum(P3)/60
 
as P3_min, 
sum(P3_sitstand) 
as P3_Sitstand, 
round(sum(P3_long_sitbout_ct),1) 
as P3_long_sitbout_ct, 
sum(P3_long_sitbout_dur)/60 
as P3_long_sitbout_dur, 
round(sum(P3_short_sitbout_ct),1)
as P3_short_sitbout_ct, 
sum(P3_short_sitbout_dur)/60
as P3_short_sitbout_dur, 
sum(P3_Sit)/60
 
as P3_Sit, 
sum(P3_Stand)/60 
as P3_Stand, 
sum(P3_LPA)/60
 
as P3_LPA, 
sum(P3_MVPA)/60 
as P3_MVPA, 
sum(P3_step_min)/60
as P3_step_min, 
sum(P3_step_ct)
as 
P3_step_ct, 
sum(P3_step00_05)/60
as 
P3_step00_05, 
sum(P3_step05_10)/60
as 
P3_step05_10, 
sum(P3_step10_15)/60
as 
P3_step10_15, 
sum(P3_step15_30)/60
as 
P3_step15_30, 
42 

SMW Study Manual of Procedures 
 
 
  
 
sum(P3_step30_60)/60
as 
P3_step30_60, 
sum(P3_step60_90)/60
as 
P3_step60_90, 
sum(P3_step90_120)/60
as 
P3_step90_120, 
sum(P3_step120_up)/60
as 
P3_step120_up, 
sum(P4)/60
 
as P4_min, 
sum(P4_sitstand) 
as P4_Sitstand, 
round(sum(P4_long_sitbout_ct),1) 
as P4_long_sitbout_ct, 
sum(P4_long_sitbout_dur)/60 
as P4_long_sitbout_dur, 
round(sum(P4_short_sitbout_ct),1)
as P4_short_sitbout_ct, 
sum(P4_short_sitbout_dur)/60
as P4_short_sitbout_dur, 
sum(P4_Sit)/60
 
as P4_Sit, 
sum(P4_Stand)/60 
as P4_Stand, 
sum(P4_LPA)/60
 
as P4_LPA, 
sum(P4_MVPA)/60 
as P4_MVPA, 
sum(P4_step_min)/60
as P4_step_min, 
sum(P4_step_ct)
as 
P4_step_ct, 
sum(P4_step00_05)/60
as 
P4_step00_05, 
sum(P4_step05_10)/60
as 
P4_step05_10, 
sum(P4_step10_15)/60
as 
P4_step10_15, 
sum(P4_step15_30)/60
as 
P4_step15_30, 
sum(P4_step30_60)/60
as 
P4_step30_60, 
sum(P4_step60_90)/60
as 
P4_step60_90, 
sum(P4_step90_120)/60
as 
P4_step90_120, 
sum(P4_step120_up)/60
as 
P4_step120_up, 
sum(P5)/60
 
as P5_min, 
sum(P5_sitstand) 
as P5_Sitstand, 
round(sum(P5_long_sitbout_ct),1) 
as P5_long_sitbout_ct, 
sum(P5_long_sitbout_dur)/60 
as P5_long_sitbout_dur, 
round(sum(P5_short_sitbout_ct),1)
as P5_short_sitbout_ct, 
sum(P5_short_sitbout_dur)/60
as P5_short_sitbout_dur, 
sum(P5_Sit)/60
 
as P5_Sit, 
43 

SMW Study Manual of Procedures 
 
 
  
 
sum(P5_Stand)/60 
as P5_Stand, 
sum(P5_LPA)/60
 
as P5_LPA, 
sum(P5_MVPA)/60 
as P5_MVPA, 
sum(P5_step_min)/60
as P5_step_min, 
sum(P5_step_ct)
as 
P5_step_ct, 
sum(P5_step00_05)/60
as 
P5_step00_05, 
sum(P5_step05_10)/60
as 
P5_step05_10, 
sum(P5_step10_15)/60
as 
P5_step10_15, 
sum(P5_step15_30)/60
as 
P5_step15_30, 
sum(P5_step30_60)/60
as 
P5_step30_60, 
sum(P5_step60_90)/60
as 
P5_step60_90, 
sum(P5_step90_120)/60
as 
P5_step90_120, 
sum(P5_step120_up)/60
as 
P5_step120_up 
 
  FROM cadence2 
  GROUP BY ID, Mtime, Date; 
QUIT; 
 
Data sittostand2; Merge sittostand Ap_var; 
by ID; 
Run; 
 
 
PROC APPEND DATA=sittostand2 out=iso.REPORT_FINAL FORCE; 
RUN; 
%end; 
/*proc Datasets lib=work nolist kill;*/ 
/*
quit;*/ 
/**/ 
/*
run;*/ 
%MEND APimport; 
 
 
*nominate folder to find the events files, followed by \, such as; 
44 

SMW Study Manual of Procedures 
 
 
  
 
%let dir = X:\Buman Lab\Stand and Move 
ASU_UMN\Data\ActivPAL\ISO_TEST\SAS_FILES\taggedfiles\T1; 
%APimport; 
 
proc printto; 
run; 
 
  %put END TIME: %sysfunc(datetime(),datetime14.); 
  %put PROCESSING TIME: 
%sysfunc(putn(%sysevalf(%sysfunc(TIME())-&datetime_start.),mmss.)) (mm:ss) ; 
 
 
  
 
Proc SQL; 
Create table Activpal as 
select a.*, 
   b.workday 
 
From iso.Report_Final as a 
Left join track.masterlogs2 as b 
ON a.ID=b.ID and a.date=b.date 
Order by a.ID, a.date; 
Quit; 
 
Data iso.AP_Final; 
set Activpal; 
 
 
 
if workday=0 and p1_min<600 then valid_p1=0; 
if workday=0 and p1_min>=600 then valid_p1=1; 
if workday=1 and p2_min<240 then valid_p2=0; 
if workday=1 and p2_min>=240 then valid_p2=1; 
if workday=1 and p3_min<240 then valid_p3=0; 
if workday=1 and p3_min>=240 then valid_p3=1; 
 
 
run; 
 
 
 
 
45