<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE article PUBLIC "-//NLM//DTD Journal Publishing DTD v2.0 20040830//EN" "http://dtd.nlm.nih.gov/publishing/2.0/journalpublishing.dtd">
<article xmlns:xlink="http://www.w3.org/1999/xlink" article-type="research-article" dtd-version="2.0">
  <front>
    <journal-meta>
      <journal-id journal-id-type="publisher-id">JFR</journal-id>
      <journal-id journal-id-type="nlm-ta">JMIR Form Res</journal-id>
      <journal-title>JMIR Formative Research</journal-title>
      <issn pub-type="epub">2561-326X</issn>
      <publisher>
        <publisher-name>JMIR Publications</publisher-name>
        <publisher-loc>Toronto, Canada</publisher-loc>
      </publisher>
    </journal-meta>
    <article-meta>
      <article-id pub-id-type="publisher-id">v5i3e17993</article-id>
      <article-id pub-id-type="pmid">33650981</article-id>
      <article-id pub-id-type="doi">10.2196/17993</article-id>
      <article-categories>
        <subj-group subj-group-type="heading">
          <subject>Original Paper</subject>
        </subj-group>
        <subj-group subj-group-type="article-type">
          <subject>Original Paper</subject>
        </subj-group>
      </article-categories>
      <title-group>
        <article-title>A Rest Quality Metric Using a Cluster-Based Analysis of Accelerometer Data and Correlation With Digital Medicine Ingestion Data: Algorithm Development</article-title>
      </title-group>
      <contrib-group>
        <contrib contrib-type="editor">
          <name>
            <surname>Eysenbach</surname>
            <given-names>Gunther</given-names>
          </name>
        </contrib>
      </contrib-group>
      <contrib-group>
        <contrib contrib-type="reviewer">
          <name>
            <surname>Vanegas</surname>
            <given-names>Erik</given-names>
          </name>
        </contrib>
        <contrib contrib-type="reviewer">
          <name>
            <surname>Patel</surname>
            <given-names>Shyamal</given-names>
          </name>
        </contrib>
      </contrib-group>
      <contrib-group>
        <contrib id="contrib1" contrib-type="author">
          <name name-style="western">
            <surname>Heidary</surname>
            <given-names>Zahra</given-names>
          </name>
          <degrees>PhD</degrees>
          <xref rid="aff1" ref-type="aff">1</xref>
          <ext-link ext-link-type="orcid">https://orcid.org/0000-0002-5602-7523</ext-link>
        </contrib>
        <contrib id="contrib2" contrib-type="author" corresp="yes">
          <name name-style="western">
            <surname>Cochran</surname>
            <given-names>Jeffrey M</given-names>
          </name>
          <degrees>PhD</degrees>
          <xref rid="aff1" ref-type="aff">1</xref>
          <address>
            <institution>Otsuka Pharmaceutical Development &#38; Commercialization, Inc</institution>
            <addr-line>508 Carnegie Center Dr</addr-line>
            <addr-line>Princeton, NJ, 08540</addr-line>
            <country>United States</country>
            <phone>1 609 524 6788</phone>
            <email>jeffrey.cochran@otsuka-us.com</email>
          </address>
          <ext-link ext-link-type="orcid">https://orcid.org/0000-0003-4291-1796</ext-link>
        </contrib>
        <contrib id="contrib3" contrib-type="author">
          <name name-style="western">
            <surname>Peters-Strickland</surname>
            <given-names>Timothy</given-names>
          </name>
          <degrees>MD</degrees>
          <xref rid="aff1" ref-type="aff">1</xref>
          <ext-link ext-link-type="orcid">https://orcid.org/0000-0001-9985-6711</ext-link>
        </contrib>
        <contrib id="contrib4" contrib-type="author">
          <name name-style="western">
            <surname>Knights</surname>
            <given-names>Jonathan</given-names>
          </name>
          <degrees>PhD</degrees>
          <xref rid="aff1" ref-type="aff">1</xref>
          <ext-link ext-link-type="orcid">https://orcid.org/0000-0002-7032-4954</ext-link>
        </contrib>
      </contrib-group>
      <aff id="aff1">
        <label>1</label>
        <institution>Otsuka Pharmaceutical Development &#38; Commercialization, Inc</institution>
        <addr-line>Princeton, NJ</addr-line>
        <country>United States</country>
      </aff>
      <author-notes>
        <corresp>Corresponding Author: Jeffrey M Cochran <email>jeffrey.cochran@otsuka-us.com</email></corresp>
      </author-notes>
      <pub-date pub-type="collection">
        <month>3</month>
        <year>2021</year>
      </pub-date>
      <pub-date pub-type="epub">
        <day>2</day>
        <month>3</month>
        <year>2021</year>
      </pub-date>
      <volume>5</volume>
      <issue>3</issue>
      <elocation-id>e17993</elocation-id>
      <history>
        <date date-type="received">
          <day>28</day>
          <month>1</month>
          <year>2020</year>
        </date>
        <date date-type="rev-request">
          <day>31</day>
          <month>8</month>
          <year>2020</year>
        </date>
        <date date-type="rev-recd">
          <day>14</day>
          <month>10</month>
          <year>2020</year>
        </date>
        <date date-type="accepted">
          <day>17</day>
          <month>1</month>
          <year>2021</year>
        </date>
      </history>
      <copyright-statement>©Zahra Heidary, Jeffrey M Cochran, Timothy Peters-Strickland, Jonathan Knights. Originally published in JMIR Formative Research (http://formative.jmir.org), 02.03.2021.</copyright-statement>
      <copyright-year>2021</copyright-year>
      <license license-type="open-access" xlink:href="https://creativecommons.org/licenses/by/4.0/">
        <p>This is an open-access article distributed under the terms of the Creative Commons Attribution License (https://creativecommons.org/licenses/by/4.0/), which permits unrestricted use, distribution, and reproduction in any medium, provided the original work, first published in JMIR Formative Research, is properly cited. The complete bibliographic information, a link to the original publication on http://formative.jmir.org, as well as this copyright and license information must be included.</p>
      </license>
      <self-uri xlink:href="https://formative.jmir.org/2021/3/e17993" xlink:type="simple"/>
      <abstract>
        <sec sec-type="background">
          <title>Background</title>
          <p>Adherence to medication regimens and patient rest are two important factors in the well-being of patients with serious mental illness. Both of these behaviors are traditionally difficult to record objectively in unsupervised populations.</p>
        </sec>
        <sec sec-type="objective">
          <title>Objective</title>
          <p>A digital medicine system that provides objective time-stamped medication ingestion records was used by patients with serious mental illness. Accelerometer data from the digital medicine system was used to assess rest quality and thus allow for investigation into correlations between rest and medication ingestion.</p>
        </sec>
        <sec sec-type="methods">
          <title>Methods</title>
          <p>Longest daily rest periods were identified and then evaluated using a k-means clustering algorithm and distance metric to quantify the relative quality of patient rest during these periods. This accelerometer-derived quality-of-rest metric, along with other accepted metrics of rest quality, such as duration and start time of the longest rest periods, was compared to the objective medication ingestion records. Overall medication adherence classification based on rest features was not performed due to a lack of patients with poor adherence in the sample population.</p>
        </sec>
        <sec sec-type="results">
          <title>Results</title>
          <p>Explorations of the relationship between these rest metrics and ingestion did seem to indicate that patients with poor adherence experienced relatively low quality of rest; however, patients with better adherence did not necessarily exhibit consistent rest quality. This sample did not contain sufficient patients with poor adherence to draw more robust correlations between rest quality and ingestion behavior. The correlation of temporal outliers in these rest metrics with daily outliers in ingestion time was also explored.</p>
        </sec>
        <sec sec-type="conclusions">
          <title>Conclusions</title>
          <p>This result demonstrates the ability of digital medicine systems to quantify patient rest quality, providing a framework for further work to expand the participant population, compare these rest metrics to gold-standard sleep measurements, and correlate these digital medicine biomarkers with objective medication ingestion data.</p>
        </sec>
      </abstract>
      <kwd-group>
        <kwd>serious mental illness</kwd>
        <kwd>rest quality</kwd>
        <kwd>actimetry</kwd>
        <kwd>behavioral health</kwd>
        <kwd>digital medicine</kwd>
        <kwd>accelerometer</kwd>
        <kwd>medication adherence</kwd>
      </kwd-group>
    </article-meta>
  </front>
  <body>
    <sec sec-type="introduction">
      <title>Introduction</title>
      <p>Lack of adherence to medication regimens is a significant public health issue that contributes to increased health care utilization [<xref ref-type="bibr" rid="ref1">1</xref>,<xref ref-type="bibr" rid="ref2">2</xref>]. Adherence is of particular concern in patients with serious mental illness (SMI), including schizophrenia, bipolar disorder, and major depressive disorder, with estimates of nonadherence as high as 60% [<xref ref-type="bibr" rid="ref1">1</xref>,<xref ref-type="bibr" rid="ref3">3</xref>]. Within this population, effective pharmacotherapy is critical for mitigating the risk of serious adverse events, such as psychosis, symptom recurrence, poor social functions, hospitalizations, and suicide attempts [<xref ref-type="bibr" rid="ref4">4</xref>,<xref ref-type="bibr" rid="ref5">5</xref>]. Conventional methods of inferring medication adherence to pharmacotherapy have limited utility, as they are typically either subjective or acquire only surrogate markers of medication ingestion [<xref ref-type="bibr" rid="ref6">6</xref>]. Thus, there is a clear, unmet clinical need for adherence monitoring that digital medicine is ideally suited to address. In this context, digital medicine refers to a system that combines an active pharmaceutical and an ingestible sensor that communicates to a mobile app or web-based application to record that patients have taken their medication at a specific time [<xref ref-type="bibr" rid="ref7">7</xref>], providing an objective measure of ingestion.</p>
      <p>Another potentially useful biomarker for patients with SMI is disruption in sleep [<xref ref-type="bibr" rid="ref8">8</xref>,<xref ref-type="bibr" rid="ref9">9</xref>] and activity patterns [<xref ref-type="bibr" rid="ref10">10</xref>,<xref ref-type="bibr" rid="ref11">11</xref>], both of which have been significantly linked to mental health. The digital medicine system (DMS) used here noninvasively records activity-related parameters such as step count, physical patient orientation, and heart rate. Due to battery optimization for ingestion monitoring, the DMS does not record these metrics at a sufficiently high temporal resolution to perform common sleep identification techniques, such as heart rate variability analysis [<xref ref-type="bibr" rid="ref12">12</xref>,<xref ref-type="bibr" rid="ref13">13</xref>]. However, accelerometer-based actigraphy has been extensively validated against gold-standard sleep measurements like polysomnography [<xref ref-type="bibr" rid="ref10">10</xref>,<xref ref-type="bibr" rid="ref14">14</xref>-<xref ref-type="bibr" rid="ref17">17</xref>]; thus, the available data from the DMS can noninvasively provide valuable insight into patterns of rest and activity in patients with SMI at the currently available temporal resolution and battery consumption while simultaneously recording previously unavailable objective medication ingestion data with a single device in a natural care setting.</p>
      <p>Thus, the goals of this study were twofold. First, 3-axis accelerometer data from the DMS and a novel analysis algorithm were used to identify and analyze patients’ longest period of rest during each day they were on the system. The relative quality of these rest periods was quantified using a modified k-means clustering algorithm of accelerometer-derived features; previous actimetry research has correlated these types of activity features with wakefulness in sleep studies [<xref ref-type="bibr" rid="ref14">14</xref>-<xref ref-type="bibr" rid="ref17">17</xref>]. These activity features should thus also be correlated with measurements of rest quality as defined by the National Sleep Foundation, such as sleep efficiency and wake after sleep onset [<xref ref-type="bibr" rid="ref18">18</xref>]. The stability of the rest period duration and consistency of the rest period starting time were also assessed across all days for each patient, as measurements of rest duration [<xref ref-type="bibr" rid="ref18">18</xref>-<xref ref-type="bibr" rid="ref20">20</xref>] and starting time [<xref ref-type="bibr" rid="ref9">9</xref>,<xref ref-type="bibr" rid="ref10">10</xref>,<xref ref-type="bibr" rid="ref18">18</xref>] have also been correlated with quality of rest. Finally, preliminary correlations between rest and medication ingestion records were explored.</p>
    </sec>
    <sec sec-type="methods">
      <title>Methods</title>
      <sec>
        <title>DMS</title>
        <p>The DMS used here has been described previously [<xref ref-type="bibr" rid="ref21">21</xref>]. Briefly, the DMS is a combination of an ingestible sensor embedded in an active pharmaceutical and a sensor patch that is attached to the torso, which records ingestion events and measures activity via a 3-axis accelerometer and an estimated sample heart rate with a single-lead electrocardiogram (ECG). The patch, which the patient must apply, also contains a temperature sensor and an impedance sensor and is designed to be worn for 7 days. The collected data is uploaded and stored in the cloud via a mobile phone app that also displays a patient dashboard (see <xref rid="figure1" ref-type="fig">Figure 1</xref>).</p>
        <fig id="figure1" position="float">
          <label>Figure 1</label>
          <caption>
            <p>Schematic of the DMS. The DMS consists of an ingestible sensor embedded within an aripiprazole tablet. Upon ingestion, this sensor communicates with a patient-worn patch, which records the ingestion event and provides measures of activity and heart rate using an accelerometer and ECG, respectively, as well as temperature and impedance across the patch. The patch then communicates all data to a smartphone app, which stores the data on a secure cloud server that can be accessed by patients or designated caregivers via a mobile or web-based dashboard. DM: digital medicine; DMS: digital medicine system; ECG: electrocardiogram; HCP: health care provider; IEM: ingestible event marker.</p>
          </caption>
          <graphic xlink:href="formative_v5i3e17993_fig1.png" alt-version="no" mimetype="image" position="float" xlink:type="simple"/>
        </fig>
        <p>This system is designed for monitoring medication ingestion in patients with SMI. Each measured ingestion event is recorded with a timestamp. The accelerometer data are measured across a 14-second sample every minute, and a built-in algorithm converts the raw data to a step count, mean acceleration along all 3 axes (a<sub>x</sub>, a<sub>y</sub>, a<sub>z</sub>), and mean body orientation angle (θ), which are read out at 1-minute intervals. When the patch initially observes activity, the accelerometer is calibrated such that the x-axis is approximately oriented along the longitudinal axis of the body regardless of the orientation of the patch. The ECG provides the mean heart rate every 5 minutes.</p>
      </sec>
      <sec>
        <title>Study Population</title>
        <p>The population used in this analysis comprised 102 participants enrolled across 2 clinical studies (NCT02219009, NCT02722967) [<xref ref-type="bibr" rid="ref22">22</xref>,<xref ref-type="bibr" rid="ref23">23</xref>]. <xref ref-type="table" rid="table1">Table 1</xref> contains the demographic and clinical characteristics for these patients. All participants were previously diagnosed with schizophrenia, bipolar disorder, or major depressive disorder and were regularly receiving once-daily doses of the atypical antipsychotic aripiprazole. For the duration of the study, patients received the digital version of aripiprazole. Both studies were reviewed and approved by the appropriate institutional review boards, and patients were all deemed capable of using the DMS and provided signed informed consent. To ensure the reliability of individual rest metrics, the data set presented here excludes 14 additional patients enrolled in the studies that did not have at least 7 days of recorded data from the DMS patch.</p>
        <table-wrap position="float" id="table1">
          <label>Table 1</label>
          <caption>
            <p>Demographic and clinical characteristics of the sample population.</p>
          </caption>
          <table border="1" rules="groups" cellpadding="5" frame="hsides" width="1000" cellspacing="0">
            <col width="30"/>
            <col width="500"/>
            <col width="470"/>
            <thead>
              <tr valign="top">
                <td colspan="2">Characteristic</td>
                <td>Values (N=102)</td>
              </tr>
            </thead>
            <tbody>
              <tr valign="top">
                <td colspan="3">
                  <bold>Gender, n (%)</bold>
                </td>
              </tr>
              <tr valign="top">
                <td/>
                <td>Female</td>
                <td>40 (39)</td>
              </tr>
              <tr valign="top">
                <td/>
                <td>Male</td>
                <td>62 (61)</td>
              </tr>
              <tr valign="top">
                <td colspan="2">Age (years), mean (SD)</td>
                <td>45.9 (11.3)</td>
              </tr>
              <tr valign="top">
                <td colspan="2">
                  <bold>Race, n (%)</bold>
                </td>
                <td/>
              </tr>
              <tr valign="top">
                <td/>
                <td>Black or African American</td>
                <td>56 (55)</td>
              </tr>
              <tr valign="top">
                <td/>
                <td>White</td>
                <td>39 (38)</td>
              </tr>
              <tr valign="top">
                <td/>
                <td>Asian</td>
                <td>5 (5)</td>
              </tr>
              <tr valign="top">
                <td/>
                <td>Other</td>
                <td>2 (2)</td>
              </tr>
              <tr valign="top">
                <td colspan="2">
                  <bold>Ethnicity, n (%)</bold>
                </td>
                <td/>
              </tr>
              <tr valign="top">
                <td/>
                <td>Hispanic or Latino</td>
                <td>5 (5)</td>
              </tr>
              <tr valign="top">
                <td/>
                <td>Not Hispanic or Latino</td>
                <td>97 (95)</td>
              </tr>
              <tr valign="top">
                <td colspan="2">
                  <bold>Diagnosis, n (%)</bold>
                </td>
                <td/>
              </tr>
              <tr valign="top">
                <td/>
                <td>Schizophrenia</td>
                <td>71 (70)</td>
              </tr>
              <tr valign="top">
                <td/>
                <td>Bipolar 1 disorder</td>
                <td>21 (21)</td>
              </tr>
              <tr valign="top">
                <td/>
                <td>Major depressive disorder</td>
                <td>10 (10)</td>
              </tr>
              <tr valign="top">
                <td colspan="3">
                  <bold>Observed ingestion (%)</bold>
                </td>
              </tr>
              <tr valign="top">
                <td/>
                <td>Median (IQR)</td>
                <td>71.3 (28.9)</td>
              </tr>
              <tr valign="top">
                <td/>
                <td>Range</td>
                <td>14.8-96.6</td>
              </tr>
              <tr valign="top">
                <td colspan="3">
                  <bold>Observed ingestion duration (days)</bold>
                </td>
              </tr>
              <tr valign="top">
                <td/>
                <td>Median (IQR)</td>
                <td>54 (14)</td>
              </tr>
              <tr valign="top">
                <td/>
                <td>Range</td>
                <td>7-64</td>
              </tr>
            </tbody>
          </table>
        </table-wrap>
      </sec>
      <sec>
        <title>Definition of Longest Rest Periods</title>
        <p>The DMS patch provides step count and posture angle measurements from the accelerometer every minute and the mean heart rate from the ECG every 5 minutes. These measurements were partitioned into 15-minute nonoverlapping time intervals, which were assessed for data quality. A 15-minute interval was considered analyzable if all 3 of the following conditions were met: (1) there was no point in the interval at which the patch was pairing with the mobile app, (2) there were at least 10 collected accelerometer measurements within the interval, (3) there were at least 2 ECG records within the window.</p>
        <p>Any intervals that failed 1 or more of these criteria were labelled as missing, ensuring that intervals were only used if they contained sufficient reliable patch data.</p>
        <p>For analyzable intervals, each 1-minute accelerometer record was then examined, and if the posture angle of that record was less than 30° away from horizontal, it was classified as rest.</p>
        <p>Based on these accelerometer measurement labels, the analyzable 15-minute intervals were then classified as either rest (if greater than 70% of the records in that interval were classified as rest) or active (if the rest criterion was not met).</p>
        <p>These 15-minute windows were then used to define each patient’s longest period of rest for a given day. The first step was to identify the longest period of consecutive rest intervals that did not contain any active or missing intervals; however, this simple longest continuous rest period (LCRP) was likely an insufficient representation of the patient’s true longest rest period (LRP). For one, intervals labeled as missing could artificially shorten these periods. Additionally, a single active interval is not necessarily indicative of the end of that rest period; for example, sleep is often interrupted by a short period of activity. Thus, an algorithm was used, as illustrated in <xref rid="figure2" ref-type="fig">Figure 2</xref>, to extend these longest periods of rest to more accurately capture the duration of each rest period.</p>
        <fig id="figure2" position="float">
          <label>Figure 2</label>
          <caption>
            <p>Flowchart for finding the longest rest period. The first step in defining the longest rest period for a given day is to locate the LCRP (ie, the longest duration of consecutive 15-minute rest windows without any active or missing windows). The algorithm described in the flowchart is then used to determine if nearby windows are added to the LCRP.</p>
          </caption>
          <graphic xlink:href="formative_v5i3e17993_fig2.png" alt-version="no" mimetype="image" position="float" xlink:type="simple"/>
        </fig>
        <p>Briefly, sequences of continuous rest windows that were within 5 intervals of either the beginning or end of the initial longest LCRP were added to the LRP if the intervening intervals were all missing (ie, none of them were labeled as active). If exactly 1 active interval was present between the longest interval and another rest interval in any of the 5-interval windows, only sequences that contained 4 or more consecutive rest intervals were added to the LRP. If more than 2 intervals between the original period and the additional rest period were labeled as active, the new rest period was not added to the LRP. <xref rid="figure3" ref-type="fig">Figure 3</xref> provides the 15-minute interval rest designations and identified LRPs for a single patient across all days.</p>
        <fig id="figure3" position="float">
          <label>Figure 3</label>
          <caption>
            <p>Rest state interval designations and longest rest periods for a single subject. (A) All 15-minute windows were classified as either rest, active, or missing, according to the procedure discussed in the Methods section. (B) The longest rest period for each day was identified using the procedure shown in <xref rid="figure2" ref-type="fig">Figure 2</xref>.</p>
          </caption>
          <graphic xlink:href="formative_v5i3e17993_fig3.png" alt-version="no" mimetype="image" position="float" xlink:type="simple"/>
        </fig>
      </sec>
      <sec>
        <title>Rest Features and Metrics</title>
        <p>With the LRP identified for each patient on each day, features were then developed to quantify the relative quality of rest within these intervals. For this purpose, 3-minute rolling windows of the accelerometer data, consisting of 3D acceleration (a<sub>x</sub>, a<sub>y</sub>, a<sub>z</sub>), posture angle (θ), and step count, were used, resulting in 13 individual data points for each 15-minute window. In all, 35 features (see <xref ref-type="supplementary-material" rid="app1">Multimedia Appendix 1</xref> Table S1) were tested, and 4 features were chosen via a feature agglomeration technique which is similar to agglomeration clustering but uses recursive merging of features instead of samples [<xref ref-type="bibr" rid="ref24">24</xref>]. The feature agglomeration clustering algorithm was run independently for each patient in the data set, and 4 features that were consistently grouped into separate clusters across all patients were chosen.</p>
        <p>These 4 features were then normalized to their respective ranges and used in a k-means clustering algorithm with 2 groups (k=2); 2 groups were purposely chosen to identify both a rest-reference (RR) cluster, in which the mean posture angle was closer to a horizontal position, and a deviation-from-rest (DFR) cluster. A Euclidean distance across the 4D feature space quantified the deviation from the rest cluster for each data point; because the 4 individual features used in this model are associated with rest quality, this distance can be interpreted as a metric for the quality of rest. For all points in the DFR cluster, the distance was calculated from that point to the center of the RR cluster in the 4D feature space. All points that were designated as part of the RR cluster were given a distance measure of 0; thus, low values indicated higher rest quality, while higher values indicated poorer rest quality. <xref rid="figure4" ref-type="fig">Figure 4</xref> shows a sample patient cluster diagram with the Euclidean distance calculation.</p>
        <fig id="figure4" position="float">
          <label>Figure 4</label>
          <caption>
            <p>K-means clustering and relative rest quality in a single patient for 2 of the 4 features. (A) K-means clustering diagram plotted across 2 dimensions representing 2 of the 4 features in the clustering algorithm. All data points for each patient were classified using 2 clusters defined as the rest reference cluster (in blue) and the deviation from rest cluster (in orange). (B) Relative rest quality distance metric calculation. A quality of rest metric, represented here by variations in color, was also determined for each data point by calculating the Euclidean distance of the point from the center of the rest reference cluster. All points within the rest reference cluster were assigned a distance of 0. Note that the rest quality color does not have a perfect correlation with apparent distance on this 2D graph because the Euclidean distance is calculated across all 4 feature dimensions.</p>
          </caption>
          <graphic xlink:href="formative_v5i3e17993_fig4.png" alt-version="no" mimetype="image" position="float" xlink:type="simple"/>
        </fig>
        <p>Within each 15-minute window, the distance measurements of all points were then summed to create a single rest quality metric. <xref rid="figure5" ref-type="fig">Figure 5</xref>A displays these LRPs and the calculated rest quality in each window for a single patient. The relative rest quality for each LRP was defined as the mean of the relative rest quality in all 15-minute windows within that LRP. Finally, for a given patient, the mean and SD of the relative rest quality of the LRP across all days were used to transform the rest quality metric for each LRP into a <italic>z</italic> score.</p>
        <fig id="figure5" position="float">
          <label>Figure 5</label>
          <caption>
            <p>Daily relative rest quality and ingestion for a single patient. (A) The longest rest period for each day. Each bar represents the time windows that constitute the longest rest period for a given day. The color of each 15-minute interval within each bar represents the rest quality metric for that window. (B) Ingestion times for each day. Recorded ingestion events are marked with a red circle, missed ingestions are marked with an empty black circle, and the mean ingestion time across all days is represented by the horizontal line. (C) Ingestion and composite rest z scores. The composite rest z score (in orange), which is the sum of the rest quality, starting time, and duration z score, and the ingestion time z score (in blue) are plotted across all days for the same patient. We searched for data points where outliers in the composite rest z score occurred near the same day as a corresponding outlier in the ingestion time z score (eg, on day 15). Note that days without recorded patch data were excluded from the analysis.</p>
          </caption>
          <graphic xlink:href="formative_v5i3e17993_fig5.png" alt-version="no" mimetype="image" position="float" xlink:type="simple"/>
        </fig>
        <p>The <italic>z</italic> score metrics of the stability of the LRP duration and of the consistency of the LRP starting time were similarly calculated across all days for each participant. A composite rest <italic>z</italic> score for each LRP could then be calculated by summing the absolute values of the quality, stability, and consistency <italic>z</italic> score measurements.</p>
      </sec>
      <sec>
        <title>Ingestion Metrics</title>
        <p>Patient medication ingestion was quantified with 2 metrics. The first was the patient’s overall observed ingestion rate, calculated as the number of days during which an ingested dose was recorded divided by the expected number of ingested doses across the entire regimen, which was defined as the time from the first day with recorded patch data to the last day with an ingestion record (see <xref ref-type="table" rid="table1">Table 1</xref> and <xref rid="figure6" ref-type="fig">Figure 6</xref>A). The second metric was a <italic>z</italic> score of daily ingestion time using the mean and SD of ingestion time across all days for a given patient. These ingestion time markers were compared to the previously described rest metrics by searching for single-day outliers in the rest <italic>z</italic> score within 1 day of similar outliers in the ingestion time <italic>z</italic> score (see <xref rid="figure5" ref-type="fig">Figure 5</xref>B).</p>
        <fig id="figure6" position="float">
          <label>Figure 6</label>
          <caption>
            <p>Ingestion rate and composite rest score. (A) Distribution of ingestion rate by patient. Ingestion rate was defined as the fraction of days that contained an ingestion event. Notice that there are relatively few patients with a poor ingestion rate, which made developing robust classification algorithms difficult. (B) Distribution of mean composite rest score across all days for each patient. (C) Ingestion rate versus mean composite rest score. There is no clear correlation between the ingestion rate and the composite rest score. Note, however, that there are no patients with very poor adherence (ie, an ingestion rate less than 0.5) that have a low composite rest score, which would be indicative of better rest.</p>
          </caption>
          <graphic xlink:href="formative_v5i3e17993_fig6.png" alt-version="no" mimetype="image" position="float" xlink:type="simple"/>
        </fig>
      </sec>
    </sec>
    <sec sec-type="results">
      <title>Results</title>
      <p>A total of 35 features, calculated across 3-minute rolling windows, were explored to characterize rest in this population of 102 patients with SMI. There were no significant observed differences across the 3 indications in this population (ie, schizophrenia, bipolar disorder, or major depressive disorder) for any of the forthcoming metrics. The 4 features chosen by the aforementioned agglomeration technique were the mean of the circular deviation in the y–z acceleration plane, the mean of the posture angle, the mean of the 3D acceleration norm, and the SD of the x acceleration (see <xref ref-type="table" rid="table2">Table 2</xref>), which were all calculated across 3-minute rolling windows. The circular deviation in the y–z acceleration, which represents the degree to which the combination of the y and z components of the acceleration differ from the full 1-g resting acceleration, was particularly successful at differentiating rest windows from those designated as active (see <xref rid="figure7" ref-type="fig">Figure 7</xref>).</p>
      <table-wrap position="float" id="table2">
        <label>Table 2</label>
        <caption>
          <p>Rest features.</p>
        </caption>
        <table border="1" rules="groups" cellpadding="5" frame="hsides" width="1000" cellspacing="0">
          <col width="500"/>
          <col width="500"/>
          <thead>
            <tr valign="top">
              <td>Name</td>
              <td>Definition</td>
            </tr>
          </thead>
          <tbody>
            <tr valign="top">
              <td>y–z acceleration circular deviation (mean)</td>
              <td>
                <inline-graphic xlink:href="formative_v5i3e17993_fig8.png" xlink:type="simple" mimetype="image"/>
              </td>
            </tr>
            <tr valign="top">
              <td>Posture angle (mean)</td>
              <td>
                <inline-graphic xlink:href="formative_v5i3e17993_fig9.png" xlink:type="simple" mimetype="image"/>
              </td>
            </tr>
            <tr valign="top">
              <td>Acceleration norm (mean)</td>
              <td>
                <inline-graphic xlink:href="formative_v5i3e17993_fig10.png" xlink:type="simple" mimetype="image"/>
              </td>
            </tr>
            <tr valign="top">
              <td>x acceleration (SD)</td>
              <td>σ(α<sub>χ</sub>)</td>
            </tr>
          </tbody>
        </table>
      </table-wrap>
      <fig id="figure7" position="float">
        <label>Figure 7</label>
        <caption>
          <p>The y–z acceleration circular deviation. (A) Mean z-axis acceleration versus mean y-axis acceleration for all data points in units of g. (B) Mean z-axis acceleration versus mean y-axis acceleration for all rest data points in units of g. Note that, for the remaining data points, the y-axis and z-axis accelerations tend to cluster around a circle with radius 1. Thus, the circular deviation in the y–z plane is an effective feature for differentiating rest from nonrest.</p>
        </caption>
        <graphic xlink:href="formative_v5i3e17993_fig7.png" alt-version="no" mimetype="image" position="float" xlink:type="simple"/>
      </fig>
      <p>These 4 features were used in the k-means clustering algorithm to create the RR and DFR groups as well as the relative rest quality distance metric (see <xref rid="figure4" ref-type="fig">Figure 4</xref>). The distance metrics for each 3-minute window were summed over each 15-minute interval, and the mean across the LRP was calculated for each patient on each day, providing a metric of rest quality throughout each LRP (see <xref rid="figure5" ref-type="fig">Figure 5</xref>A). Note that the value of this metric is inversely related to the quality of rest. The start time and duration of each LRP was also calculated. The <italic>z</italic> scores for this rest quality, along with the start time stability and duration of the LRPs, were calculated with respect to the mean and SD of all LRPs within a given patient’s data set. A composite rest score was then defined by summing the absolute value of the 3 <italic>z</italic> score metrics for each LRP. This composite score was thus a measure of the combined magnitude of deviation from a patient’s typical pattern for these 3 rest metrics. The distribution of the mean value of this composite rest score for all patients can be seen in <xref rid="figure6" ref-type="fig">Figure 6</xref>B.</p>
      <p>These rest metrics were then compared to the overall ingestion rate for each patient, which was defined as the fraction of days a patient was using the DMS that contained an ingestion event. This study population had a notable lack of patients with poor adherence; for example, only 15% of patients had an observed ingestion percentage of 50% or less (see <xref rid="figure6" ref-type="fig">Figure 6</xref>A). Patients with lower adherence did appear to have a relatively low quality of rest as quantified by the composite rest metric; there were no patients with an ingestion rate equal to or less than 50% that had a low composite rest <italic>z</italic> score (see <xref rid="figure6" ref-type="fig">Figure 6</xref>C), which signifies better rest. However, the asymmetry in high versus low adherence and the small sample size precluded statistically significant conclusions about the overall correlation between low adherence and rest quality.</p>
      <p>We were, however, able to explore correlations between daily outliers in the composite rest score with outliers in ingestion time that occurred within 1 day of the rest outlier. One such example can be seen in <xref rid="figure5" ref-type="fig">Figure 5</xref>C. Although this sample does not contain sufficient events of this type to develop quantitative conclusions, this could be a potentially useful marker for identifying rest-related adherence risk factors in the time domain.</p>
    </sec>
    <sec sec-type="discussion">
      <title>Discussion</title>
      <sec>
        <title>Principal Results</title>
        <p>This DMS combines objective, time-stamped records of medication ingestion with noninvasive physiological markers of activity and heart rate in patients with SMI. It thus provides a unique opportunity to measure the quality of rest and explore correlations between rest and objective medication ingestion data. Here, algorithms were developed to both identify rest periods and quantify the relative quality of the rest within these periods using only the data available from the DMS without increasing battery consumption.</p>
        <p>The LRP identification algorithm used accelerometer data, as provided by the DMS, to first find 15-minute windows that could be classified as rest and then to combine these windows to find a daily period of longest rest. Thirty-five potential accelerometer-measured features were explored, and the four best were selected via a feature agglomeration methodology (see <xref ref-type="table" rid="table2">Table 2</xref>). These features included the acceleration norm and SD of the x-axis acceleration, with larger values associated with greater activity. Another feature was the posture angle, with 0 corresponding to a patient lying down and deviations representing a greater degree of uprightness. The most novel feature was the circular deviation of the y–z acceleration, which is also correlated with rest. If a patient were lying still and perfectly horizontally, the x-axis (ie, head-to-toe) acceleration would be small, and thus the total y–z magnitude of acceleration would be near 1. This would be an example of high-quality rest and result in a y–z circular deviation near 0 (see <xref rid="figure4" ref-type="fig">Figure 4</xref>). Larger y–z circular deviations can thus be interpreted as an indicator of decreased rest quality.</p>
        <p>These 4 features served as the input for an unsupervised k-means clustering algorithm (k=2) that included a 4D Euclidean distance metric for each data point to the center of the RR cluster, which was then applied to all windows in each LRP. This distance metric thus could quantify the degree to which a patient deviates from the RR cluster. Because each of the 4 features that constitute this distance can individually be correlated with rest quality, this distance metric can thus be interpreted as a deviation from quality rest. All patients used in this clustering algorithm were examined to ensure that their data points were not well represented by a single rest cluster. It should be noted that other populations could contain such a patient, which could minimize the contrast between the RR and DFR clusters. This algorithm demonstrates the ability of the DMS to quantify patient-specific rest quality despite the relatively low temporal resolution of the available accelerometer data due to the need to prioritize power consumption of the ingestion detection module. Thus, rest quality can be quantified for patients already engaged with the DMS without the use of an additional activity tracker that would require further patient engagement.</p>
        <p>Exploratory correlations between the calculated rest metrics and ingestion data were hindered by the sample’s asymmetry in medication adherence, in which few patients exhibited poor ingestion rates. Thus, no statistically significant conclusions about rest and overall adherence were drawn. Patients with poor adherence did tend to have larger composite rest <italic>z</italic> scores, which is indicative of inconsistent rest quality; however, patients that were largely adherent to the regimen did not necessarily have more consistent rest as measured by the composite rest <italic>z</italic> score. A <italic>z</italic> score–based comparison of daily outliers in rest and ingestion outliers within 1 day could also serve as a useful metric for exploring the time-domain prediction of variability in medication ingestion time in a study with a larger sample.</p>
      </sec>
      <sec>
        <title>Limitations</title>
        <p>Thus, this analysis is an important first step in leveraging the available data from this DMS system to quantify personalized rest metrics for eventual correlation with objective ingestion data, providing insight into the behavioral context of medication adherence for patients with SMI. However, the study does have several limitations that can be addressed with future research. The most notable is the lack of patients with very poor adherence, which prevented the use of rest data to truly classify patients by their adherence. This shortcoming can be easily addressed by accruing more participants in future studies. It would also be interesting to apply these rest metrics to patients in a controlled sleep study, which would enable an assessment of the degree to which these markers for rest are an accurate surrogate of sleep. Finally, an inherent limitation of the DMS is that it provides accelerometer data at only 1-minute intervals. This study nonetheless demonstrates that this relatively sparse data can still be used to effectively monitor patient rest.</p>
        <p>There are many other future analysis directions that could be pursued with this data. Two of the most direct extensions of this study would be to more fully incorporate the system’s measurement of heart rate and to begin exploring markers that quantify a patient’s activity level throughout the day.</p>
      </sec>
      <sec>
        <title>Conclusions</title>
        <p>Data from the accelerometer in a DMS that provides objective time-stamped medication ingestion records were collected and used to develop novel algorithms for identifying and assessing the quality of daily rest periods for individual patients. A lack of patients with poor adherence in the sample population prevented the use of a quantitative classifier; however, pilot explorations of the relationship between these rest metrics and ingestion provided several insights. Patients with poor adherence experienced lower quality of rest, while patients with high adherence did not exhibit a consistent rest pattern. Additionally, the correlation of outliers in composite rest score with outliers in ingestion time is an interesting potential application of this algorithm. This study is an important first demonstration of the ability of the DMS to track patient rest, which provides a framework for future correlation of DMS-based biomarkers with medication adherence in patients with SMI.</p>
      </sec>
    </sec>
  </body>
  <back>
    <app-group>
      <supplementary-material id="app1">
        <label>Multimedia Appendix 1</label>
        <p>List of all accelerometer features used.</p>
        <media xlink:href="formative_v5i3e17993_app1.docx" xlink:title="DOCX File , 15 KB"/>
      </supplementary-material>
    </app-group>
    <glossary>
      <title>Abbreviations</title>
      <def-list>
        <def-item>
          <term id="abb1">DFR</term>
          <def>
            <p>deviation from rest</p>
          </def>
        </def-item>
        <def-item>
          <term id="abb2">DMS</term>
          <def>
            <p>digital medicine system</p>
          </def>
        </def-item>
        <def-item>
          <term id="abb3">ECG</term>
          <def>
            <p>electrocardiogram</p>
          </def>
        </def-item>
        <def-item>
          <term id="abb4">LCRP</term>
          <def>
            <p>longest continuous rest period</p>
          </def>
        </def-item>
        <def-item>
          <term id="abb5">LRP</term>
          <def>
            <p>longest rest period</p>
          </def>
        </def-item>
        <def-item>
          <term id="abb6">RR</term>
          <def>
            <p>rest reference</p>
          </def>
        </def-item>
        <def-item>
          <term id="abb7">SMI</term>
          <def>
            <p>serious mental illness</p>
          </def>
        </def-item>
      </def-list>
    </glossary>
    <ack>
      <p>Funding for this study was provided by Otsuka Pharmaceutical Development &#38; Commercialization, Inc.</p>
    </ack>
    <fn-group>
      <fn fn-type="con">
        <p>ZH and JK made substantial contributions to the design and conception of this study, the data collection, and the analysis and interpretation of the data. JMC participated in the analysis and interpretation of the data and created the first draft of the manuscript. TP contributed to the design and conception of this study and the data collection. All authors provided intellectual contributions to the manuscript reviews and approved the final version for submission.</p>
      </fn>
      <fn fn-type="conflict">
        <p>ZH, JMC, JK, and TPS are employees of Otsuka Pharmaceutical Development &#38; Commercialization, Inc.</p>
      </fn>
    </fn-group>
    <ref-list>
      <ref id="ref1">
        <label>1</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Kane</surname>
              <given-names>JM</given-names>
            </name>
            <name name-style="western">
              <surname>Kishimoto</surname>
              <given-names>T</given-names>
            </name>
            <name name-style="western">
              <surname>Correll</surname>
              <given-names>CU</given-names>
            </name>
          </person-group>
          <article-title>Non-adherence to medication in patients with psychotic disorders: epidemiology, contributing factors and management strategies</article-title>
          <source>World Psychiatry</source>
          <year>2013</year>
          <month>10</month>
          <volume>12</volume>
          <issue>3</issue>
          <fpage>216</fpage>
          <lpage>26</lpage>
          <comment>
            <ext-link ext-link-type="uri" xlink:type="simple" xlink:href="https://doi.org/10.1002/wps.20060"/>
          </comment>
          <pub-id pub-id-type="doi">10.1002/wps.20060</pub-id>
          <pub-id pub-id-type="medline">24096780</pub-id>
          <pub-id pub-id-type="pmcid">PMC3799245</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref2">
        <label>2</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Cutler</surname>
              <given-names>DM</given-names>
            </name>
            <name name-style="western">
              <surname>Everett</surname>
              <given-names>W</given-names>
            </name>
          </person-group>
          <article-title>Thinking outside the pillbox--medication adherence as a priority for health care reform</article-title>
          <source>N Engl J Med</source>
          <year>2010</year>
          <month>04</month>
          <day>29</day>
          <volume>362</volume>
          <issue>17</issue>
          <fpage>1553</fpage>
          <lpage>5</lpage>
          <pub-id pub-id-type="doi">10.1056/NEJMp1002305</pub-id>
          <pub-id pub-id-type="medline">20375400</pub-id>
          <pub-id pub-id-type="pii">NEJMp1002305</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref3">
        <label>3</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Valenstein</surname>
              <given-names>M</given-names>
            </name>
            <name name-style="western">
              <surname>Ganoczy</surname>
              <given-names>D</given-names>
            </name>
            <name name-style="western">
              <surname>McCarthy</surname>
              <given-names>JF</given-names>
            </name>
            <name name-style="western">
              <surname>Myra Kim</surname>
              <given-names>H</given-names>
            </name>
            <name name-style="western">
              <surname>Lee</surname>
              <given-names>TA</given-names>
            </name>
            <name name-style="western">
              <surname>Blow</surname>
              <given-names>FC</given-names>
            </name>
          </person-group>
          <article-title>Antipsychotic adherence over time among patients receiving treatment for schizophrenia: a retrospective review</article-title>
          <source>J Clin Psychiatry</source>
          <year>2006</year>
          <month>10</month>
          <volume>67</volume>
          <issue>10</issue>
          <fpage>1542</fpage>
          <lpage>50</lpage>
          <pub-id pub-id-type="doi">10.4088/jcp.v67n1008</pub-id>
          <pub-id pub-id-type="medline">17107245</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref4">
        <label>4</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Velligan</surname>
              <given-names>DI</given-names>
            </name>
            <name name-style="western">
              <surname>Sajatovic</surname>
              <given-names>M</given-names>
            </name>
            <name name-style="western">
              <surname>Hatch</surname>
              <given-names>A</given-names>
            </name>
            <name name-style="western">
              <surname>Kramata</surname>
              <given-names>P</given-names>
            </name>
            <name name-style="western">
              <surname>Docherty</surname>
              <given-names>JP</given-names>
            </name>
          </person-group>
          <article-title>Why do psychiatric patients stop antipsychotic medication? A systematic review of reasons for nonadherence to medication in patients with serious mental illness</article-title>
          <source>Patient Prefer Adherence</source>
          <year>2017</year>
          <volume>11</volume>
          <fpage>449</fpage>
          <lpage>468</lpage>
          <comment>
            <ext-link ext-link-type="uri" xlink:type="simple" xlink:href="https://dx.doi.org/10.2147/PPA.S124658"/>
          </comment>
          <pub-id pub-id-type="doi">10.2147/PPA.S124658</pub-id>
          <pub-id pub-id-type="medline">28424542</pub-id>
          <pub-id pub-id-type="pii">ppa-11-449</pub-id>
          <pub-id pub-id-type="pmcid">PMC5344423</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref5">
        <label>5</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>El-Mallakh</surname>
              <given-names>P</given-names>
            </name>
            <name name-style="western">
              <surname>Findlay</surname>
              <given-names>J</given-names>
            </name>
          </person-group>
          <article-title>Strategies to improve medication adherence in patients with schizophrenia: the role of support services</article-title>
          <source>Neuropsychiatr Dis Treat</source>
          <year>2015</year>
          <volume>11</volume>
          <fpage>1077</fpage>
          <lpage>90</lpage>
          <comment>
            <ext-link ext-link-type="uri" xlink:type="simple" xlink:href="https://dx.doi.org/10.2147/NDT.S56107"/>
          </comment>
          <pub-id pub-id-type="doi">10.2147/NDT.S56107</pub-id>
          <pub-id pub-id-type="medline">25931823</pub-id>
          <pub-id pub-id-type="pii">ndt-11-1077</pub-id>
          <pub-id pub-id-type="pmcid">PMC4404876</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref6">
        <label>6</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Andrade</surname>
              <given-names>SE</given-names>
            </name>
            <name name-style="western">
              <surname>Kahler</surname>
              <given-names>KH</given-names>
            </name>
            <name name-style="western">
              <surname>Frech</surname>
              <given-names>F</given-names>
            </name>
            <name name-style="western">
              <surname>Chan</surname>
              <given-names>KA</given-names>
            </name>
          </person-group>
          <article-title>Methods for evaluation of medication adherence and persistence using automated databases</article-title>
          <source>Pharmacoepidemiol Drug Saf</source>
          <year>2006</year>
          <month>08</month>
          <volume>15</volume>
          <issue>8</issue>
          <fpage>565</fpage>
          <lpage>74; discussion 575</lpage>
          <comment>
            <ext-link ext-link-type="uri" xlink:type="simple" xlink:href="https://doi.org/10.1002/pds.1230"/>
          </comment>
          <pub-id pub-id-type="doi">10.1002/pds.1230</pub-id>
          <pub-id pub-id-type="medline">16514590</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref7">
        <label>7</label>
        <nlm-citation citation-type="web">
          <article-title>FDA approves pill with sensor that digitally tracks if patients have ingested their medication</article-title>
          <source>The U.S. Food and Drug Administration</source>
          <access-date>2018-02-22</access-date>
          <comment>
            <ext-link ext-link-type="uri" xlink:type="simple" xlink:href="https://tinyurl.com/y3zbavse">https://tinyurl.com/y3zbavse</ext-link>
          </comment>
        </nlm-citation>
      </ref>
      <ref id="ref8">
        <label>8</label>
        <nlm-citation citation-type="book">
          <person-group person-group-type="editor">
            <name name-style="western">
              <surname>Pandi-Perumal</surname>
              <given-names>SR</given-names>
            </name>
            <name name-style="western">
              <surname>Kramer</surname>
              <given-names>M</given-names>
            </name>
          </person-group>
          <source>Sleep and Mental Illness</source>
          <year>2010</year>
          <publisher-loc>Cambridge</publisher-loc>
          <publisher-name>Cambridge University Press</publisher-name>
        </nlm-citation>
      </ref>
      <ref id="ref9">
        <label>9</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Jagannath</surname>
              <given-names>A</given-names>
            </name>
            <name name-style="western">
              <surname>Peirson</surname>
              <given-names>SN</given-names>
            </name>
            <name name-style="western">
              <surname>Foster</surname>
              <given-names>RG</given-names>
            </name>
          </person-group>
          <article-title>Sleep and circadian rhythm disruption in neuropsychiatric illness</article-title>
          <source>Curr Opin Neurobiol</source>
          <year>2013</year>
          <month>10</month>
          <volume>23</volume>
          <issue>5</issue>
          <fpage>888</fpage>
          <lpage>94</lpage>
          <pub-id pub-id-type="doi">10.1016/j.conb.2013.03.008</pub-id>
          <pub-id pub-id-type="medline">23618559</pub-id>
          <pub-id pub-id-type="pii">S0959-4388(13)00085-8</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref10">
        <label>10</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Jones</surname>
              <given-names>SH</given-names>
            </name>
            <name name-style="western">
              <surname>Hare</surname>
              <given-names>DJ</given-names>
            </name>
            <name name-style="western">
              <surname>Evershed</surname>
              <given-names>K</given-names>
            </name>
          </person-group>
          <article-title>Actigraphic assessment of circadian activity and sleep patterns in bipolar disorder</article-title>
          <source>Bipolar Disord</source>
          <year>2005</year>
          <month>04</month>
          <volume>7</volume>
          <issue>2</issue>
          <fpage>176</fpage>
          <lpage>86</lpage>
          <pub-id pub-id-type="doi">10.1111/j.1399-5618.2005.00187.x</pub-id>
          <pub-id pub-id-type="medline">15762859</pub-id>
          <pub-id pub-id-type="pii">BDI187</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref11">
        <label>11</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Soundy</surname>
              <given-names>A</given-names>
            </name>
            <name name-style="western">
              <surname>Roskell</surname>
              <given-names>C</given-names>
            </name>
            <name name-style="western">
              <surname>Stubbs</surname>
              <given-names>B</given-names>
            </name>
            <name name-style="western">
              <surname>Vancampfort</surname>
              <given-names>D</given-names>
            </name>
          </person-group>
          <article-title>Selection, use and psychometric properties of physical activity measures to assess individuals with severe mental illness: a narrative synthesis</article-title>
          <source>Arch Psychiatr Nurs</source>
          <year>2014</year>
          <month>04</month>
          <volume>28</volume>
          <issue>2</issue>
          <fpage>135</fpage>
          <lpage>51</lpage>
          <pub-id pub-id-type="doi">10.1016/j.apnu.2013.12.002</pub-id>
          <pub-id pub-id-type="medline">24673789</pub-id>
          <pub-id pub-id-type="pii">S0883-9417(13)00153-2</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref12">
        <label>12</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Elsenbruch</surname>
              <given-names>S</given-names>
            </name>
            <name name-style="western">
              <surname>Harnish</surname>
              <given-names>MJ</given-names>
            </name>
            <name name-style="western">
              <surname>Orr</surname>
              <given-names>WC</given-names>
            </name>
          </person-group>
          <article-title>Heart rate variability during waking and sleep in healthy males and females</article-title>
          <source>Sleep</source>
          <year>1999</year>
          <month>12</month>
          <day>15</day>
          <volume>22</volume>
          <issue>8</issue>
          <fpage>1067</fpage>
          <lpage>71</lpage>
          <pub-id pub-id-type="doi">10.1093/sleep/22.8.1067</pub-id>
          <pub-id pub-id-type="medline">10617167</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref13">
        <label>13</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Tobaldini</surname>
              <given-names>E</given-names>
            </name>
            <name name-style="western">
              <surname>Nobili</surname>
              <given-names>L</given-names>
            </name>
            <name name-style="western">
              <surname>Strada</surname>
              <given-names>S</given-names>
            </name>
            <name name-style="western">
              <surname>Casali</surname>
              <given-names>KR</given-names>
            </name>
            <name name-style="western">
              <surname>Braghiroli</surname>
              <given-names>A</given-names>
            </name>
            <name name-style="western">
              <surname>Montano</surname>
              <given-names>N</given-names>
            </name>
          </person-group>
          <article-title>Heart rate variability in normal and pathological sleep</article-title>
          <source>Front Physiol</source>
          <year>2013</year>
          <month>10</month>
          <day>16</day>
          <volume>4</volume>
          <fpage>294</fpage>
          <comment>
            <ext-link ext-link-type="uri" xlink:type="simple" xlink:href="https://doi.org/10.3389/fphys.2013.00294"/>
          </comment>
          <pub-id pub-id-type="doi">10.3389/fphys.2013.00294</pub-id>
          <pub-id pub-id-type="medline">24137133</pub-id>
          <pub-id pub-id-type="pmcid">PMC3797399</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref14">
        <label>14</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Ancoli-Israel</surname>
              <given-names>S</given-names>
            </name>
            <name name-style="western">
              <surname>Cole</surname>
              <given-names>R</given-names>
            </name>
            <name name-style="western">
              <surname>Alessi</surname>
              <given-names>C</given-names>
            </name>
            <name name-style="western">
              <surname>Chambers</surname>
              <given-names>M</given-names>
            </name>
            <name name-style="western">
              <surname>Moorcroft</surname>
              <given-names>W</given-names>
            </name>
            <name name-style="western">
              <surname>Pollak</surname>
              <given-names>CP</given-names>
            </name>
          </person-group>
          <article-title>The role of actigraphy in the study of sleep and circadian rhythms</article-title>
          <source>Sleep</source>
          <year>2003</year>
          <month>05</month>
          <day>01</day>
          <volume>26</volume>
          <issue>3</issue>
          <fpage>342</fpage>
          <lpage>92</lpage>
          <pub-id pub-id-type="doi">10.1093/sleep/26.3.342</pub-id>
          <pub-id pub-id-type="medline">12749557</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref15">
        <label>15</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Sadeh</surname>
              <given-names>A</given-names>
            </name>
            <name name-style="western">
              <surname>Sharkey</surname>
              <given-names>KM</given-names>
            </name>
            <name name-style="western">
              <surname>Carskadon</surname>
              <given-names>MA</given-names>
            </name>
          </person-group>
          <article-title>Activity-based sleep-wake identification: an empirical test of methodological issues</article-title>
          <source>Sleep</source>
          <year>1994</year>
          <month>04</month>
          <volume>17</volume>
          <issue>3</issue>
          <fpage>201</fpage>
          <lpage>7</lpage>
          <pub-id pub-id-type="doi">10.1093/sleep/17.3.201</pub-id>
          <pub-id pub-id-type="medline">7939118</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref16">
        <label>16</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Reid</surname>
              <given-names>K</given-names>
            </name>
            <name name-style="western">
              <surname>Dawson</surname>
              <given-names>D</given-names>
            </name>
          </person-group>
          <article-title>Correlation between wrist activity monitor and electrophysiological measures of sleep in a simulated shiftwork environment for younger and older subjects</article-title>
          <source>Sleep</source>
          <year>1999</year>
          <month>05</month>
          <day>01</day>
          <volume>22</volume>
          <issue>3</issue>
          <fpage>378</fpage>
          <lpage>85</lpage>
          <pub-id pub-id-type="doi">10.1093/sleep/22.3.378</pub-id>
          <pub-id pub-id-type="medline">10341389</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref17">
        <label>17</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Hedner</surname>
              <given-names>J</given-names>
            </name>
            <name name-style="western">
              <surname>Pillar</surname>
              <given-names>G</given-names>
            </name>
            <name name-style="western">
              <surname>Pittman</surname>
              <given-names>SD</given-names>
            </name>
            <name name-style="western">
              <surname>Zou</surname>
              <given-names>D</given-names>
            </name>
            <name name-style="western">
              <surname>Grote</surname>
              <given-names>L</given-names>
            </name>
            <name name-style="western">
              <surname>White</surname>
              <given-names>DP</given-names>
            </name>
          </person-group>
          <article-title>A novel adaptive wrist actigraphy algorithm for sleep-wake assessment in sleep apnea patients</article-title>
          <source>Sleep</source>
          <year>2004</year>
          <month>12</month>
          <day>15</day>
          <volume>27</volume>
          <issue>8</issue>
          <fpage>1560</fpage>
          <lpage>6</lpage>
          <pub-id pub-id-type="doi">10.1093/sleep/27.8.1560</pub-id>
          <pub-id pub-id-type="medline">15683148</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref18">
        <label>18</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Ohayon</surname>
              <given-names>M</given-names>
            </name>
            <name name-style="western">
              <surname>Wickwire</surname>
              <given-names>EM</given-names>
            </name>
            <name name-style="western">
              <surname>Hirshkowitz</surname>
              <given-names>M</given-names>
            </name>
            <name name-style="western">
              <surname>Albert</surname>
              <given-names>SM</given-names>
            </name>
            <name name-style="western">
              <surname>Avidan</surname>
              <given-names>A</given-names>
            </name>
            <name name-style="western">
              <surname>Daly</surname>
              <given-names>FJ</given-names>
            </name>
            <name name-style="western">
              <surname>Dauvilliers</surname>
              <given-names>Y</given-names>
            </name>
            <name name-style="western">
              <surname>Ferri</surname>
              <given-names>R</given-names>
            </name>
            <name name-style="western">
              <surname>Fung</surname>
              <given-names>C</given-names>
            </name>
            <name name-style="western">
              <surname>Gozal</surname>
              <given-names>D</given-names>
            </name>
            <name name-style="western">
              <surname>Hazen</surname>
              <given-names>N</given-names>
            </name>
            <name name-style="western">
              <surname>Krystal</surname>
              <given-names>A</given-names>
            </name>
            <name name-style="western">
              <surname>Lichstein</surname>
              <given-names>K</given-names>
            </name>
            <name name-style="western">
              <surname>Mallampalli</surname>
              <given-names>M</given-names>
            </name>
            <name name-style="western">
              <surname>Plazzi</surname>
              <given-names>G</given-names>
            </name>
            <name name-style="western">
              <surname>Rawding</surname>
              <given-names>R</given-names>
            </name>
            <name name-style="western">
              <surname>Scheer</surname>
              <given-names>FA</given-names>
            </name>
            <name name-style="western">
              <surname>Somers</surname>
              <given-names>V</given-names>
            </name>
            <name name-style="western">
              <surname>Vitiello</surname>
              <given-names>MV</given-names>
            </name>
          </person-group>
          <article-title>National Sleep Foundation's sleep quality recommendations: first report</article-title>
          <source>Sleep Health</source>
          <year>2017</year>
          <month>02</month>
          <volume>3</volume>
          <issue>1</issue>
          <fpage>6</fpage>
          <lpage>19</lpage>
          <pub-id pub-id-type="doi">10.1016/j.sleh.2016.11.006</pub-id>
          <pub-id pub-id-type="medline">28346153</pub-id>
          <pub-id pub-id-type="pii">S2352-7218(16)30130-9</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref19">
        <label>19</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Strine</surname>
              <given-names>TW</given-names>
            </name>
            <name name-style="western">
              <surname>Chapman</surname>
              <given-names>DP</given-names>
            </name>
          </person-group>
          <article-title>Associations of frequent sleep insufficiency with health-related quality of life and health behaviors</article-title>
          <source>Sleep Med</source>
          <year>2005</year>
          <month>01</month>
          <volume>6</volume>
          <issue>1</issue>
          <fpage>23</fpage>
          <lpage>7</lpage>
          <pub-id pub-id-type="doi">10.1016/j.sleep.2004.06.003</pub-id>
          <pub-id pub-id-type="medline">15680291</pub-id>
          <pub-id pub-id-type="pii">S1389-9457(04)00107-8</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref20">
        <label>20</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Lemola</surname>
              <given-names>S</given-names>
            </name>
            <name name-style="western">
              <surname>Ledermann</surname>
              <given-names>T</given-names>
            </name>
            <name name-style="western">
              <surname>Friedman</surname>
              <given-names>EM</given-names>
            </name>
          </person-group>
          <article-title>Variability of sleep duration is related to subjective sleep quality and subjective well-being: an actigraphy study</article-title>
          <source>PLoS One</source>
          <year>2013</year>
          <volume>8</volume>
          <issue>8</issue>
          <fpage>e71292</fpage>
          <comment>
            <ext-link ext-link-type="uri" xlink:type="simple" xlink:href="https://dx.plos.org/10.1371/journal.pone.0071292"/>
          </comment>
          <pub-id pub-id-type="doi">10.1371/journal.pone.0071292</pub-id>
          <pub-id pub-id-type="medline">23967186</pub-id>
          <pub-id pub-id-type="pii">PONE-D-12-32105</pub-id>
          <pub-id pub-id-type="pmcid">PMC3743871</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref21">
        <label>21</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Knights</surname>
              <given-names>J</given-names>
            </name>
            <name name-style="western">
              <surname>Heidary</surname>
              <given-names>Z</given-names>
            </name>
            <name name-style="western">
              <surname>Peters-Strickland</surname>
              <given-names>T</given-names>
            </name>
            <name name-style="western">
              <surname>Ramanathan</surname>
              <given-names>M</given-names>
            </name>
          </person-group>
          <article-title>Evaluating digital medicine ingestion data from seriously mentally ill patients with a Bayesian Hybrid Model</article-title>
          <source>NPJ Digit Med</source>
          <year>2019</year>
          <volume>2</volume>
          <fpage>20</fpage>
          <comment>
            <ext-link ext-link-type="uri" xlink:type="simple" xlink:href="https://doi.org/10.1038/s41746-019-0095-z"/>
          </comment>
          <pub-id pub-id-type="doi">10.1038/s41746-019-0095-z</pub-id>
          <pub-id pub-id-type="medline">31304367</pub-id>
          <pub-id pub-id-type="pii">95</pub-id>
          <pub-id pub-id-type="pmcid">PMC6550231</pub-id>
        </nlm-citation>
      </ref>
      <ref id="ref22">
        <label>22</label>
        <nlm-citation citation-type="web">
          <article-title>Open-label study to assess usability of the medical information device #1 (MIND1) system in adults with schizophrenia on oral aripiprazole</article-title>
          <source>ClinicalTrials.gov</source>
          <access-date>2021-02-11</access-date>
          <comment>
            <ext-link ext-link-type="uri" xlink:type="simple" xlink:href="https://clinicaltrials.gov/ct2/show/NCT02219009">https://clinicaltrials.gov/ct2/show/NCT02219009</ext-link>
          </comment>
        </nlm-citation>
      </ref>
      <ref id="ref23">
        <label>23</label>
        <nlm-citation citation-type="web">
          <article-title>Exploratory trial to assess the functionality of an integrated call center for the digital medicine system</article-title>
          <source>ClinicalTrials.gov</source>
          <access-date>2021-02-11</access-date>
          <comment>
            <ext-link ext-link-type="uri" xlink:type="simple" xlink:href="https://clinicaltrials.gov/ct2/show/NCT02722967">https://clinicaltrials.gov/ct2/show/NCT02722967</ext-link>
          </comment>
        </nlm-citation>
      </ref>
      <ref id="ref24">
        <label>24</label>
        <nlm-citation citation-type="journal">
          <person-group person-group-type="author">
            <name name-style="western">
              <surname>Pedregosa</surname>
              <given-names>F</given-names>
            </name>
            <name name-style="western">
              <surname>Varoquaux</surname>
              <given-names>G</given-names>
            </name>
            <name name-style="western">
              <surname>Gramfort</surname>
              <given-names>A</given-names>
            </name>
            <name name-style="western">
              <surname>Michel</surname>
              <given-names>V</given-names>
            </name>
            <name name-style="western">
              <surname>Thirion</surname>
              <given-names>B</given-names>
            </name>
            <name name-style="western">
              <surname>Grisel</surname>
              <given-names>O</given-names>
            </name>
            <name name-style="western">
              <surname>Blondel</surname>
              <given-names>M</given-names>
            </name>
            <name name-style="western">
              <surname>Prettenhofer</surname>
              <given-names>P</given-names>
            </name>
            <name name-style="western">
              <surname>Weiss</surname>
              <given-names>R</given-names>
            </name>
            <name name-style="western">
              <surname>Dubourg</surname>
              <given-names>V</given-names>
            </name>
            <name name-style="western">
              <surname>Vanderplas</surname>
              <given-names>J</given-names>
            </name>
            <name name-style="western">
              <surname>Passos</surname>
              <given-names>A</given-names>
            </name>
            <name name-style="western">
              <surname>Cournapeau</surname>
              <given-names>D</given-names>
            </name>
            <name name-style="western">
              <surname>Brucher</surname>
              <given-names>M</given-names>
            </name>
            <name name-style="western">
              <surname>Perrot</surname>
              <given-names>M</given-names>
            </name>
            <name name-style="western">
              <surname>Duchesnay</surname>
              <given-names>É</given-names>
            </name>
          </person-group>
          <article-title>Scikit-learn: machine learning in Python</article-title>
          <source>J Machine Learning</source>
          <year>2011</year>
          <volume>12</volume>
          <issue>85</issue>
          <fpage>2825</fpage>
          <lpage>2830</lpage>
        </nlm-citation>
      </ref>
    </ref-list>
  </back>
</article>
