<?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, G matrix warning, remove solutions from replications? in Statistical Procedures</title>
    <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-Mixed-G-matrix-warning-remove-solutions-from-replications/m-p/545336#M27282</link>
    <description>&lt;P&gt;Use the ConvergenceStatus table. For a discussion and example, see &lt;A href="https://blogs.sas.com/content/iml/2015/08/26/convergence-sim.html" target="_self"&gt;"Monitor convergence during simulation studies in SAS,"&lt;/A&gt; especially the section "The ConvergenceStatus table".&lt;/P&gt;</description>
    <pubDate>Fri, 22 Mar 2019 17:59:00 GMT</pubDate>
    <dc:creator>Rick_SAS</dc:creator>
    <dc:date>2019-03-22T17:59:00Z</dc:date>
    <item>
      <title>Proc Mixed, G matrix warning, remove solutions from replications?</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-Mixed-G-matrix-warning-remove-solutions-from-replications/m-p/545240#M27278</link>
      <description>&lt;P&gt;I am using SAS 9.4&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am running a proc Mixed and saving the group level residuals for analysis. I am running 1000 replications. Some of the runs result in a estimated G matrix is not positive definite. I understand why this is happening.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Questions:&lt;/P&gt;&lt;P&gt;1. is there a way to report how many of the replications are resulting in the 'estimated G matrix is not positive definite'?&lt;/P&gt;&lt;P&gt;2. is there a way to remove the resulting residual solutions for these cases from the 'solutionr' file?&lt;/P&gt;&lt;P&gt;Is there a way to remove the results from the fit statistics as well?&lt;/P&gt;&lt;P&gt;3. is there a way to continue the replications so the total is 1000 excluding those that result in the non-positive definite matrix?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;here is my code (iter=replication number). :&lt;/P&gt;&lt;P&gt;proc mixed data=fulltestdata covtest;&lt;BR /&gt;by iter;&lt;BR /&gt;class idt idk wave;&lt;BR /&gt;model y = wave / noint s residual ;&lt;BR /&gt;random wave / sub=idt type=un g gcorr solution;&lt;BR /&gt;repeated wave / sub=idk(idt) type=un r rcorr;&lt;BR /&gt;&lt;BR /&gt;ods graphics off; ods output fitstatistics=fit solutionr=MMtchres;&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Sample from the log:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;NOTE: Convergence criteria met.&lt;BR /&gt;NOTE: The above message was for the following BY group:&lt;BR /&gt;iter=731&lt;BR /&gt;NOTE: Convergence criteria met.&lt;BR /&gt;NOTE: The above message was for the following BY group:&lt;BR /&gt;iter=732&lt;BR /&gt;NOTE: Convergence criteria met.&lt;BR /&gt;NOTE: The above message was for the following BY group:&lt;BR /&gt;iter=733&lt;BR /&gt;NOTE: Convergence criteria met.&lt;BR /&gt;NOTE: Estimated G matrix is not positive definite.&lt;BR /&gt;NOTE: The above message was for the following BY group:&lt;BR /&gt;iter=734&lt;BR /&gt;NOTE: Convergence criteria met.&lt;BR /&gt;NOTE: The above message was for the following BY group:&lt;BR /&gt;iter=735&lt;BR /&gt;NOTE: Convergence criteria met.&lt;BR /&gt;NOTE: The above message was for the following BY group:&lt;BR /&gt;iter=736&lt;/P&gt;</description>
      <pubDate>Fri, 22 Mar 2019 14:50:35 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-Mixed-G-matrix-warning-remove-solutions-from-replications/m-p/545240#M27278</guid>
      <dc:creator>avanwie</dc:creator>
      <dc:date>2019-03-22T14:50:35Z</dc:date>
    </item>
    <item>
      <title>Re: Proc Mixed, G matrix warning, remove solutions from replications?</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-Mixed-G-matrix-warning-remove-solutions-from-replications/m-p/545336#M27282</link>
      <description>&lt;P&gt;Use the ConvergenceStatus table. For a discussion and example, see &lt;A href="https://blogs.sas.com/content/iml/2015/08/26/convergence-sim.html" target="_self"&gt;"Monitor convergence during simulation studies in SAS,"&lt;/A&gt; especially the section "The ConvergenceStatus table".&lt;/P&gt;</description>
      <pubDate>Fri, 22 Mar 2019 17:59:00 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-Mixed-G-matrix-warning-remove-solutions-from-replications/m-p/545336#M27282</guid>
      <dc:creator>Rick_SAS</dc:creator>
      <dc:date>2019-03-22T17:59:00Z</dc:date>
    </item>
    <item>
      <title>Re: Proc Mixed, G matrix warning, remove solutions from replications?</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-Mixed-G-matrix-warning-remove-solutions-from-replications/m-p/545604#M27290</link>
      <description>&lt;P&gt;Thanks. The model did converge so the Convergence status table with reasons doesn't help.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The log:&lt;/P&gt;&lt;P&gt;222&lt;BR /&gt;223 proc mixed data=fulltestdata covtest;&lt;BR /&gt;224 by iter;&lt;BR /&gt;225 class idt idk wave;&lt;BR /&gt;226 model y = wave / noint s residual ;&lt;BR /&gt;227 random wave / sub=idt type=un g gcorr solution;&lt;BR /&gt;228 repeated wave / sub=idk(idt) type=un r rcorr;&lt;BR /&gt;229&lt;BR /&gt;230 ods graphics off; ods output fitstatistics=fit solutionr=MMtchres ConvergenceStatus=CS;&lt;BR /&gt;231 run;&lt;/P&gt;&lt;P&gt;NOTE: Convergence criteria met.&lt;BR /&gt;NOTE: Estimated G matrix is not positive definite.&lt;BR /&gt;NOTE: The above message was for the following BY group:&lt;BR /&gt;iter=1&lt;BR /&gt;NOTE: Convergence criteria met.&lt;BR /&gt;NOTE: Estimated G matrix is not positive definite.&lt;BR /&gt;NOTE: The above message was for the following BY group:&lt;BR /&gt;iter=2&lt;BR /&gt;NOTE: The data set WORK.CS has 2 observations and 5 variables.&lt;BR /&gt;NOTE: The data set WORK.MMTCHRES has 90 observations and 9 variables.&lt;BR /&gt;NOTE: The data set WORK.FIT has 8 observations and 3 variables.&lt;BR /&gt;NOTE: PROCEDURE MIXED used (Total process time):&lt;BR /&gt;real time 0.64 seconds&lt;BR /&gt;cpu time 0.61 seconds&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Screen Shot 2019-03-24 at 11.02.54 AM.png" style="width: 451px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/28158iE4D9A8D252C3B1DC/image-size/large?v=v2&amp;amp;px=999" role="button" title="Screen Shot 2019-03-24 at 11.02.54 AM.png" alt="Screen Shot 2019-03-24 at 11.02.54 AM.png" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Sun, 24 Mar 2019 15:03:32 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-Mixed-G-matrix-warning-remove-solutions-from-replications/m-p/545604#M27290</guid>
      <dc:creator>avanwie</dc:creator>
      <dc:date>2019-03-24T15:03:32Z</dc:date>
    </item>
    <item>
      <title>Re: Proc Mixed, G matrix warning, remove solutions from replications?</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-Mixed-G-matrix-warning-remove-solutions-from-replications/m-p/545917#M27296</link>
      <description>&lt;P&gt;When you use ODS OUTPUT, it creates a SAS data set which contains "non-printing columns" for the table.&lt;/P&gt;
&lt;P&gt;In particular, if you look at the variables in the ConvergenceStatus table (PROC CONTENTS), you will see that one of the variables is&lt;/P&gt;
&lt;P&gt;pdG which stands for "positive definite gradient."&lt;/P&gt;
&lt;P&gt;This is a binary indicator variable. You can use a WHERE clause such as&amp;nbsp;&lt;/P&gt;
&lt;P&gt;WHERE=(pdG = 1)&lt;/P&gt;
&lt;P&gt;to obtain only the samples for which the gradient at the solution was positive definite.&lt;/P&gt;</description>
      <pubDate>Mon, 25 Mar 2019 18:29:15 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-Mixed-G-matrix-warning-remove-solutions-from-replications/m-p/545917#M27296</guid>
      <dc:creator>Rick_SAS</dc:creator>
      <dc:date>2019-03-25T18:29:15Z</dc:date>
    </item>
  </channel>
</rss>

