BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
yael
Quartz | Level 8

 

Hello

I tried to run the following code:

 

proc means data=sasuser.sasfile190616;

var TAssets Sales FDtotalFF IDtotalFF ODtotalFF FDtotalFNF IDtotalFNF ODtotalFNF Firmdefi FOWNFF FINFF OTHERFF FOWNFNF FINFNF OTHERFNF ROA Q SalesGro RDSales LTassets LN(Assets) NIAssets CAPAXS LTSTEquity Divsales Marexpsales FirmAgeissue Beta;

class FIRMDEFI;

run;

 

And got the following errors (more than that, but all of them with the same reason):

ERROR: Variable FDtotalFNF in list does not match type prescribed for this list.

ERROR: Variable IDtotalFNF in list does not match type prescribed for this list.

ERROR: Variable ODtotalFNF in list does not match type prescribed for this list.

 

These variables are numeric but have a lot of missing values because each of this variable describe only one class out of 3.

What I have to do in order to get the proc means

 

Thanks a lot! 

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
Reeza
Super User

The log is telling you they are not numeric. Run a proc contents and verify this. Convert them into numeric variables then use proc means. 

View solution in original post

3 REPLIES 3
Reeza
Super User

The log is telling you they are not numeric. Run a proc contents and verify this. Convert them into numeric variables then use proc means. 

KTstarter
Calcite | Level 5

I'm having the same isssue. I've checked my data that's stored in excel and the header is text (the variable I'm interested in) and the samples are stored as numbers but SAS still states the same issue as discussed above. 

yael
Quartz | Level 8

Deae @KTstarter

 

I did as they mentioned above, it means that my code was:

 

proc contents data=sasuser.yael1;

run;

 

I found that variables that I thought and also looked like numbers were actually text. I really do not know why it happened, but I changed it in excel to numbers and copied again to SAS as numbers.

 

I hope it will helps

 

 

 

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

Register now!

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 3 replies
  • 61299 views
  • 3 likes
  • 3 in conversation