<?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 creating a long/short portfolio in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/creating-a-long-short-portfolio/m-p/438983#M282365</link>
    <description>&lt;P&gt;First time asking for help with SAS (not much experience using it). I pulled cumulative returns on the industries within the Consumer Discretionary Sector and not wish to make a long/short portfolio going long in the best performing industry while going short in the worst performing industry. The code I made is&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data SLPort;
	merge Textile3(in=a rename=_freq_=L_N) Automobile3(in=b rename=_freq_=S_N) class.ff_factors(in=c);
	by date;

	if a and b and c;
	S_L = gind252030_ewret - gind251020_ewret;
	format gind252030_ewret gind251020_ewret S_L percentn8.2;
run;

proc reg data=SLPort;
	model S_L=mktrf smb hml umd;
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;however when I try to run the code, I receive and error saying that,&amp;nbsp;&lt;STRONG&gt;The variable _NAME_ or _TYPE_ exists in a data set that is not TYPE=CORR, COV, SSCP, etc&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Any help would be terrific! Also apologies if I posted this in the wrong location with the wrong subject&lt;/P&gt;</description>
    <pubDate>Wed, 21 Feb 2018 16:43:37 GMT</pubDate>
    <dc:creator>zcmcderm</dc:creator>
    <dc:date>2018-02-21T16:43:37Z</dc:date>
    <item>
      <title>creating a long/short portfolio</title>
      <link>https://communities.sas.com/t5/SAS-Programming/creating-a-long-short-portfolio/m-p/438983#M282365</link>
      <description>&lt;P&gt;First time asking for help with SAS (not much experience using it). I pulled cumulative returns on the industries within the Consumer Discretionary Sector and not wish to make a long/short portfolio going long in the best performing industry while going short in the worst performing industry. The code I made is&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data SLPort;
	merge Textile3(in=a rename=_freq_=L_N) Automobile3(in=b rename=_freq_=S_N) class.ff_factors(in=c);
	by date;

	if a and b and c;
	S_L = gind252030_ewret - gind251020_ewret;
	format gind252030_ewret gind251020_ewret S_L percentn8.2;
run;

proc reg data=SLPort;
	model S_L=mktrf smb hml umd;
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;however when I try to run the code, I receive and error saying that,&amp;nbsp;&lt;STRONG&gt;The variable _NAME_ or _TYPE_ exists in a data set that is not TYPE=CORR, COV, SSCP, etc&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Any help would be terrific! Also apologies if I posted this in the wrong location with the wrong subject&lt;/P&gt;</description>
      <pubDate>Wed, 21 Feb 2018 16:43:37 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/creating-a-long-short-portfolio/m-p/438983#M282365</guid>
      <dc:creator>zcmcderm</dc:creator>
      <dc:date>2018-02-21T16:43:37Z</dc:date>
    </item>
    <item>
      <title>Re: creating a long/short portfolio</title>
      <link>https://communities.sas.com/t5/SAS-Programming/creating-a-long-short-portfolio/m-p/438987#M282366</link>
      <description>&lt;P&gt;That's not an error that seems to align with the code you've posted. Can you please post your full log and code. Use the { i } to post your code to ensure it's formatted and not garbled in the web page.&lt;/P&gt;</description>
      <pubDate>Wed, 21 Feb 2018 16:44:26 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/creating-a-long-short-portfolio/m-p/438987#M282366</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2018-02-21T16:44:26Z</dc:date>
    </item>
  </channel>
</rss>

