<?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: paired t-test with complex survey data in Statistical Procedures</title>
    <link>https://communities.sas.com/t5/Statistical-Procedures/paired-t-test-with-complex-survey-data/m-p/430766#M22646</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/155173"&gt;@SAS_Rob&lt;/a&gt;&amp;nbsp;, could you provide a bit of guidance please? I've been searching all over and am having trouble!&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Suppose I want to see if a teacher used textbook1 in 2015 and in 2017. I created a difference variable, called t1.&lt;/P&gt;
&lt;P&gt;diff_t1 = textbook1_use_2017 - textbook1_use_2015.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;so t1 is my difference variable. I have my survey weight variable, call it "weights."&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;How can I test this in surveymeans? I found some documentation saying to use the domain statement, but that doesn't apply here.&lt;/P&gt;
&lt;PRE&gt;proc surveymeans data = dataset;
 	weight weighst;
	var diff_t1;
run;&lt;/PRE&gt;
&lt;P&gt;I don't think I can use surveyreg because I'd need to incorporate fixed and random effects if I ran a model. Please advise.&lt;/P&gt;
&lt;P&gt;Thanks!&lt;/P&gt;</description>
    <pubDate>Thu, 25 Jan 2018 03:40:23 GMT</pubDate>
    <dc:creator>ginak</dc:creator>
    <dc:date>2018-01-25T03:40:23Z</dc:date>
    <item>
      <title>paired t-test with complex survey data</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/paired-t-test-with-complex-survey-data/m-p/407286#M21202</link>
      <description>&lt;P&gt;Does anyone have a procedure in mind for longitudinal analysis of ordinal data from a complex survey? For this particular outcome, I'd use proc ttest with a paired statement for the first two time points and repeated measures ANOVA for 3 or more time points BUT I am using complex survey data and need to use one of the PROCSURVEY... procedures.&amp;nbsp;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 25 Oct 2017 14:16:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/paired-t-test-with-complex-survey-data/m-p/407286#M21202</guid>
      <dc:creator>Bren</dc:creator>
      <dc:date>2017-10-25T14:16:40Z</dc:date>
    </item>
    <item>
      <title>Re: paired t-test with complex survey data</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/paired-t-test-with-complex-survey-data/m-p/407437#M21209</link>
      <description>&lt;P&gt;To do a paired t-test you could simply create a difference variable and then use Proc SURVEYMEANS on that variable&lt;/P&gt;</description>
      <pubDate>Wed, 25 Oct 2017 19:22:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/paired-t-test-with-complex-survey-data/m-p/407437#M21209</guid>
      <dc:creator>SAS_Rob</dc:creator>
      <dc:date>2017-10-25T19:22:40Z</dc:date>
    </item>
    <item>
      <title>Re: paired t-test with complex survey data</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/paired-t-test-with-complex-survey-data/m-p/430766#M22646</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/155173"&gt;@SAS_Rob&lt;/a&gt;&amp;nbsp;, could you provide a bit of guidance please? I've been searching all over and am having trouble!&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Suppose I want to see if a teacher used textbook1 in 2015 and in 2017. I created a difference variable, called t1.&lt;/P&gt;
&lt;P&gt;diff_t1 = textbook1_use_2017 - textbook1_use_2015.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;so t1 is my difference variable. I have my survey weight variable, call it "weights."&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;How can I test this in surveymeans? I found some documentation saying to use the domain statement, but that doesn't apply here.&lt;/P&gt;
&lt;PRE&gt;proc surveymeans data = dataset;
 	weight weighst;
	var diff_t1;
