<?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: Using data from 2 independent data sets in Statistical Procedures</title>
    <link>https://communities.sas.com/t5/Statistical-Procedures/Using-data-from-2-independent-data-sets/m-p/238140#M12621</link>
    <description>&lt;P&gt;I didn't attend that SGF talk, so I don't know the details, but that statement seems to incite unnecessary worry.&amp;nbsp; I regularly use MERGE without a BY statement to horizontally concatenate data that I then use to use in creating ODS graphics. (&lt;A href="http://blogs.sas.com/content/iml/2013/04/22/overlay-custom-curves.html" target="_self"&gt;See the end of this article for a discussion&lt;/A&gt;.) I've never had a problem.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Philosophically, you have to accept that the first observation in data set 'A' might have nothing to do with the first observation in data set 'B'. Of course, I wouldn't do a statistical analysis of the combined data unless I knew that the observations lined up.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Perhaps a more fair poem would be:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;To horizontally concatenate,&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;MERGE without BY is really great.&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;But if the&amp;nbsp;variables don't relate,&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;a statistical analysis is tempting fate.&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 07 Dec 2015 19:15:30 GMT</pubDate>
    <dc:creator>Rick_SAS</dc:creator>
    <dc:date>2015-12-07T19:15:30Z</dc:date>
    <item>
      <title>Using data from 2 independent data sets</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Using-data-from-2-independent-data-sets/m-p/237978#M12606</link>
      <description>&lt;P&gt;Hi there my SAS friends:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I have a question about solving an function using 2 independent data sets, this because in one of them i have my dependent variable and in the other my independent variables.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;So, here is what i have:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I have accomplished to generate the mean diference between 2 data sets, and further this diference i obtained 3 values a0 b0 and b1, like that:&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;data dif_want;&lt;BR /&gt;merge mean1 mean2;&lt;BR /&gt;diff = mean_var_interest1 - mean_var_interest2;&lt;BR /&gt;&lt;STRONG&gt;a0&lt;/STRONG&gt; = (mean_var_interest1- mean_var_interest2)/30;&lt;BR /&gt;&lt;STRONG&gt;b0&lt;/STRONG&gt; = log(a0/mean_var_interest2);&lt;BR /&gt;&lt;STRONG&gt;b1&lt;/STRONG&gt; = b0/10;&lt;BR /&gt;run;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The next step, to increase the efficience of the solution; i need to use a0 b0 and b1 into this function:&lt;BR /&gt;&lt;BR /&gt;proc nlin data=any_other_dataset plots=all method=marquardt;&lt;BR /&gt;parms a0 = &lt;STRONG&gt;a0&lt;/STRONG&gt; b0 = &lt;STRONG&gt;b0&lt;/STRONG&gt; b1 = &lt;STRONG&gt;b1&lt;/STRONG&gt;;&lt;BR /&gt;model response=a0*exp(exp(b0)*(exp(b1*observation)-1)/b1&lt;WBR /&gt;);&lt;BR /&gt;id Sample;&lt;BR /&gt;output out=est_ind1 p=pred r=resid parms=a0 b0 b1;&lt;BR /&gt;run;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I have to write the specifications of the function, being: response and observation that belong to the dataset called 'any_other_dataset'&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thank you very much for your suggestions and help.&lt;/P&gt;</description>
      <pubDate>Sat, 05 Dec 2015 21:42:22 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Using-data-from-2-independent-data-sets/m-p/237978#M12606</guid>
      <dc:creator>jonatan_velarde</dc:creator>
      <dc:date>2015-12-05T21:42:22Z</dc:date>
    </item>
    <item>
      <title>Re: Using data from 2 independent data sets</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Using-data-from-2-independent-data-sets/m-p/237990#M12607</link>
      <description>&lt;P&gt;If you want the values from dif_want as starting values for the nonlinear regression. Use&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;parms / pdata=dif_want;&lt;/P&gt;</description>
      <pubDate>Sat, 05 Dec 2015 23:16:35 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Using-data-from-2-independent-data-sets/m-p/237990#M12607</guid>
      <dc:creator>PGStats</dc:creator>
      <dc:date>2015-12-05T23:16:35Z</dc:date>
    </item>
    <item>
      <title>Re: Using data from 2 independent data sets</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Using-data-from-2-independent-data-sets/m-p/238013#M12608</link>
      <description>&lt;P&gt;Thank you for your answer but unfortunaly didn't work, in log file appears:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;DIV class="sasSource" style="color: #000000; font-family: Consolas, Courier, 'Courier New'; font-size: 16px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: pre; widows: 1; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: #ffffff;"&gt;1 OPTIONS NONOTES NOSTIMER NOSOURCE NOSYNTAXCHECK;&lt;/DIV&gt;
