<?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: i am new to sas i have a data set with 5 variables i need the output given in attachment file in New SAS User</title>
    <link>https://communities.sas.com/t5/New-SAS-User/i-am-new-to-sas-i-have-a-data-set-with-5-variables-i-need-the/m-p/514127#M2655</link>
    <description>&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data VS;
input PT  VISITNO  HEIGHT   WEIGHT   PULSE  SBP;    
cards;
101 1 156 78 102 120
101 2 156 78 103 121
101 3 156 78 102 120
102 1 150 70 100 121
;
run;

data w;
set vs;
n=0;
array t height--sbp;
do over t;
v_name=vname(t);
ORRES=t;
n+1;
output;
end;
keep pt visitno v_name orres n;
run;

proc sort data=w out=want(drop=n);
by pt n;
run;
&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Sat, 17 Nov 2018 14:58:30 GMT</pubDate>
    <dc:creator>novinosrin</dc:creator>
    <dc:date>2018-11-17T14:58:30Z</dc:date>
    <item>
      <title>i am new to sas i have a data set with 5 variables i need the output given in attachment file</title>
      <link>https://communities.sas.com/t5/New-SAS-User/i-am-new-to-sas-i-have-a-data-set-with-5-variables-i-need-the/m-p/514123#M2652</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data VS;
input PT  VISITNO  HEIGHT   WEIGHT   PULSE  SBP;    
cards;
101 1 156 78 102 120
101 2 156 78 103 121
101 3 156 78 102 120
102 1 150 70 100 121
;
run;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 17 Nov 2018 14:02:30 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/i-am-new-to-sas-i-have-a-data-set-with-5-variables-i-need-the/m-p/514123#M2652</guid>
      <dc:creator>Aliya-begum</dc:creator>
      <dc:date>2018-11-17T14:02:30Z</dc:date>
    </item>
    <item>
      <title>Re: i am new to sas i have a data set with 5 variables i need the output given in attachment file</title>
      <link>https://communities.sas.com/t5/New-SAS-User/i-am-new-to-sas-i-have-a-data-set-with-5-variables-i-need-the/m-p/514124#M2653</link>
      <description>&lt;P&gt;Proc transpose should solve your needs.&lt;/P&gt;
&lt;P&gt;&lt;A href="https://support.sas.com/documentation/cdl/en/proc/61895/HTML/default/viewer.htm#a000063663.htm" target="_blank"&gt;https://support.sas.com/documentation/cdl/en/proc/61895/HTML/default/viewer.htm#a000063663.htm&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://stats.idre.ucla.edu/sas/modules/how-to-reshape-data-long-to-wide-using-proc-transpose/" target="_blank"&gt;https://stats.idre.ucla.edu/sas/modules/how-to-reshape-data-long-to-wide-using-proc-transpose/&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 17 Nov 2018 14:22:46 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/i-am-new-to-sas-i-have-a-data-set-with-5-variables-i-need-the/m-p/514124#M2653</guid>
      <dc:creator>VDD</dc:creator>
      <dc:date>2018-11-17T14:22:46Z</dc:date>
    </item>
    <item>
      <title>Re: i am new to sas i have a data set with 5 variables i need the output given in attachment file</title>
      <link>https://communities.sas.com/t5/New-SAS-User/i-am-new-to-sas-i-have-a-data-set-with-5-variables-i-need-the/m-p/514125#M2654</link>
      <description>&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data VS;
input PT  VISITNO  HEIGHT   WEIGHT   PULSE  SBP;    
cards;
101 1 156 78 102 120
101 2 156 78 103 121
101 3 156 78 102 120
102 1 150 70 100 121
;
run;

proc transpose data=vs out=w;
by pt visitno;
var height--sbp;
run;
proc sort data=w out=want;
by pt _name_;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Rename/add labels to your convenience/needs&lt;/P&gt;</description>
      <pubDate>Sat, 17 Nov 2018 14:47:29 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/i-am-new-to-sas-i-have-a-data-set-with-5-variables-i-need-the/m-p/514125#M2654</guid>
      <dc:creator>novinosrin</dc:creator>
      <dc:date>2018-11-17T14:47:29Z</dc:date>
    </item>
    <item>
      <title>Re: i am new to sas i have a data set with 5 variables i need the output given in attachment file</title>
      <link>https://communities.sas.com/t5/New-SAS-User/i-am-new-to-sas-i-have-a-data-set-with-5-variables-i-need-the/m-p/514127#M2655</link>
      <description>&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data VS;
