turn on suggestions

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

Find a Community

- Home
- /
- Analytics
- /
- Stat Procs
- /
- Proc MI

Topic Options

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

01-08-2013 03:55 PM

I am trying to use multiple imputation in PROC MI to impute hospital diagnoses. according to the documentation it looks like I want to use the FCS method since diagnosis is a multi-level categorical variable.

when I run my code I get that weird message about floating points. I am assuming the issue is that there are many levels to this variable. I tried to lump categories together and reduce the number of levels from about 235 to 40, but the proc still bombed.

anyone here use PROC MI with the FCS statement when trying to impute a categorical variable? I can provide code I'm using if so. Maybe my syntax is wrong.

also, when I run the proc it says that the FCS command is experimental in my release of SAS (9.3).

thanks

Julia

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

01-09-2013 09:49 AM

I don't know if this will be of any help for your particular situation, but check out https://communities.sas.com/message/145964#145964 . With a floating point error, I would guess that you have identified the main source of the problem being the number of levels. From there, it may be a sparsity of data/quasi-separation problem, such that there is insufficient data to get the categorical model (assuming it is logistic) to converge, and thus the likelihood function wanders off into places in the manifold where it overflows. However, diagnosing the problem and solving it are two different tasks, and we'll need the first to attack the second. Check your syntax against what is in the referenced thread and the suggestion there, and then look at some cross-tabs about where the missing levels are relative to the predictive variables.

Steve Denham

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

01-09-2013 09:54 AM

Thanks Steve. I will check this out.

Julia

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

01-09-2013 10:25 AM

Steve, do you think the following syntax looks right? I only want to impute for the variable DXCCS1, and want to use the other variables to help inform that process. DXCCS1 right now has about 40 levels. The dataset is huge--2.4 million records.

proc mi data=all out= outall nimpute=10;

class dxgrp ccsproc female discharge_loc;

fcs nbiter=20 discrim(dxgrp) ;

var dxgrp ccsproc newlos female discharge_loc age; /* newlos and age continuous*/

run;

even with the large N ,it could still be a sparsity issue I guess, with some levels of CCSPROC (primary procedure, having 200 or so levels) having very little data.

BELOW are the messages I get from SAS when running that code:

NOTE: The FCS statement is experimental in this release.

WARNING: The covariates are not specified in an FCS discriminant method for variable dxgrp, only

remaining continuous variables will be used as covariates.

WARNING: The covariates are not specified in an FCS discriminant method for variable ccsproc,

only remaining continuous variables will be used as covariates.

WARNING: The covariates are not specified in an FCS discriminant method for variable FEMALE, only

remaining continuous variables will be used as covariates.

WARNING: The covariates are not specified in an FCS discriminant method for variable

discharge_loc, only remaining continuous variables will be used as covariates.

WARNING: An effect for variable newlos is a linear combination of other effects. The coefficient

of the effect will be set to zero in the imputation.

ERROR: Floating Point Zero Divide.

ERROR: Termination due to Floating Point Exception

thanks for any feedback.

Julia

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

01-09-2013 12:29 PM

Still not sure but try the following :

proc mi data=all out= outall nimpute=10 seed=123;

class dxccs1 dxgrp ccsproc female discharge_loc;

fcs nbiter=20 discrim(dxccs1=dxgrp ccsproc newlos female discharge_loc age/classeffects=include details)

var dxccs1 dxgrp ccsproc newlos female discharge_loc age; /* newlos and age continuous*/

run;

If that still blows things up, you might have some luck using logistic rather than discrim as the method in the fcs statement. For an example that works, see Example 57.8 FCS Method with Trace Plot.

Steve Denham