&lt;DIV class="sasSource" style="color: #000000; font-family: Consolas, Courier, 'Courier New'; font-size: 16px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: pre; widows: 1; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: #ffffff;"&gt;55&lt;/DIV&gt;
&lt;DIV class="sasSource" style="color: #000000; font-family: Consolas, Courier, 'Courier New'; font-size: 16px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: pre; widows: 1; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: #ffffff;"&gt;56 proc nlin data=Sem_data_Negat plots=all method=marquardt;&lt;/DIV&gt;
&lt;DIV class="sasSource" style="color: #000000; font-family: Consolas, Courier, 'Courier New'; font-size: 16px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: pre; widows: 1; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: #ffffff;"&gt;57 parms / pdata=dif_want;&lt;/DIV&gt;
&lt;DIV class="sasSource" style="color: #000000; font-family: Consolas, Courier, 'Courier New'; font-size: 16px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: pre; widows: 1; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: #ffffff;"&gt;58 where age_in_days &amp;gt;= 0 and age_in_days &amp;lt;= 40;&lt;/DIV&gt;
&lt;DIV id="sasLogError1_1449412972748" class="sasError" style="color: red; font-family: Consolas, Courier, 'Courier New'; font-size: 16px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: pre; widows: 1; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: #ffffff;"&gt;ERROR: Variable age_in_days is not on file WORK.DIF_WANT.&lt;/DIV&gt;
&lt;DIV class="sasSource" style="color: #000000; font-family: Consolas, Courier, 'Courier New'; font-size: 16px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: pre; widows: 1; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: #ffffff;"&gt;59 model weight_in_Kilograms=a0*exp(exp(b0)*(exp(b1*age_in_days)-1)/b1);&lt;/DIV&gt;
&lt;DIV class="sasSource" style="color: #000000; font-family: Consolas, Courier, 'Courier New'; font-size: 16px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: pre; widows: 1; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: #ffffff;"&gt;60 id Animal;&lt;/DIV&gt;
&lt;DIV class="sasSource" style="color: #000000; font-family: Consolas, Courier, 'Courier New'; font-size: 16px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: pre; widows: 1; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: #ffffff;"&gt;61 output out=est_ind1 p=Peso_Predito1 r=resid parms=a0 b0 b1;&lt;/DIV&gt;
&lt;DIV class="sasSource" style="color: #000000; font-family: Consolas, Courier, 'Courier New'; font-size: 16px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: pre; widows: 1; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: #ffffff;"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasSource" style="color: #000000; font-family: Consolas, Courier, 'Courier New'; font-size: 16px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: pre; widows: 1; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: #ffffff;"&gt;thanks&lt;/DIV&gt;</description>
      <pubDate>Sun, 06 Dec 2015 15:54:42 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Using-data-from-2-independent-data-sets/m-p/238013#M12608</guid>
      <dc:creator>jonatan_velarde</dc:creator>
      <dc:date>2015-12-06T15:54:42Z</dc:date>
    </item>
    <item>
      <title>Re: Using data from 2 independent data sets</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Using-data-from-2-independent-data-sets/m-p/238017#M12609</link>
      <description>&lt;P&gt;Interesting. I guess you want the WHERE condition to apply to the data from &lt;SPAN&gt;Sem_data_Negat.&lt;/SPAN&gt;&amp;nbsp;Try moving the where statement BEFORE the PARMS statement.&lt;/P&gt;</description>
      <pubDate>Sun, 06 Dec 2015 18:31:33 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Using-data-from-2-independent-data-sets/m-p/238017#M12609</guid>
      <dc:creator>PGStats</dc:creator>
      <dc:date>2015-12-06T18:31:33Z</dc:date>
    </item>
    <item>
      <title>Re: Using data from 2 independent data sets</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Using-data-from-2-independent-data-sets/m-p/238063#M12612</link>
      <description>&lt;P&gt;You need a BY on your MERGE.&amp;nbsp; This should be the variable that matches between the data sets (ID number or whatever).&amp;nbsp; If no variable matches between data sets then any results you get will be nonsense.&lt;/P&gt;</description>
      <pubDate>Mon, 07 Dec 2015 14:04:43 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Using-data-from-2-independent-data-sets/m-p/238063#M12612</guid>
      <dc:creator>plf515</dc:creator>
      <dc:date>2015-12-07T14:04:43Z</dc:date>
    </item>
    <item>
      <title>Re: Using data from 2 independent data sets</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Using-data-from-2-independent-data-sets/m-p/238097#M12614</link>
      <description>&lt;P&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/15128"&gt;@plf515﻿&lt;/a&gt;, it is not necessarily&amp;nbsp;good practice, but MERGE without BY does exist. It is called One-to-One merging.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="http://support.sas.com/documentation/cdl/en/basess/58133/HTML/default/viewer.htm#a001318478.htm" target="_blank"&gt;http://support.sas.com/documentation/cdl/en/basess/58133/HTML/default/viewer.htm#a001318478.htm&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;It can be convenient for combining single observation datasets (I know, there are other methods).&lt;/P&gt;</description>
      <pubDate>Mon, 07 Dec 2015 16:14:38 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Using-data-from-2-independent-data-sets/m-p/238097#M12614</guid>
      <dc:creator>PGStats</dc:creator>
      <dc:date>2015-12-07T16:14:38Z</dc:date>
    </item>
    <item>
      <title>Re: Using data from 2 independent data sets</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Using-data-from-2-independent-data-sets/m-p/238131#M12620</link>
      <description>&lt;P&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/462"&gt;@PGStats﻿&lt;/a&gt;&amp;nbsp; Yes, I know it exists.&amp;nbsp; But .... I think I heard this in a SGF talk long ago:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If you merge without a by&lt;/P&gt;&lt;P&gt;You'll get strange results and won't know why&lt;/P&gt;</description>
      <pubDate>Mon, 07 Dec 2015 18:44:20 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Using-data-from-2-independent-data-sets/m-p/238131#M12620</guid>
      <dc:creator>plf515</dc:creator>
      <dc:date>2015-12-07T18:44:20Z</dc:date>
    </item>
    <item>
      <title>Re: Using data from 2 independent data sets</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Using-data-from-2-independent-data-sets/m-p/238140#M12621</link>
      <description>&lt;P&gt;I didn't attend that SGF talk, so I don't know the details, but that statement seems to incite unnecessary worry.&amp;nbsp; I regularly use MERGE without a BY statement to horizontally concatenate data that I then use to use in creating ODS graphics. (&lt;A href="http://blogs.sas.com/content/iml/2013/04/22/overlay-custom-curves.html" target="_self"&gt;See the end of this article for a discussion&lt;/A&gt;.) I've never had a problem.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Philosophically, you have to accept that the first observation in data set 'A' might have nothing to do with the first observation in data set 'B'. Of course, I wouldn't do a statistical analysis of the combined data unless I knew that the observations lined up.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Perhaps a more fair poem would be:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;To horizontally concatenate,&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;MERGE without BY is really great.&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;But if the&amp;nbsp;variables don't relate,&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;a statistical analysis is tempting fate.&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 07 Dec 2015 19:15:30 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Using-data-from-2-independent-data-sets/m-p/238140#M12621</guid>
      <dc:creator>Rick_SAS</dc:creator>
      <dc:date>2015-12-07T19:15:30Z</dc:date>
    </item>
  </channel>
</rss>