input PT  VISITNO  HEIGHT   WEIGHT   PULSE  SBP;    
cards;
101 1 156 78 102 120
101 2 156 78 103 121
101 3 156 78 102 120
102 1 150 70 100 121
;
run;

data w;
set vs;
n=0;
array t height--sbp;
do over t;
v_name=vname(t);
ORRES=t;
n+1;
output;
end;
keep pt visitno v_name orres n;
run;

proc sort data=w out=want(drop=n);
by pt n;
run;
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Sat, 17 Nov 2018 14:58:30 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/i-am-new-to-sas-i-have-a-data-set-with-5-variables-i-need-the/m-p/514127#M2655</guid>
      <dc:creator>novinosrin</dc:creator>
      <dc:date>2018-11-17T14:58:30Z</dc:date>
    </item>
    <item>
      <title>Re: i am new to sas i have a data set with 5 variables i need the output given in attachment file</title>
      <link>https://communities.sas.com/t5/New-SAS-User/i-am-new-to-sas-i-have-a-data-set-with-5-variables-i-need-the/m-p/514128#M2656</link>
      <description>&lt;P&gt;And something fancy&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data VS;
input PT  VISITNO  HEIGHT   WEIGHT   PULSE  SBP;    
cards;
101 1 156 78 102 120
101 2 156 78 103 121
101 3 156 78 102 120
102 1 150 70 100 121
;
run;
data _null_;
if _n_=1 then do;
   dcl hash H (ordered: "A",multidata:'y') ;
   h.definekey  ("PT",'n') ;
   h.definedata ("PT", "VISITNO", "V_NAME","ORRES") ;
   h.definedone () ;
   end;
set vs end=lr;
n=0;
array t height--sbp;
do over t;
v_name=vname(t);
ORRES=t;
n+1;
h.add();
end;
if lr then h.output(dataset:'want');
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Sat, 17 Nov 2018 15:06:16 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/i-am-new-to-sas-i-have-a-data-set-with-5-variables-i-need-the/m-p/514128#M2656</guid>
      <dc:creator>novinosrin</dc:creator>
      <dc:date>2018-11-17T15:06:16Z</dc:date>
    </item>
    <item>
      <title>Re: i am new to sas i have a data set with 5 variables i need the output given in attachment file</title>
      <link>https://communities.sas.com/t5/New-SAS-User/i-am-new-to-sas-i-have-a-data-set-with-5-variables-i-need-the/m-p/514138#M2659</link>
      <description>thank you for helping me</description>
      <pubDate>Sat, 17 Nov 2018 16:55:43 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/i-am-new-to-sas-i-have-a-data-set-with-5-variables-i-need-the/m-p/514138#M2659</guid>
      <dc:creator>Aliya-begum</dc:creator>
      <dc:date>2018-11-17T16:55:43Z</dc:date>
    </item>
    <item>
      <title>Re: i am new to sas i have a data set with 5 variables i need the output given in attachment file</title>
      <link>https://communities.sas.com/t5/New-SAS-User/i-am-new-to-sas-i-have-a-data-set-with-5-variables-i-need-the/m-p/514141#M2661</link>
      <description>&lt;P&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/247024"&gt;@Aliya-begum&lt;/a&gt;&amp;nbsp; If the questions has been answered, you could mark as answered choosing one of the given solutions that you prefer.&lt;/P&gt;</description>
      <pubDate>Sat, 17 Nov 2018 17:35:21 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/i-am-new-to-sas-i-have-a-data-set-with-5-variables-i-need-the/m-p/514141#M2661</guid>
      <dc:creator>Andygray</dc:creator>
      <dc:date>2018-11-17T17:35:21Z</dc:date>
    </item>
  </channel>
</rss>

