<?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: Check Condition in multiple variables in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Check-Condition-in-multiple-variables/m-p/760874#M240668</link>
    <description>&lt;P&gt;OK i am attaching file.&lt;/P&gt;</description>
    <pubDate>Wed, 11 Aug 2021 09:33:49 GMT</pubDate>
    <dc:creator>jay_bhavsar</dc:creator>
    <dc:date>2021-08-11T09:33:49Z</dc:date>
    <item>
      <title>Check Condition in multiple variables</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Check-Condition-in-multiple-variables/m-p/760343#M240430</link>
      <description>&lt;P&gt;Hello all,&lt;/P&gt;&lt;P&gt;I have below data&amp;nbsp;&lt;/P&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;SUB&lt;/TD&gt;&lt;TD&gt;Arm&lt;/TD&gt;&lt;TD&gt;Screen&lt;/TD&gt;&lt;TD&gt;Week1&lt;/TD&gt;&lt;TD&gt;Week2&lt;/TD&gt;&lt;TD&gt;Week3&lt;/TD&gt;&lt;TD&gt;Week4&lt;/TD&gt;&lt;TD&gt;Week5&lt;/TD&gt;&lt;TD&gt;Week6&lt;/TD&gt;&lt;TD&gt;Week7&lt;/TD&gt;&lt;TD&gt;Week8&lt;/TD&gt;&lt;TD&gt;Week9&lt;/TD&gt;&lt;TD&gt;Week10&lt;/TD&gt;&lt;TD&gt;TIME TO ACHIVE TARGET 10&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;1&lt;/TD&gt;&lt;TD&gt;Test&lt;/TD&gt;&lt;TD&gt;8&lt;/TD&gt;&lt;TD&gt;8.2&lt;/TD&gt;&lt;TD&gt;8.4&lt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&lt;/TD&gt;&lt;TD&gt;8.3&lt;/TD&gt;&lt;TD&gt;8.5&lt;/TD&gt;&lt;TD&gt;8.7&lt;/TD&gt;&lt;TD&gt;8.9&lt;/TD&gt;&lt;TD&gt;9.1&lt;/TD&gt;&lt;TD&gt;9.3&lt;/TD&gt;&lt;TD&gt;9.5&lt;/TD&gt;&lt;TD&gt;9.7&lt;/TD&gt;&lt;TD&gt;9.9&lt;/TD&gt;&lt;TD&gt;10.1&lt;/TD&gt;&lt;TD&gt;10.3&lt;/TD&gt;&lt;TD&gt;9&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;i want to check that at which week subject has reached score of 10, in last column answer are there i want that column to be generated by coding if score is greater then 10 at screen we will drop that subject.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks in advance.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 09 Aug 2021 12:13:42 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Check-Condition-in-multiple-variables/m-p/760343#M240430</guid>
      <dc:creator>jay_bhavsar</dc:creator>
      <dc:date>2021-08-09T12:13:42Z</dc:date>
    </item>
    <item>
      <title>Re: Check Condition in multiple variables</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Check-Condition-in-multiple-variables/m-p/760346#M240431</link>
      <description>&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;/* UNTESTED CODE */
data want;
    set have;
    if screen&amp;gt;10 then delete;
    array w week1-week10;
    array ww _temporary_;
    do i = 1 to dim(w);
         ww(i)=(w(i)&amp;gt;=10);
    end;
    time_to_achieve_target_10 = whichn(1,of ww[*]);
    drop i;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;If you want tested code, please provide data as a SAS data set (&lt;A href="https://blogs.sas.com/content/sastraining/2016/03/11/jedi-sas-tricks-data-to-data-step-macro/" target="_self"&gt;instructions&lt;/A&gt;)&lt;/P&gt;</description>
      <pubDate>Mon, 09 Aug 2021 12:37:15 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Check-Condition-in-multiple-variables/m-p/760346#M240431</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2021-08-09T12:37:15Z</dc:date>
    </item>
    <item>
      <title>Re: Check Condition in multiple variables</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Check-Condition-in-multiple-variables/m-p/760545#M240503</link>
      <description>Hi friend,&lt;BR /&gt;may be i failed to explain the query i run the the code but its not giving answer as i accepted. let me explain you the situation.&lt;BR /&gt;SUB 1 reached to score of more then 10 at week10 so "Time to achieve target 10" has value 10.&lt;BR /&gt;Likewise SUB 1 reached to score of more then 10 at week7 so "Time to achieve target 10" has value 7.&lt;BR /&gt;and for sub 3 its week5, for sub 4 its week3, for sub 5 its week1, for sub 7 its week10, for 8 week4 and so on.&lt;BR /&gt;and what if all Column name is not in sequence (Ex: Jan Mar May Sep Dec) then how can we get values of time to achieve target 10.</description>
      <pubDate>Tue, 10 Aug 2021 05:18:21 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Check-Condition-in-multiple-variables/m-p/760545#M240503</guid>
      <dc:creator>jay_bhavsar</dc:creator>
      <dc:date>2021-08-10T05:18:21Z</dc:date>
    </item>
    <item>
      <title>Re: Check Condition in multiple variables</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Check-Condition-in-multiple-variables/m-p/760551#M240504</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/210344"&gt;@jay_bhavsar&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;Hi friend,&lt;BR /&gt;may be i failed to explain the query i run the the code but its not giving answer as i accepted. let me explain you the situation.&lt;BR /&gt;SUB 1 reached to score of more then 10 at week10 so "Time to achieve target 10" has value 10.&lt;BR /&gt;Likewise SUB 1 reached to score of more then 10 at week7 so "Time to achieve target 10" has value 7.&lt;BR /&gt;and for sub 3 its week5, for sub 4 its week3, for sub 5 its week1, for sub 7 its week10, for 8 week4 and so on.&lt;BR /&gt;and what if all Column name is not in sequence (Ex: Jan Mar May Sep Dec) then how can we get values of time to achieve target 10.&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;There are no variables named "Jan", "Mar", etc in your data. Please post the data you have in usable form and with the variable names you have.&lt;/P&gt;
