<?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 MODEL Warning: For covariance type Unstructured in Statistical Procedures</title>
    <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/741205#M36020</link>
    <description>&lt;P&gt;It is not obvious to me what the problem might be.&amp;nbsp; At first I thought you may be trying to estimate too many parameters in the UN structure, but as you have it written you should get a single parameter estimate called UN(1,1).&amp;nbsp; The mysterious part of all this is that there are no other relevant NOTEs, WARNINGs or ERRORs in the log.&amp;nbsp; There may be something in the .lst file that would help explain what is happening.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I would like to push this to some folks who are really good with this sort of thing, so&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/60873"&gt;@jiltao&lt;/a&gt;&amp;nbsp;,&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/330163"&gt;@STAT_Kathleen&lt;/a&gt;&amp;nbsp;, you guys have helped me in the past, so please give&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/332984"&gt;@cjacks21&lt;/a&gt;&amp;nbsp; something to work with.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;SteveDenham&lt;/P&gt;</description>
    <pubDate>Thu, 13 May 2021 18:22:52 GMT</pubDate>
    <dc:creator>SteveDenham</dc:creator>
    <dc:date>2021-05-13T18:22:52Z</dc:date>
    <item>
      <title>Proc MIXED MODEL Warning: For covariance type Unstructured</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/740919#M36019</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am having trouble getting the result I need from my proc mixed models. I am comparing 3 different types but for some reason my Proc Mixed model with the covariance structure Type=un (unstructured) ran and I add the intercept on the random line the result are an warning, the solution LSMEANS is missing, and no out put of my predicted values. For the proc mixed model type= cs everything is fine with the intercept added. I attached the output to this post and the code and code log is below. What do I need to change for me to used intercept and year in my un proc mixed model?&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;NOTE: 7898 observations are not included because of missing values.&lt;BR /&gt;NOTE: The data set WORK.PRED has 0 observations and 0 variables.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;------&amp;gt;WARNING: Data set WORK.PRED was not replaced because new file is incomplete.&amp;lt;-----&lt;/STRONG&gt;&lt;BR /&gt;NOTE: PROCEDURE MIXED used (Total process time):&lt;BR /&gt;real time 0.88 seconds&lt;BR /&gt;cpu time 0.68 seconds&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;SAS Code:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc sort data = youthavgvl_yr out= youthavgvl_yr_sorted nodupkey; *remove duplicates;
by rfa_id year time avgvlyryouth; 
run;
*When I ran the procedure without adding intercept or int after random the output showed everything but with it some outputs where
cut out;
PROC MIXED data= youthavgvl_yr_sorted covtest noitprint method=reml PLOTS(MAXPOINTS=NONE);
    class   sex_hars (ref="F") res_at_hiv_dx (ref="Urban") race_combined (ref="Black") hiv_risk (ref="MSM") baseline_cd4 (ref="&amp;gt; 500") agegroup(ref="20-24");
    model avgvlyryouth= year ccd4c ctimeyr sex_hars res_at_hiv_dx race_combined hiv_risk baseline_cd4 
			agegroup ccd4c*sex_hars ccd4c*res_at_hiv_dx ccd4c*race_combined ccd4c*hiv_risk ccd4c*baseline_cd4 
			ccd4c*agegroup ctimeyr*sex_hars ctimeyr*res_at_hiv_dx ctimeyr*race_combined ctimeyr*hiv_risk 
			ctimeyr*baseline_cd4 ctimeyr*agegroup/ solution outp = pred;
	random intercept / subject=rfa_id Type= un;
	lsmeans sex_hars res_at_hiv_dx race_combined hiv_risk baseline_cd4 agegroup /diff;
title 'Mixed Model Test for Youth Unstructured';
RUN;

proc sort data = youthavgvl_yr out= youthavgvl_yr_sorted nodupkey; *remove duplicates;
by rfa_id year time avgvlyryouth; 
run;

PROC MIXED data= youthavgvl_yr_sorted order=data PLOTS(MAXPOINTS=NONE);
    class   sex_hars (ref="F") res_at_hiv_dx (ref="Urban") race_combined (ref="Black") hiv_risk (ref="MSM") baseline_cd4 (ref="&amp;gt; 500") agegroup(ref="20-24");
    model avgvlyryouth= year ccd4c ctimeyr sex_hars res_at_hiv_dx race_combined hiv_risk baseline_cd4 
			agegroup ccd4c*sex_hars ccd4c*res_at_hiv_dx ccd4c*race_combined ccd4c*hiv_risk ccd4c*baseline_cd4 
			ccd4c*agegroup ctimeyr*sex_hars ctimeyr*res_at_hiv_dx ctimeyr*race_combined ctimeyr*hiv_risk 
			ctimeyr*baseline_cd4 ctimeyr*agegroup/ solution outp = pred_cs;
	random  intercept year / subject=rfa_id Type= cs;
	lsmeans sex_hars res_at_hiv_dx race_combined hiv_risk baseline_cd4 agegroup /diff;