run;&lt;/PRE&gt;
&lt;P&gt;I don't think I can use surveyreg because I'd need to incorporate fixed and random effects if I ran a model. Please advise.&lt;/P&gt;
&lt;P&gt;Thanks!&lt;/P&gt;</description>
      <pubDate>Thu, 25 Jan 2018 03:40:23 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/paired-t-test-with-complex-survey-data/m-p/430766#M22646</guid>
      <dc:creator>ginak</dc:creator>
      <dc:date>2018-01-25T03:40:23Z</dc:date>
    </item>
    <item>
      <title>Re: paired t-test with complex survey data</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/paired-t-test-with-complex-survey-data/m-p/430915#M22656</link>
      <description>&lt;P&gt;Assuming that the two variables you are taking the difference of are continuous and you don't also have strata and clusters then that code should give you what you want.&lt;/P&gt;</description>
      <pubDate>Thu, 25 Jan 2018 14:05:07 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/paired-t-test-with-complex-survey-data/m-p/430915#M22656</guid>
      <dc:creator>SAS_Rob</dc:creator>
      <dc:date>2018-01-25T14:05:07Z</dc:date>
    </item>
    <item>
      <title>Re: paired t-test with complex survey data</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/paired-t-test-with-complex-survey-data/m-p/599959#M29183</link>
      <description>&lt;P&gt;Thanks &lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/155173"&gt;@SAS_Rob&lt;/a&gt;&amp;nbsp;- Using PROC SURVEYMEANS worked to test differences between groups over time.&amp;nbsp; But I'm back with a new twist.&amp;nbsp; How do I test a Time 1 to Time 2 difference in a&amp;nbsp;continuous variable within a group using complex survey data?&amp;nbsp; How about three or more time points?&lt;/P&gt;</description>
      <pubDate>Tue, 29 Oct 2019 01:01:22 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/paired-t-test-with-complex-survey-data/m-p/599959#M29183</guid>
      <dc:creator>Bren</dc:creator>
      <dc:date>2019-10-29T01:01:22Z</dc:date>
    </item>
    <item>
      <title>Re: paired t-test with complex survey data</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/paired-t-test-with-complex-survey-data/m-p/600056#M29184</link>
      <description>&lt;P&gt;If the data are non-normal then what distribution would you use to describe them?&amp;nbsp; In this case it is likely that you would need to take a modeling approach if you are going to use SAS.&amp;nbsp; If the distribution comes from an exponential family then you could use a MACRO that is linked below that uses replicate weights in GENMOD.&lt;/P&gt;
&lt;P&gt;&lt;A href="https://support.sas.com/rnd/app/stat/examples/SurveyPoisson/surveypoisson.htm" target="_blank"&gt;https://support.sas.com/rnd/app/stat/examples/SurveyPoisson/surveypoisson.htm&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I don't see why you couldn't use different DIST= LINK= options for other distributions and link functions (you would need to modify the&amp;nbsp;&lt;/P&gt;
&lt;P&gt;MACRO code MODEL statement, but the idea should still hold.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 29 Oct 2019 13:17:18 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/paired-t-test-with-complex-survey-data/m-p/600056#M29184</guid>
      <dc:creator>SAS_Rob</dc:creator>
      <dc:date>2019-10-29T13:17:18Z</dc:date>
    </item>
    <item>
      <title>Re: paired t-test with complex survey data</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/paired-t-test-with-complex-survey-data/m-p/600074#M29186</link>
      <description>&lt;P&gt;Any suggestions for normally distributed data? I have a time 1 and time 2 continuous measure (paired) and I am hoping to test if time 2 is different from time 1.&amp;nbsp; I'd do a paired t test if I wasn't using complex survey data. So far the only thing I've found is PROC SURVEYMEANS with the T option, but I don't know is that is comparing a group mean or if it is the equivalent of a paired t test.&amp;nbsp; Do you know? To use PROC SURVEYMEANS with the T option, I calculate the difference between time 1 and 2 and the T option compares that difference from no change (Null hypothesis).&lt;/P&gt;</description>
      <pubDate>Tue, 29 Oct 2019 14:12:43 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/paired-t-test-with-complex-survey-data/m-p/600074#M29186</guid>
      <dc:creator>Bren</dc:creator>
      <dc:date>2019-10-29T14:12:43Z</dc:date>
    </item>
  </channel>
</rss>

