<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Determine if value is consistent by subject in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Determine-if-value-is-consistent-by-subject/m-p/477725#M123096</link>
    <description>&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc sql;
create table not_same as
select *
from have
group by subjectID
having not (max(labLocation)=Min(labLocation));
quit;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/155121"&gt;@mglogan&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I need to determine if the lab collection method for each subject in my data set was collected consistently throughout the study.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;To Illustrate, the variables I will use are "Lab Location" and "Subject ID." Each subject has multiple observations in the data set.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I need to determine if the value of "Lab Location" (Character) is the same for all observations per Subject ID. if not, I need to output to view the result.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Example Data:&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;SubjectID&amp;nbsp; LabLocation Visit&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;Subj123&amp;nbsp; &amp;nbsp; &amp;nbsp;Lab&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;1&lt;BR /&gt;Subj123&amp;nbsp; &amp;nbsp; &amp;nbsp;Lab&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;2&lt;BR /&gt;Subj123&amp;nbsp; &amp;nbsp; &amp;nbsp;Point of Care&amp;nbsp; &amp;nbsp; &amp;nbsp; 3&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Can you recommend the best method for doing this?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thank you!&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
    <pubDate>Fri, 13 Jul 2018 00:06:39 GMT</pubDate>
    <dc:creator>Reeza</dc:creator>
    <dc:date>2018-07-13T00:06:39Z</dc:date>
    <item>
      <title>Determine if value is consistent by subject</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Determine-if-value-is-consistent-by-subject/m-p/477710#M123089</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I need to determine if the lab collection method for each subject in my data set was collected consistently throughout the study.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;To Illustrate, the variables I will use are "Lab Location" and "Subject ID." Each subject has multiple observations in the data set.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I need to determine if the value of "Lab Location" (Character) is the same for all observations per Subject ID. if not, I need to output to view the result.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Example Data:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;SubjectID&amp;nbsp; LabLocation Visit&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Subj123&amp;nbsp; &amp;nbsp; &amp;nbsp;Lab&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;1&lt;BR /&gt;Subj123&amp;nbsp; &amp;nbsp; &amp;nbsp;Lab&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;2&lt;BR /&gt;Subj123&amp;nbsp; &amp;nbsp; &amp;nbsp;Point of Care&amp;nbsp; &amp;nbsp; &amp;nbsp; 3&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Can you recommend the best method for doing this?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you!&lt;/P&gt;</description>
      <pubDate>Thu, 12 Jul 2018 22:49:29 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Determine-if-value-is-consistent-by-subject/m-p/477710#M123089</guid>
      <dc:creator>mglogan</dc:creator>
      <dc:date>2018-07-12T22:49:29Z</dc:date>
    </item>
    <item>
      <title>Re: Determine if value is consistent by subject</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Determine-if-value-is-consistent-by-subject/m-p/477725#M123096</link>
      <description>&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc sql;
create table not_same as
select *
from have
group by subjectID
having not (max(labLocation)=Min(labLocation));
quit;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/155121"&gt;@mglogan&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I need to determine if the lab collection method for each subject in my data set was collected consistently throughout the study.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;To Illustrate, the variables I will use are "Lab Location" and "Subject ID." Each subject has multiple observations in the data set.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I need to determine if the value of "Lab Location" (Character) is the same for all observations per Subject ID. if not, I need to output to view the result.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Example Data:&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;SubjectID&amp;nbsp; LabLocation Visit&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;Subj123&amp;nbsp; &amp;nbsp; &amp;nbsp;Lab&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;1&lt;BR /&gt;Subj123&amp;nbsp; &amp;nbsp; &amp;nbsp;Lab&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;2&lt;BR /&gt;Subj123&amp;nbsp; &amp;nbsp; &amp;nbsp;Point of Care&amp;nbsp; &amp;nbsp; &amp;nbsp; 3&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Can you recommend the best method for doing this?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thank you!&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 13 Jul 2018 00:06:39 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Determine-if-value-is-consistent-by-subject/m-p/477725#M123096</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2018-07-13T00:06:39Z</dc:date>
    </item>
  </channel>
</rss>