title 'Mixed Model Test for Youth Compound Symmetry';
RUN;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;SAS log:&lt;/P&gt;&lt;P&gt;&lt;CODE class=" language-sas"&gt;&lt;/CODE&gt;&lt;/P&gt;&lt;P&gt;&lt;CODE class=" language-sas"&gt;&lt;/CODE&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;SAS log

458  proc sort data = youthavgvl_yr out= youthavgvl_yr_sorted nodupkey; *remove duplicates;
459  by rfa_id year time avgvlyryouth;
460  run;

NOTE: There were 57534 observations read from the data set WORK.YOUTHAVGVL_YR.
NOTE: 10467 observations with duplicate key values were deleted.
NOTE: The data set WORK.YOUTHAVGVL_YR_SORTED has 47067 observations and 19 variables.
NOTE: PROCEDURE SORT used (Total process time):
      real time           0.04 seconds
      cpu time            0.04 seconds


461  *When I ran the procedure without adding intercept or int after random the output showed
461! everything but with it some outputs where
462  cut out;
463  PROC MIXED data= youthavgvl_yr_sorted covtest noitprint method=reml PLOTS(MAXPOINTS=NONE);
464      class   sex_hars (ref="F") res_at_hiv_dx (ref="Urban") race_combined (ref="Black")
464! hiv_risk (ref="MSM") baseline_cd4 (ref="&amp;gt; 500") agegroup(ref="20-24");
465      model avgvlyryouth= year ccd4c ctimeyr sex_hars res_at_hiv_dx race_combined hiv_risk
465! baseline_cd4
466              agegroup ccd4c*sex_hars ccd4c*res_at_hiv_dx ccd4c*race_combined ccd4c*hiv_risk
466!  ccd4c*baseline_cd4
467              ccd4c*agegroup ctimeyr*sex_hars ctimeyr*res_at_hiv_dx ctimeyr*race_combined
467! ctimeyr*hiv_risk
468              ctimeyr*baseline_cd4 ctimeyr*agegroup/ solution outp = pred;
469      random intercept / subject=rfa_id Type= un;
470      lsmeans sex_hars res_at_hiv_dx race_combined hiv_risk baseline_cd4 agegroup /diff;
471  title 'Mixed Model Test for Youth Unstructured';
472  RUN;

NOTE: 7898 observations are not included because of missing values.&lt;BR /&gt;NOTE: The data set WORK.PRED has 0 observations and 0 variables.&lt;BR /&gt;WARNING: Data set WORK.PRED was not replaced because new file is incomplete.&lt;BR /&gt;NOTE: PROCEDURE MIXED used (Total process time):&lt;BR /&gt;real time 0.88 seconds&lt;BR /&gt;cpu time 0.68 seconds&lt;BR /&gt;&lt;BR /&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;NOTE: PROCEDURE MIXED used (Total process time):
      real time           0.88 seconds
      cpu time            0.68 seconds


473
474  proc sort data = youthavgvl_yr out= youthavgvl_yr_sorted nodupkey; *remove duplicates;
475  by rfa_id year time avgvlyryouth;
476  run;

NOTE: There were 57534 observations read from the data set WORK.YOUTHAVGVL_YR.
NOTE: 10467 observations with duplicate key values were deleted.
NOTE: The data set WORK.YOUTHAVGVL_YR_SORTED has 47067 observations and 19 variables.
NOTE: PROCEDURE SORT used (Total process time):
      real time           0.04 seconds
      cpu time            0.04 seconds


477
478  PROC MIXED data= youthavgvl_yr_sorted order=data PLOTS(MAXPOINTS=NONE);
479      class   sex_hars (ref="F") res_at_hiv_dx (ref="Urban") race_combined (ref="Black")
479! hiv_risk (ref="MSM") baseline_cd4 (ref="&amp;gt; 500") agegroup(ref="20-24");
480      model avgvlyryouth= year ccd4c ctimeyr sex_hars res_at_hiv_dx race_combined hiv_risk
480! baseline_cd4
481              agegroup ccd4c*sex_hars ccd4c*res_at_hiv_dx ccd4c*race_combined ccd4c*hiv_risk
481!  ccd4c*baseline_cd4
482              ccd4c*agegroup ctimeyr*sex_hars ctimeyr*res_at_hiv_dx ctimeyr*race_combined
482! ctimeyr*hiv_risk
483              ctimeyr*baseline_cd4 ctimeyr*agegroup/ solution outp = pred_cs;
484      random  intercept year / subject=rfa_id Type= cs;
485      lsmeans sex_hars res_at_hiv_dx race_combined hiv_risk baseline_cd4 agegroup /diff;
486  title 'Mixed Model Test for Youth Compound Symmetry';
487  RUN;