&lt;P&gt;Please explain the role of the variables "Arm" and "Screen", are they necessary to calculate "TimeToAchieveTarget10"?&lt;/P&gt;
&lt;P&gt;Untested:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data want;
  set have;
  length Target10 8;
  array values Week1-Week10;

  do i = 1 to dim(values);
    if values[i] &amp;gt;= 10 then do;
      Target10 = input(compress(vname(values[i]),,'kd'), 2.);
      leave;
    end;
  end;
run;
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 10 Aug 2021 07:12:52 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Check-Condition-in-multiple-variables/m-p/760551#M240504</guid>
      <dc:creator>andreas_lds</dc:creator>
      <dc:date>2021-08-10T07:12:52Z</dc:date>
    </item>
    <item>
      <title>Re: Check Condition in multiple variables</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Check-Condition-in-multiple-variables/m-p/760560#M240507</link>
      <description>&lt;P&gt;Thank you Andreas,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The code is giving desired results. One more thing to see what is some weeks in between are not there (file attached).&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;variables&amp;nbsp; "Arm" and "Screen" is just for carry no need to check condition in that.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 10 Aug 2021 08:35:21 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Check-Condition-in-multiple-variables/m-p/760560#M240507</guid>
      <dc:creator>jay_bhavsar</dc:creator>
      <dc:date>2021-08-10T08:35:21Z</dc:date>
    </item>
    <item>
      <title>Re: Check Condition in multiple variables</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Check-Condition-in-multiple-variables/m-p/760572#M240511</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/210344"&gt;@jay_bhavsar&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;Thank you Andreas,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The code is giving desired results. One more thing to see what is some weeks in between are not there (file attached).&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;variables&amp;nbsp; "Arm" and "Screen" is just for carry no need to check condition in that.&lt;/SPAN&gt;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Sorry, but i won't open any office-file, please post the data in usable form.&lt;/P&gt;</description>
      <pubDate>Tue, 10 Aug 2021 10:22:09 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Check-Condition-in-multiple-variables/m-p/760572#M240511</guid>
      <dc:creator>andreas_lds</dc:creator>
      <dc:date>2021-08-10T10:22:09Z</dc:date>
    </item>
    <item>
      <title>Re: Check Condition in multiple variables</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Check-Condition-in-multiple-variables/m-p/760594#M240517</link>
      <description>which format is fine for you? SAS DATASET of any other??</description>
      <pubDate>Tue, 10 Aug 2021 12:15:04 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Check-Condition-in-multiple-variables/m-p/760594#M240517</guid>
      <dc:creator>jay_bhavsar</dc:creator>
      <dc:date>2021-08-10T12:15:04Z</dc:date>
    </item>
    <item>
      <title>Re: Check Condition in multiple variables</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Check-Condition-in-multiple-variables/m-p/760605#M240518</link>
      <description>&lt;P&gt;Earlier, I gave a link to instructions to provide your data as SAS data step code. That's the best form to use.&lt;/P&gt;</description>
      <pubDate>Tue, 10 Aug 2021 12:19:50 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Check-Condition-in-multiple-variables/m-p/760605#M240518</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2021-08-10T12:19:50Z</dc:date>
    </item>
    <item>
      <title>Re: Check Condition in multiple variables</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Check-Condition-in-multiple-variables/m-p/760874#M240668</link>
      <description>&lt;P&gt;OK i am attaching file.&lt;/P&gt;</description>
      <pubDate>Wed, 11 Aug 2021 09:33:49 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Check-Condition-in-multiple-variables/m-p/760874#M240668</guid>
      <dc:creator>jay_bhavsar</dc:creator>
      <dc:date>2021-08-11T09:33:49Z</dc:date>
    </item>
    <item>
      <title>Re: Check Condition in multiple variables</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Check-Condition-in-multiple-variables/m-p/760881#M240671</link>
      <description>&lt;P&gt;Many of us will not download files. The SAS code should be included in your reply, as text by pasting it into the window that appears when you click on the "running man" icon.&lt;/P&gt;</description>
      <pubDate>Wed, 11 Aug 2021 10:11:19 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Check-Condition-in-multiple-variables/m-p/760881#M240671</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2021-08-11T10:11:19Z</dc:date>
    </item>
    <item>
      <title>Re: Check Condition in multiple variables</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Check-Condition-in-multiple-variables/m-p/760882#M240672</link>
      <description>data Have;&lt;BR /&gt;  infile datalines ;&lt;BR /&gt;  input SUB Arm $ Screen Week1 Week2 Week5 Week6 Week7 Week9 Week10 TIME_TO_ACHIVE_TARGET ;&lt;BR /&gt;datalines4;&lt;BR /&gt;1 Test 8 8.2 8.4 9 9.2 9.4 9.8 1 10&lt;BR /&gt;2 Test 8.7 8.9 9.1 9.7 9.9 1 5 7 7&lt;BR /&gt;3 Ref 9 9.2 9.4 10 2 4 8 11 5&lt;BR /&gt;4 Test 9.5 9.7 9.9 5 7 9 11.3 11.5 3&lt;BR /&gt;5 Ref 9.8 10 2 8 11 11.2 11.6 11.8 1&lt;BR /&gt;6 Ref 3 5 7 11.3 11.5 11.7 12.1 12.3 .&lt;BR /&gt;7 Test 8 8.2 8.4 9 9.2 9.4 9.8 10 10&lt;BR /&gt;8 Ref 9.2 9.4 9.6 2 4 6 11 11.2 4&lt;BR /&gt;9 Ref 8.6 8.8 9 9.6 9.8 10 4 6 7&lt;BR /&gt;10 Test 8.3 8.5 8.7 9.3 9.5 9.7 1 3 9&lt;BR /&gt;;;;;&lt;BR /&gt;</description>
      <pubDate>Wed, 11 Aug 2021 10:20:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Check-Condition-in-multiple-variables/m-p/760882#M240672</guid>
      <dc:creator>jay_bhavsar</dc:creator>
      <dc:date>2021-08-11T10:20:40Z</dc:date>
    </item>
    <item>
      <title>Re: Check Condition in multiple variables</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Check-Condition-in-multiple-variables/m-p/760891#M240677</link>
      <description>&lt;P&gt;This data is dramatically different than what you posted originally, and there are many places where the value is 1 whereas before it was 10, which of course changes the results. Are these typographical errors?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Could you please correct all of your data set (or inform me that it already is correct)? Could you please post the code in a code box as I requested?&lt;/P&gt;</description>
      <pubDate>Wed, 11 Aug 2021 12:24:41 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Check-Condition-in-multiple-variables/m-p/760891#M240677</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2021-08-11T12:24:41Z</dc:date>
    </item>
    <item>
      <title>Re: Check Condition in multiple variables</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Check-Condition-in-multiple-variables/m-p/760896#M240680</link>
      <description>&lt;P&gt;The posted data is same as before. the only difference is i removed some column to see how code can be apply when the sequence of Week1-Week10 is not there.&amp;nbsp;&lt;BR /&gt;As for all available columns the code provided previously is working perfectly.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;but i just curious to know what if we have columns which are not in sequence.&lt;/P&gt;</description>
      <pubDate>Wed, 11 Aug 2021 12:24:37 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Check-Condition-in-multiple-variables/m-p/760896#M240680</guid>
      <dc:creator>jay_bhavsar</dc:creator>
      <dc:date>2021-08-11T12:24:37Z</dc:date>
    </item>
    <item>
      <title>Re: Check Condition in multiple variables</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Check-Condition-in-multiple-variables/m-p/760897#M240681</link>
      <description>&lt;BLOCKQUOTE&gt;
