<?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: Proc mixed unbalanced data in animal science with multiple variables in Statistical Procedures</title>
    <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-mixed-unbalanced-data-in-animal-science-with-multiple/m-p/642811#M30757</link>
    <description>I have conducted a study on checking the effect of of 4 stocking rates (1 animal per pen, 2 animals per pen, 4 Animals per pen and 8 animals per pen) on feed intake. I had 3 feeds offered at the same quantity on a pen with same space on 4 periods. I wamt to know how stocking rate affected feed intake of each feed. Periods are repeated measures and grouping of animals is random, I have animal Identies for each period . How can I go about the commands.</description>
    <pubDate>Fri, 24 Apr 2020 22:44:09 GMT</pubDate>
    <dc:creator>Pepeta</dc:creator>
    <dc:date>2020-04-24T22:44:09Z</dc:date>
    <item>
      <title>Proc mixed unbalanced data in animal science with multiple variables</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-mixed-unbalanced-data-in-animal-science-with-multiple/m-p/550997#M27483</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;I am analysing the interaction of lunar phases on feed intake(DMINT), water intake(WI), milk yield(MY) and body weight (Live_wgt) on cattle. I have data from 2012-2016. There are +-200 cows. The cows are divided into two genetic groups (C and S), then they are subdivided into 2 feeding type groups (XB and XH). I am trying to see if there is a significant interaction between LunarPhase and the 4 variables or could this interaction be an effect of the variables on each other.&amp;nbsp; My data is unbalanced, so proc mixed was seen as a more useful procedure. There are fixed effects: Eartag (animal ID),&amp;nbsp; Date, Parity(LactNo) Days in milk (DIM) Season, Year, system (Genetic group*feeding type), and Weight (live_wgt).&amp;nbsp; With focusing on feed intake (DMINT) as an example, I have been using the code;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;proc mixed data=MYdata PLOTS (maxpoints=9000);&lt;/P&gt;&lt;P&gt;class EARTAG Date LunarPhase Season DIM Year Lactno System Live_weight;&lt;/P&gt;&lt;P&gt;model DMINT=LunarPhase DIM Season*Year Lactno System Live_weight/ s;&lt;/P&gt;&lt;P&gt;random EARTAG*Lactno;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Now my question is that when I am trying to look at the relationship and add MY to my model it says that there is an error issue. How do I make this code work, what am I doing wrong, what procedure could I use to fix this?&lt;/P&gt;</description>
      <pubDate>Mon, 15 Apr 2019 11:13:41 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-mixed-unbalanced-data-in-animal-science-with-multiple/m-p/550997#M27483</guid>
      <dc:creator>ghannah5</dc:creator>
      <dc:date>2019-04-15T11:13:41Z</dc:date>
    </item>
    <item>
      <title>Re: Proc mixed unbalanced data in animal science with multiple variables</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-mixed-unbalanced-data-in-animal-science-with-multiple/m-p/551205#M27488</link>
      <description>&lt;P&gt;If I am understanding you correctly, you are trying to add 'MY' next to 'DMINT' in the model statement. If this is the case, the syntax is wrong. You need to use different models for different outcomes:&amp;nbsp;&lt;SPAN&gt;feed intake(DMINT), water intake(WI), milk yield(MY) and body weight (Live_wgt). The outcomes need to be continuous. In other words, you cannot simultaneously examine the effect of lunar phase / other interactions on all outcomes at once.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Rajesh.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 15 Apr 2019 19:12:17 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-mixed-unbalanced-data-in-animal-science-with-multiple/m-p/551205#M27488</guid>
      <dc:creator>Rajesh3</dc:creator>
      <dc:date>2019-04-15T19:12:17Z</dc:date>
    </item>
    <item>
      <title>Re: Proc mixed unbalanced data in animal science with multiple variables</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-mixed-unbalanced-data-in-animal-science-with-multiple/m-p/551331#M27494</link>
      <description>Basically I know through literature that milk yield is effected by DMINT&lt;BR /&gt;and LunarPhase has an effect with DMINT. So how would I include that in my&lt;BR /&gt;model? Or should I just create another model in order to analyse this&lt;BR /&gt;relationship between DMINT and MY?&lt;BR /&gt;</description>
      <pubDate>Tue, 16 Apr 2019 09:45:18 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-mixed-unbalanced-data-in-animal-science-with-multiple/m-p/551331#M27494</guid>
      <dc:creator>ghannah5</dc:creator>
      <dc:date>2019-04-16T09:45:18Z</dc:date>
    </item>
    <item>
      <title>Re: Proc mixed unbalanced data in animal science with multiple variables</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-mixed-unbalanced-data-in-animal-science-with-multiple/m-p/551421#M27505</link>
      <description>&lt;P&gt;Yeah. You would need to use two different models for your hypotheses.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;One would be MY=DMINT (Hypothesis: DMINT has an effect on MY). I think you already have the second one.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you,&lt;/P&gt;&lt;P&gt;Rajesh.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 16 Apr 2019 15:36:36 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-mixed-unbalanced-data-in-animal-science-with-multiple/m-p/551421#M27505</guid>
      <dc:creator>Rajesh3</dc:creator>
      <dc:date>2019-04-16T15:36:36Z</dc:date>
    </item>
    <item>
      <title>Re: Proc mixed unbalanced data in animal science with multiple variables</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-mixed-unbalanced-data-in-animal-science-with-multiple/m-p/551530#M27508</link>
      <description>&lt;P&gt;You could consider a structural equation model; for an example, see&amp;nbsp;&lt;A href="https://www.ncbi.nlm.nih.gov/pubmed/29254715" target="_self"&gt;Implementing structural equation models to observational data from feedlot production systems.&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 16 Apr 2019 19:41:16 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-mixed-unbalanced-data-in-animal-science-with-multiple/m-p/551530#M27508</guid>
      <dc:creator>sld</dc:creator>
      <dc:date>2019-04-16T19:41:16Z</dc:date>
    </item>
    <item>
      <title>Re: Proc mixed unbalanced data in animal science with multiple variables</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-mixed-unbalanced-data-in-animal-science-with-multiple/m-p/642811#M30757</link>
      <description>I have conducted a study on checking the effect of of 4 stocking rates (1 animal per pen, 2 animals per pen, 4 Animals per pen and 8 animals per pen) on feed intake. I had 3 feeds offered at the same quantity on a pen with same space on 4 periods. I wamt to know how stocking rate affected feed intake of each feed. Periods are repeated measures and grouping of animals is random, I have animal Identies for each period . How can I go about the commands.</description>
      <pubDate>Fri, 24 Apr 2020 22:44:09 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-mixed-unbalanced-data-in-animal-science-with-multiple/m-p/642811#M30757</guid>
      <dc:creator>Pepeta</dc:creator>
      <dc:date>2020-04-24T22:44:09Z</dc:date>
    </item>
    <item>
      <title>Re: Proc mixed unbalanced data in animal science with multiple variables</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-mixed-unbalanced-data-in-animal-science-with-multiple/m-p/643189#M30799</link>
      <description>&lt;P&gt;If you have a new question, I recommend starting a new thread. If you tap into an old thread, especially if it has already been answered, people may overlook your question.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Do you have intake data for each of the 3 feeds for each &lt;EM&gt;animal&lt;/EM&gt; for each period, or do you have intake data for each of the 3 feeds for each &lt;EM&gt;pen&lt;/EM&gt; for each period?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Was the amount of feed provided in the pen with 8 animals the same absolute quantity as the amount in the pen with 1 animal, or was it 8 times the amount? Did each pen eat appreciably less than the amount of each feed provided, or did the amount of feed provided impose some sort of constraint on consumption? For example, the pen ate all of its favorite feed and then moved to a less favored feed.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Are you pondering &lt;EM&gt;feed preference&lt;/EM&gt; (in other words, preferential consumption of some feeds over others) as a consequence of stocking rate, as opposed to &lt;EM&gt;total consumption&lt;/EM&gt; as a consequence of stocking rate? Do you plan to analyze consumption/preference of each feed separately? Or are you looking at compositional consumption (in other words, joint consumption of the three feeds, which might be thought of as diet allocation)?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;How many pens did you have for each stocking rate?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In this study, pen is the experimental unit for stocking rate. It is not uncommon for people to think of animal as the experimental unit, but that is an incorrect assumption. Consequently, any measurements that you have on individual animals within a pen should be considered to be subsamples rather than true replicates. Plus, typically in studies like this, you have consumption by pen and not by individual animal within a pen.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Once we have a better understanding of your study, we can help you with your code. But you'll need to show what you've tried so far to give us something to work from.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;And I have to ask, without intending to be mean but intending to point out the importance of &lt;EM&gt;planning ahead&lt;/EM&gt;, Why did you not think about analysis before you collected your data? (You are definitely not alone in that approach, but it really is not in anyone's best interest.)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I hope this provides some clarity. Please follow up as need be.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 27 Apr 2020 04:01:19 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-mixed-unbalanced-data-in-animal-science-with-multiple/m-p/643189#M30799</guid>
      <dc:creator>sld</dc:creator>
      <dc:date>2020-04-27T04:01:19Z</dc:date>
    </item>
    <item>
      <title>Re: Proc mixed unbalanced data in animal science with multiple variables</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-mixed-unbalanced-data-in-animal-science-with-multiple/m-p/643225#M30802</link>
      <description>I am looking at diet selection the proportion of each feed consumes. The feeds were provided ad libitum they were offered in the morning and feeders were filled up in the evening to ensure adlibitum availability. There was one pen per stocking rate.&lt;BR /&gt;The commands i wrote are as follows:&lt;BR /&gt;&lt;BR /&gt;DATA Pepeta;&lt;BR /&gt;Input ........period treatment initial body weight group animalID proportionEaten feed;&lt;BR /&gt;Cards;&lt;BR /&gt;.&lt;BR /&gt;.&lt;BR /&gt;.&lt;BR /&gt;;&lt;BR /&gt;run;&lt;BR /&gt;Proc sort;&lt;BR /&gt;by feed;&lt;BR /&gt;Proc mixed data = Pepeta;&lt;BR /&gt;Class period animlID treat;&lt;BR /&gt;Model proportionEaten = treat Initial body weight;&lt;BR /&gt;By feed;&lt;BR /&gt;Eandom group (anImalID);&lt;BR /&gt;Repeated period:;.lsmeans treat/pdiff adjust=Tuckey;</description>
      <pubDate>Mon, 27 Apr 2020 09:36:12 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-mixed-unbalanced-data-in-animal-science-with-multiple/m-p/643225#M30802</guid>
      <dc:creator>Pepeta</dc:creator>
      <dc:date>2020-04-27T09:36:12Z</dc:date>
    </item>
    <item>
      <title>Re: Proc mixed unbalanced data in animal science with multiple variables</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-mixed-unbalanced-data-in-animal-science-with-multiple/m-p/643303#M30813</link>
      <description>&lt;P&gt;You say that there was one pen per stocking rate. To clarify, does that mean that you had 4 pens in total, and 1 + 2 + 4 + 8 = 15 animals?&lt;/P&gt;</description>
      <pubDate>Mon, 27 Apr 2020 14:26:08 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-mixed-unbalanced-data-in-animal-science-with-multiple/m-p/643303#M30813</guid>
      <dc:creator>sld</dc:creator>
      <dc:date>2020-04-27T14:26:08Z</dc:date>
    </item>
    <item>
      <title>Re: Proc mixed unbalanced data in animal science with multiple variables</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-mixed-unbalanced-data-in-animal-science-with-multiple/m-p/643304#M30814</link>
      <description>&lt;P&gt;This is going to sound harsh, but you have no ability to estimate the error around the experimental unit with only one observation per unit.&amp;nbsp; Unless I misunderstood your design, you have a total of four pens, each with a different number of animals. Any results you get by considering animal as the experimental unit are likely to be suspect.&lt;/P&gt;
&lt;P&gt;Additionally, your response variable is a proportion, not an amount, so the variable likely has a beta distribution (ratio of two random variables) rather than a distribution with normal random errors (Gaussian). Consider modeling amount of each feed type per head per day.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;But the real issue is replication.&amp;nbsp; Unless you replicate the experimental units, your analysis is going to be suspect.&amp;nbsp; This was the point&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/1708"&gt;@sld&lt;/a&gt;&amp;nbsp;made.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;SteveDenahm&lt;/P&gt;</description>
      <pubDate>Mon, 27 Apr 2020 14:31:36 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-mixed-unbalanced-data-in-animal-science-with-multiple/m-p/643304#M30814</guid>
      <dc:creator>SteveDenham</dc:creator>
      <dc:date>2020-04-27T14:31:36Z</dc:date>
    </item>
    <item>
      <title>Re: Proc mixed unbalanced data in animal science with multiple variables</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-mixed-unbalanced-data-in-animal-science-with-multiple/m-p/643308#M30815</link>
      <description>&lt;P&gt;Sheesh.&amp;nbsp; Always read before hitting send.&lt;/P&gt;
&lt;P&gt;I said: "&lt;SPAN&gt;you have no ability to estimate the error around the experimental unit with only one observation per unit."&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;I should have said:&amp;nbsp;you have no ability to estimate the error associated with treatment effects based on the pen as the experimental unit with only one pen per treatment.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;And an answer to&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/1708"&gt;@sld&lt;/a&gt;&amp;nbsp;'s question would really help us help you.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;SteveDenham&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 27 Apr 2020 14:41:36 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-mixed-unbalanced-data-in-animal-science-with-multiple/m-p/643308#M30815</guid>
      <dc:creator>SteveDenham</dc:creator>
      <dc:date>2020-04-27T14:41:36Z</dc:date>
    </item>
  </channel>
</rss>