NOTE: 7898 observations are not included because of missing values.
NOTE: Convergence criteria met.
NOTE: Estimated G matrix is not positive definite.
NOTE: The data set WORK.PRED_CS has 47067 observations and 26 variables.
NOTE: PROCEDURE MIXED used (Total process time):
      real time           50.90 seconds
      cpu time            50.49 seconds&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;CODE class=" language-sas"&gt;&lt;/CODE&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 12 May 2021 19:46:04 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/740919#M36019</guid>
      <dc:creator>cjacks21</dc:creator>
      <dc:date>2021-05-12T19:46:04Z</dc:date>
    </item>
    <item>
      <title>Re: Proc MIXED MODEL Warning: For covariance type Unstructured</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/741205#M36020</link>
      <description>&lt;P&gt;It is not obvious to me what the problem might be.&amp;nbsp; At first I thought you may be trying to estimate too many parameters in the UN structure, but as you have it written you should get a single parameter estimate called UN(1,1).&amp;nbsp; The mysterious part of all this is that there are no other relevant NOTEs, WARNINGs or ERRORs in the log.&amp;nbsp; There may be something in the .lst file that would help explain what is happening.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I would like to push this to some folks who are really good with this sort of thing, so&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/60873"&gt;@jiltao&lt;/a&gt;&amp;nbsp;,&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/330163"&gt;@STAT_Kathleen&lt;/a&gt;&amp;nbsp;, you guys have helped me in the past, so please give&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/332984"&gt;@cjacks21&lt;/a&gt;&amp;nbsp; something to work with.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;SteveDenham&lt;/P&gt;</description>
      <pubDate>Thu, 13 May 2021 18:22:52 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/741205#M36020</guid>
      <dc:creator>SteveDenham</dc:creator>
      <dc:date>2021-05-13T18:22:52Z</dc:date>
    </item>
    <item>
      <title>Re: Proc MIXED MODEL Warning: For covariance type Unstructured</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/741210#M36021</link>
      <description>&lt;P&gt;Thank you so much for you help in advance. I have be trouble shooting this for a couple days.&lt;/P&gt;</description>
      <pubDate>Thu, 13 May 2021 18:29:30 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/741210#M36021</guid>
      <dc:creator>cjacks21</dc:creator>
      <dc:date>2021-05-13T18:29:30Z</dc:date>
    </item>
    <item>
      <title>Re: Proc MIXED MODEL Warning: For covariance type Unstructured</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/741237#M36022</link>
      <description>&lt;P&gt;If you want to fit a random intercept model, you might want to use --&lt;/P&gt;
&lt;LI-CODE lang="sas"&gt;random intercept / subject=rfa_id;&lt;/LI-CODE&gt;
&lt;P&gt;If you want to fit a random intercept and slope model, you might want to use --&lt;/P&gt;
&lt;LI-CODE lang="sas"&gt;random intercept year / subject=rfa_id type=un;&lt;/LI-CODE&gt;
&lt;P&gt;I would not use type=CS for a random coefficients model.&lt;/P&gt;
&lt;P&gt;Are you saying that the random intercept model (model 1 above) worked but the random intercept and slope model (model 2 above) did not? What exactly happened for the model 2 above?&lt;/P&gt;</description>
      <pubDate>Thu, 13 May 2021 18:53:48 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/741237#M36022</guid>
      <dc:creator>jiltao</dc:creator>
      <dc:date>2021-05-13T18:53:48Z</dc:date>
    </item>
    <item>
      <title>Re: Proc MIXED MODEL Warning: For covariance type Unstructured</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/741324#M36025</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Hello very close. I am sorry for the confusion.&amp;nbsp; Model 1 is the TYPE= UN and Model 2 = CS.&amp;nbsp; For both models I am trying to use the random intercept and time which equal year on my model.&amp;nbsp; When I use:&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;random intercept year / subject=rfa_id type=un&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;I do not get any outputs. It seems as if the code stops. For the compound symmetry type (model 2)&amp;nbsp; I get a result.&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 14 May 2021 00:28:26 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/741324#M36025</guid>
      <dc:creator>cjacks21</dc:creator>
      <dc:date>2021-05-14T00:28:26Z</dc:date>
    </item>
    <item>
      <title>Re: Proc MIXED MODEL Warning: For covariance type Unstructured</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/741407#M36030</link>
      <description>&lt;P&gt;For the UN structure situation, how many levels of year are in your data?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;SteveDenham&lt;/P&gt;</description>
      <pubDate>Fri, 14 May 2021 12:34:28 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/741407#M36030</guid>
      <dc:creator>SteveDenham</dc:creator>
      <dc:date>2021-05-14T12:34:28Z</dc:date>
    </item>
    <item>
      <title>Re: Proc MIXED MODEL Warning: For covariance type Unstructured</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/741442#M36032</link>
      <description>&lt;P&gt;For this model --&lt;/P&gt;
