<?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 How to replace value with Another Row value in SAS from Data Set in Developers</title>
    <link>https://communities.sas.com/t5/Developers/How-to-replace-value-with-Another-Row-value-in-SAS-from-Data-Set/m-p/640405#M738</link>
    <description>&lt;P&gt;How to replace if the value is 1 with the below row value&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;STRONG&gt;"Weight"&lt;/STRONG&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;find the below image current data set and the final output required,&lt;/P&gt;&lt;P&gt;please any one help how to get the final required dataset&lt;span class="lia-inline-image-display-wrapper lia-image-align-left" image-alt="dataheloset.PNG" style="width: 999px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/38350i190830A2AA3C533D/image-size/large?v=v2&amp;amp;px=999" role="button" title="dataheloset.PNG" alt="dataheloset.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
    <pubDate>Thu, 16 Apr 2020 11:52:57 GMT</pubDate>
    <dc:creator>Shuail_Ibrahim</dc:creator>
    <dc:date>2020-04-16T11:52:57Z</dc:date>
    <item>
      <title>How to replace value with Another Row value in SAS from Data Set</title>
      <link>https://communities.sas.com/t5/Developers/How-to-replace-value-with-Another-Row-value-in-SAS-from-Data-Set/m-p/640405#M738</link>
      <description>&lt;P&gt;How to replace if the value is 1 with the below row value&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;STRONG&gt;"Weight"&lt;/STRONG&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;find the below image current data set and the final output required,&lt;/P&gt;&lt;P&gt;please any one help how to get the final required dataset&lt;span class="lia-inline-image-display-wrapper lia-image-align-left" image-alt="dataheloset.PNG" style="width: 999px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/38350i190830A2AA3C533D/image-size/large?v=v2&amp;amp;px=999" role="button" title="dataheloset.PNG" alt="dataheloset.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 16 Apr 2020 11:52:57 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Developers/How-to-replace-value-with-Another-Row-value-in-SAS-from-Data-Set/m-p/640405#M738</guid>
      <dc:creator>Shuail_Ibrahim</dc:creator>
      <dc:date>2020-04-16T11:52:57Z</dc:date>
    </item>
    <item>
      <title>Re: How to replace value with Another Row value in SAS from Data Set</title>
      <link>https://communities.sas.com/t5/Developers/How-to-replace-value-with-Another-Row-value-in-SAS-from-Data-Set/m-p/640408#M739</link>
      <description>&lt;P&gt;Why did you post photographs of 25 numbers? Wouldn't it have been easier to just type (or paste) the numbers directly into your question?&amp;nbsp; It certainly would be easier to deal with.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;First step is the split the original mish-mash into two datasets.&amp;nbsp; One with the actual employee data. And the other with the WEIGHT data.&amp;nbsp; Now you can combine them.&amp;nbsp; It looks like you just want to multiple the value of TEST1 times the value of WEIGHT1, TEST2 times the value of WEIGHT2 etc. Do not attempt to add the extra row back into the result.&amp;nbsp; If you need to re-create your photograph do that as a report.&lt;/P&gt;</description>
      <pubDate>Thu, 16 Apr 2020 11:59:09 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Developers/How-to-replace-value-with-Another-Row-value-in-SAS-from-Data-Set/m-p/640408#M739</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2020-04-16T11:59:09Z</dc:date>
    </item>
    <item>
      <title>Re: How to replace value with Another Row value in SAS from Data Set</title>
      <link>https://communities.sas.com/t5/Developers/How-to-replace-value-with-Another-Row-value-in-SAS-from-Data-Set/m-p/640703#M754</link>
      <description>&lt;P&gt;Plz post the data step code ,NOT picture , nobody would like to type it for you.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data have;
input id $ test1-test4;
cards;
1 0 0 0 1
2 1 0 0 0
3 0 0 1 0
4 0 0 0 0
weight 1.412 0.207 0.207 0.207
;
data want;
 set have;
 if _n_=1 then set have(keep=test1-test4 
 rename=(test1-test4=t1-t4)) point=nobs nobs=nobs;
array x{*} test1-test4;
array y{*} t1-t4;
do i=1 to dim(x);
 if x{i} then x{i}=y{i};
end;
drop i t1-t4;
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 17 Apr 2020 12:21:22 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Developers/How-to-replace-value-with-Another-Row-value-in-SAS-from-Data-Set/m-p/640703#M754</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2020-04-17T12:21:22Z</dc:date>
    </item>
  </channel>
</rss>