&lt;P&gt;&lt;SPAN&gt;The posted data is same as before.&lt;/SPAN&gt;&lt;/P&gt;
&lt;/BLOCKQUOTE&gt;
&lt;P&gt;No it is not.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;There were 10s in the original data set, and the value of 1 appears now. Are these typographical errors? If so, please correct them.&lt;/P&gt;</description>
      <pubDate>Wed, 11 Aug 2021 12:42:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Check-Condition-in-multiple-variables/m-p/760897#M240681</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2021-08-11T12:42:40Z</dc:date>
    </item>
    <item>
      <title>Re: Check Condition in multiple variables</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Check-Condition-in-multiple-variables/m-p/761349#M240914</link>
      <description>&lt;P&gt;Please explain why Time_To_Achieve_Target is 10 in the first line of the data you have posted. The maximum value is 9.8 in Week9.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The code i posted will need at one update if some week-variables don't exist. Changing the array-statement to&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;array values Week:;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;should be sufficient, assuming that there are no variables in the dataset whose names start with "week" but must not considered in setting Time_To_Achieve_Target. And the variables must be properly sorted, if Week5 appears before Week4 the loop won't give the expected results.&lt;/P&gt;</description>
      <pubDate>Fri, 13 Aug 2021 04:34:50 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Check-Condition-in-multiple-variables/m-p/761349#M240914</guid>
      <dc:creator>andreas_lds</dc:creator>
      <dc:date>2021-08-13T04:34:50Z</dc:date>
    </item>
  </channel>
</rss>