&lt;LI-CODE lang="sas"&gt;random intercept year / subject=rfa_id type=un;&lt;/LI-CODE&gt;
&lt;P&gt;can you send in the Log (including the program and messages) and Output?&lt;/P&gt;</description>
      <pubDate>Fri, 14 May 2021 13:25:34 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/741442#M36032</guid>
      <dc:creator>jiltao</dc:creator>
      <dc:date>2021-05-14T13:25:34Z</dc:date>
    </item>
    <item>
      <title>Re: Proc MIXED MODEL Warning: For covariance type Unstructured</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/741880#M36082</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Yes. The log out put is below for that structure.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;268  proc sort data = youthavgvl_yr out= youthavgvl_yr_sorted nodupkey;
268! *remove duplicates;
269  by rfa_id year time avgvlyryouth;
270  run;

NOTE: There were 57534 observations read from the data set
      WORK.YOUTHAVGVL_YR.
NOTE: 10467 observations with duplicate key values were deleted.
NOTE: The data set WORK.YOUTHAVGVL_YR_SORTED has 47067 observations and
      19 variables.
NOTE: PROCEDURE SORT used (Total process time):
      real time           0.04 seconds
      cpu time            0.03 seconds


271  *When I ran the procedure without adding intercept or int after
271! random the output showed everything but with it some outputs where
272  cut out;
273  PROC MIXED data= youthavgvl_yr_sorted covtest noitprint method=reml
273! PLOTS(MAXPOINTS=NONE);
274      class   sex_hars (ref="F") res_at_hiv_dx (ref="Urban")
274! race_combined (ref="Black") hiv_risk (ref="MSM") baseline_cd4 (ref="&amp;gt;
274!  500") agegroup(ref="20-24");
275      model avgvlyryouth= year ccd4c ctimeyr sex_hars res_at_hiv_dx
275! race_combined hiv_risk baseline_cd4
276              agegroup ccd4c*sex_hars ccd4c*res_at_hiv_dx
276! ccd4c*race_combined ccd4c*hiv_risk ccd4c*baseline_cd4
277              ccd4c*agegroup ctimeyr*sex_hars ctimeyr*res_at_hiv_dx
277! ctimeyr*race_combined ctimeyr*hiv_risk
278              ctimeyr*baseline_cd4 ctimeyr*agegroup/ solution outp =
278! pred_un ;
279      random intercept year/  Type= un subject=rfa_id;
280      *random year / type= un subject= rfa_id;
281      lsmeans sex_hars res_at_hiv_dx race_combined hiv_risk
281! baseline_cd4 agegroup /diff;
282  title 'Mixed Model Test for Youth Unstructured';
283  RUN;

NOTE: 7898 observations are not included because of missing values.
NOTE: The data set WORK.PRED_UN has 0 observations and 0 variables.
NOTE: PROCEDURE MIXED used (Total process time):
      real time           1.21 seconds
      cpu time            0.88 seconds&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 17 May 2021 15:04:31 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/741880#M36082</guid>
      <dc:creator>cjacks21</dc:creator>
      <dc:date>2021-05-17T15:04:31Z</dc:date>
    </item>
    <item>
      <title>Re: Proc MIXED MODEL Warning: For covariance type Unstructured</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/741887#M36083</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I added the year to the class statement in the proc mixed model and for year there are 21 levels.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Courtney Jacks&lt;/P&gt;</description>
      <pubDate>Mon, 17 May 2021 15:16:35 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/741887#M36083</guid>
      <dc:creator>cjacks21</dc:creator>
      <dc:date>2021-05-17T15:16:35Z</dc:date>
    </item>
    <item>
      <title>Re: Proc MIXED MODEL Warning: For covariance type Unstructured</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/741963#M36087</link>
      <description>&lt;P&gt;Please also send the Output from your PROC MIXED program. Thanks!&lt;/P&gt;</description>
      <pubDate>Mon, 17 May 2021 19:15:42 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/741963#M36087</guid>
      <dc:creator>jiltao</dc:creator>
      <dc:date>2021-05-17T19:15:42Z</dc:date>
    </item>
    <item>
      <title>Re: Proc MIXED MODEL Warning: For covariance type Unstructured</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/742190#M36106</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am so sorry. I missed that part of the reply. My Output window was empty but I did have the Result. I attached it to the reply as a word document. The code log is below again:&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;346  ************************************* 1st Proc Mixed Code
346! *****************************************************;
347  *************************************    Youth Part 1
347! *****************************************************;
348  *sort data set with average viral load by rfa_id time and average
348! viral load by year;
349  *proc sort data = youthavgvl_yr out= youthavgvl_yr_sorted nodupkey;
349! *remove duplicates;
350  *by rfa_id year time avgvlyryouth;
351  *run;
352
353  *ods rtf;
354  *Proc mix to look at youth mean viral load by residence, cd4, sex,
354! race, and gender ;
355  * multilevel (ref="Black") hiv_risk (ref="MSM") baseline_cd4 (ref="&amp;gt;
355! 500") agegroup(ref="20-24");
356  *PROC MIXED data= youthavgvl_yr_sorted covtest noitprint method=reml
356! PLOTS(MAXPOINTS=NONE);
357      *class   rfa_id sex_hars (ref="F") res_at_hiv_dx (ref="Urban")
357! race_combined (ref="Black") hiv_risk (ref="MSM") baseline_cd4 (ref="&amp;gt;
357!  500") agegroup(ref="20-24");
358      *model avgvlyryouth = year ccd4c ctimeyr sex_hars res_at_hiv_dx
358! race_combined hiv_risk baseline_cd4 agegroup/ solution outp = pred;
359     * random  int year / subject=rfa_id Type= un vcorr;
360    *title 'Mixed Model Results For Viral Load Trend Over Time For
360! Youth Visits (Reference 1)';
361  *RUN;
362  *ods rtf close;
363
364   *ccd4c*sex_hars ccd4c*res_at_hiv_dx ccd4c*race_combined
364! ccd4c*hiv_risk ccd4c*baseline_cd4 ccd4c*agegroup ctimeyr*sex_hars
364! ctimeyr*res_at_hiv_dx ctimeyr*race_combined ctimeyr*hiv_risk
364! ctimeyr*baseline_cd4 ctimeyr*agegroup
365
366
367  *************************************    Youth Proc Mixed Models
367! *****************************************************;
368  *CJacks notes;
369  *3 proc mixed models where used to determine which TYPE= was the best
369!  for the data analysis of mean vl over time;
370  *TYPE= UN, CS, and AR(1);
371  *sort data set with average viral load by rfa_id time and average
371! viral load by year;
372
373  proc sort data = youthavgvl_yr out= youthavgvl_yr_sorted nodupkey;
373! *remove duplicates;
374  by rfa_id year time avgvlyryouth;
375  run;

NOTE: There were 57534 observations read from the data set
      WORK.YOUTHAVGVL_YR.
NOTE: 10467 observations with duplicate key values were deleted.
NOTE: The data set WORK.YOUTHAVGVL_YR_SORTED has 47067 observations and
      19 variables.
NOTE: PROCEDURE SORT used (Total process time):
      real time           0.04 seconds
      cpu time            0.04 seconds


376  *When I ran the procedure without adding intercept or int after
376! random the output showed everything but with it some outputs where
377  cut out;
378  PROC MIXED data= youthavgvl_yr_sorted covtest noitprint method=reml
378! PLOTS(MAXPOINTS=NONE);
379      class sex_hars (ref="F") res_at_hiv_dx (ref="Urban")
379! race_combined (ref="Black") hiv_risk (ref="MSM") baseline_cd4 (ref="&amp;gt;
379!  500") agegroup(ref="20-24");
380      model avgvlyryouth= year ccd4c ctimeyr sex_hars res_at_hiv_dx
380! race_combined hiv_risk baseline_cd4
381              agegroup ccd4c*sex_hars ccd4c*res_at_hiv_dx
381! ccd4c*race_combined ccd4c*hiv_risk ccd4c*baseline_cd4
382              ccd4c*agegroup ctimeyr*sex_hars ctimeyr*res_at_hiv_dx
382! ctimeyr*race_combined ctimeyr*hiv_risk
383              ctimeyr*baseline_cd4 ctimeyr*agegroup/ solution outp =
383! pred_un ;
384      random intercept year/  Type= un subject=rfa_id;
385      *random year / type= un subject= rfa_id;
386      lsmeans sex_hars res_at_hiv_dx race_combined hiv_risk
386! baseline_cd4 agegroup /diff;
387  title 'Mixed Model Test for Youth Unstructured';
388  RUN;

NOTE: 7898 observations are not included because of missing values.
NOTE: The data set WORK.PRED_UN has 0 observations and 0 variables.
WARNING: Data set WORK.PRED_UN was not replaced because new file is
         incomplete.
NOTE: PROCEDURE MIXED used (Total process time):
      real time           1.21 seconds
      cpu time            0.92 seconds


389  ods rtf close;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 18 May 2021 15:03:14 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/742190#M36106</guid>
      <dc:creator>cjacks21</dc:creator>
      <dc:date>2021-05-18T15:03:14Z</dc:date>
    </item>
    <item>
      <title>Re: Proc MIXED MODEL Warning: For covariance type Unstructured</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/742243#M36108</link>
      <description>&lt;P&gt;Your PROC MIXED program did not converge, and that is why your OUTP= data set is empty.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I wonder if your response variable has very large values. If so you might want to rescale it so the values are within a reasonable range. If you can send in your SAS data set I might take a look to see what I can recommend.&lt;/P&gt;</description>
      <pubDate>Tue, 18 May 2021 17:11:01 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/742243#M36108</guid>
      <dc:creator>jiltao</dc:creator>
      <dc:date>2021-05-18T17:11:01Z</dc:date>
    </item>
    <item>
      <title>Re: Proc MIXED MODEL Warning: For covariance type Unstructured</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/742269#M36114</link>
      <description>Hello,&lt;BR /&gt;&lt;BR /&gt;Okay. I will look into that. The response variable is the viral load which was converted to log_10. I can not send the data set but I will take a look at what you suggested.</description>
      <pubDate>Tue, 18 May 2021 19:29:32 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/742269#M36114</guid>
      <dc:creator>cjacks21</dc:creator>
      <dc:date>2021-05-18T19:29:32Z</dc:date>
    </item>
    <item>
      <title>Re: Proc MIXED MODEL Warning: For covariance type Unstructured</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/742299#M36115</link>
      <description>Another thought: You might want to recode the values for year. I assume the year values are in the thousands? That can produce very small slope estimates and cause some convergence issues. See if you can record the values to, for example, 1, 2, 3, 4, etc.&lt;BR /&gt;</description>
      <pubDate>Tue, 18 May 2021 23:23:06 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/742299#M36115</guid>
      <dc:creator>jiltao</dc:creator>
      <dc:date>2021-05-18T23:23:06Z</dc:date>
    </item>
    <item>
      <title>Re: Proc MIXED MODEL Warning: For covariance type Unstructured</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/749901#M36469</link>
      <description>&lt;P&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/60873"&gt;@jiltao&lt;/a&gt;&amp;nbsp;Hello,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So I am still working on this issue. I round the dependent variables to just one decimal place after the decimal. I also recoded the years for example 1999 and put for example, 1, 2, 3, 4, etc.It still did not work. It also removed the warning but the OUTP=data set is empty. With no columns nor rows.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Courtney Jacks&lt;/P&gt;</description>
      <pubDate>Wed, 23 Jun 2021 15:58:12 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/749901#M36469</guid>
      <dc:creator>cjacks21</dc:creator>
      <dc:date>2021-06-23T15:58:12Z</dc:date>
    </item>
    <item>
      <title>Re: Proc MIXED MODEL Warning: For covariance type Unstructured</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/750241#M36482</link>
      <description>&lt;P&gt;Can you send me the Log and Output from this new attempt?&lt;/P&gt;</description>
      <pubDate>Thu, 24 Jun 2021 15:27:56 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/750241#M36482</guid>
      <dc:creator>jiltao</dc:creator>
      <dc:date>2021-06-24T15:27:56Z</dc:date>
    </item>
    <item>
      <title>Re: Proc MIXED MODEL Warning: For covariance type Unstructured</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/750242#M36483</link>
      <description>&lt;P&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/60873"&gt;@jiltao&lt;/a&gt;&amp;nbsp;Your request is below. I also attempted some of the options on the document I found online. When I changed the method for estimating the covariance parameters from REML to MIVQUE0 the data set converged. I attached the sheet of tips to help.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Also, do you think it may be because I am missing data for viral load? It reads in the files as "." The dataset is unbalanced and contains missing data. I do not know if that would cause the proc mixed model to not converge.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;SAS code&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc sort data = Firstvisit;
by rfa_id testdate year;
RUN;

data avegvl_youth;
set Firstvisit;
keep rfa_id test_year testdate year sex_hars res_at_hiv_dx race_combined hiv_risk agegroup ccd4c ctimeyr days year mn quarter time  first_cd4cgp result_vl_log10;
by rfa_id testdate year;
run;


data youth_year;
set avegvl_youth;
if year=1999 then group = "1" ;
else if year = 2000 then group = "2";
else if year = 2001 then group = "3";
else if year = 2002 then group = "4";
else if year = 2003 then group = "5";
else if year = 2004 then group = "6";
else if year = 2005 then group = "7";
else if year = 2006 then group = "8";
else if year = 2007 then group = "9";
else if year = 2008 then group = "10";
else if year = 2009 then group = "11";
else if year = 2010 then group = "12";
else if year = 2011 then group = "13";
else if year = 2012 then group = "14";
else if year = 2013 then group = "15";
else if year = 2014 then group = "16";
else if year = 2015 then group = "17";
else if year = 2016 then group = "18";
else if year = 2017 then group = "19";
else if year = 2018 then group = "20";
else if year = 2019 then group = "21";
else if year = 2020 then group = "22";
rename group = yr;
run;

************************************* 1st Proc Mixed Code *****************************************************; 
*************************************    Unstructured  *****************************************************;


proc sort data = youth_year out = avegvl_youth_sort nodupkey;
by rfa_id testdate year result_vl_log10;
RUN;


PROC MIXED data= avegvl_youth_sort covtest  method=reml PLOTS(MAXPOINTS=NONE)noitprint;
    class  rfa_id sex_hars (ref="F") res_at_hiv_dx (ref="Urban") race_combined (ref="Black") 
		   hiv_risk (ref="MSM") first_cd4cgp (ref="&amp;gt; 500") agegroup(ref="20-24");
    model  result_vl_log10= year ccd4c ctimeyr sex_hars res_at_hiv_dx race_combined hiv_risk first_cd4cgp 
		   agegroup ccd4c*sex_hars ccd4c*res_at_hiv_dx ccd4c*race_combined ccd4c*hiv_risk ccd4c*first_cd4cgp 
		   ccd4c*agegroup ctimeyr*sex_hars ctimeyr*res_at_hiv_dx ctimeyr*race_combined ctimeyr*hiv_risk 
		   ctimeyr*first_cd4cgp ctimeyr*agegroup/ solution cl outp = pred_un ;
	random intercept year /  type= un subject=rfa_id;
	lsmeans sex_hars res_at_hiv_dx race_combined hiv_risk first_cd4cgp agegroup /diff adjust= tukey;
    title 'Mixed Model Results For Viral Load';
RUN;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;The output starts here:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;581  proc sort data = Firstvisit;
582  by rfa_id testdate year;
583  RUN;

NOTE: There were 57534 observations read from the data set WORK.FIRSTVISIT.
NOTE: The data set WORK.FIRSTVISIT has 57534 observations and 36 variables.
NOTE: PROCEDURE SORT used (Total process time):
      real time           0.07 seconds
      cpu time            0.07 seconds


584
585  data avegvl_youth;
586  set Firstvisit;
587  keep rfa_id test_year testdate year sex_hars res_at_hiv_dx race_combined hiv_risk agegroup
587!  ccd4c ctimeyr days year mn quarter time  first_cd4cgp result_vl_log10;
588  by rfa_id testdate year;
589  run;

NOTE: There were 57534 observations read from the data set WORK.FIRSTVISIT.
NOTE: The data set WORK.AVEGVL_YOUTH has 57534 observations and 17 variables.
NOTE: DATA statement used (Total process time):
      real time           0.04 seconds
      cpu time            0.03 seconds


590
591
592  data youth_year;
593  set avegvl_youth;
594  if year=1999 then group = "1" ;
595  else if year = 2000 then group = "2";
596  else if year = 2001 then group = "3";
597  else if year = 2002 then group = "4";
598  else if year = 2003 then group = "5";
599  else if year = 2004 then group = "6";
600  else if year = 2005 then group = "7";
601  else if year = 2006 then group = "8";
602  else if year = 2007 then group = "9";
603  else if year = 2008 then group = "10";
604  else if year = 2009 then group = "11";
605  else if year = 2010 then group = "12";
606  else if year = 2011 then group = "13";
607  else if year = 2012 then group = "14";
608  else if year = 2013 then group = "15";
609  else if year = 2014 then group = "16";
610  else if year = 2015 then group = "17";
611  else if year = 2016 then group = "18";
612  else if year = 2017 then group = "19";
613  else if year = 2018 then group = "20";
614  else if year = 2019 then group = "21";
615  else if year = 2020 then group = "22";
616  rename group = yr;
617  run;

NOTE: There were 57534 observations read from the data set WORK.AVEGVL_YOUTH.
NOTE: The data set WORK.YOUTH_YEAR has 57534 observations and 18 variables.
NOTE: DATA statement used (Total process time):
      real time           0.04 seconds
      cpu time            0.03 seconds


618
619  ************************************* 1st Proc Mixed Code
619! *****************************************************;
620  *************************************    Unstructured
620! *****************************************************;
621
622
623  proc sort data = youth_year out = avegvl_youth_sort nodupkey;
624  by rfa_id testdate year result_vl_log10;
625  RUN;

NOTE: There were 57534 observations read from the data set WORK.YOUTH_YEAR.
NOTE: 207 observations with duplicate key values were deleted.
NOTE: The data set WORK.AVEGVL_YOUTH_SORT has 57327 observations and 18 variables.
NOTE: PROCEDURE SORT used (Total process time):
      real time           0.04 seconds
      cpu time            0.04 seconds


626
627
628  PROC MIXED data= avegvl_youth_sort covtest  method=reml PLOTS(MAXPOINTS=NONE)noitprint;
629      class  rfa_id sex_hars (ref="F") res_at_hiv_dx (ref="Urban") race_combined
629! (ref="Black")
630             hiv_risk (ref="MSM") first_cd4cgp (ref="&amp;gt; 500") agegroup(ref="20-24");
631      model  result_vl_log10= year ccd4c ctimeyr sex_hars res_at_hiv_dx race_combined
631! hiv_risk first_cd4cgp
632             agegroup ccd4c*sex_hars ccd4c*res_at_hiv_dx ccd4c*race_combined ccd4c*hiv_risk
632! ccd4c*first_cd4cgp
633             ccd4c*agegroup ctimeyr*sex_hars ctimeyr*res_at_hiv_dx ctimeyr*race_combined
633! ctimeyr*hiv_risk
634             ctimeyr*first_cd4cgp ctimeyr*agegroup/ solution cl outp = pred_un ;
635      random intercept year /  type= un subject=rfa_id;
636      lsmeans sex_hars res_at_hiv_dx race_combined hiv_risk first_cd4cgp agegroup /diff
636! adjust= tukey;
637      title 'Mixed Model Results For Viral Load';
638  RUN;

NOTE: 16629 observations are not included because of missing values.
NOTE: The data set WORK.PRED_UN has 0 observations and 0 variables.
WARNING: Data set WORK.PRED_UN was not replaced because new file is incomplete.
NOTE: PROCEDURE MIXED used (Total process time):
      real time           10.39 seconds
      cpu time            10.10 seconds&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 24 Jun 2021 15:44:58 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/750242#M36483</guid>
      <dc:creator>cjacks21</dc:creator>
      <dc:date>2021-06-24T15:44:58Z</dc:date>
    </item>
    <item>
      <title>Re: Proc MIXED MODEL Warning: For covariance type Unstructured</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/750245#M36484</link>
      <description>&lt;P&gt;I think your DATA step to compute group from year is wrong. You didn't set the LENGTH of group, so the first assignment sets the length. Depending on the data, that might be one character, which means that the group variable has mostly value "1" because "10" through "19" get truncated to "1".&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Use&amp;nbsp;&lt;/P&gt;
&lt;P&gt;LENGTH group $2;&lt;/P&gt;
&lt;P&gt;or even better use a numeric variable:&lt;/P&gt;
&lt;P&gt;group = year-1998;&lt;/P&gt;</description>
      <pubDate>Thu, 24 Jun 2021 15:56:38 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/750245#M36484</guid>
      <dc:creator>Rick_SAS</dc:creator>
      <dc:date>2021-06-24T15:56:38Z</dc:date>
    </item>
    <item>
      <title>Re: Proc MIXED MODEL Warning: For covariance type Unstructured</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/750248#M36485</link>
      <description>Yes. I also noticed I rename group to yr and in the model and random statement I had year instead of yr. It works now.</description>
      <pubDate>Thu, 24 Jun 2021 16:16:34 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/750248#M36485</guid>
      <dc:creator>cjacks21</dc:creator>
      <dc:date>2021-06-24T16:16:34Z</dc:date>
    </item>
    <item>
      <title>Re: Proc MIXED MODEL Warning: For covariance type Unstructured</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/750250#M36486</link>
      <description />
      <pubDate>Thu, 24 Jun 2021 16:20:09 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-MIXED-MODEL-Warning-For-covariance-type-Unstructured/m-p/750250#M36486</guid>
      <dc:creator>cjacks21</dc:creator>
      <dc:date>2021-06-24T16:20:09Z</dc:date>
    </item>
  </channel>
</rss>

