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

Hi there -- Though this is less a SAS specific question and more a general clarification question, I'm wondering if someone would have feedback/suggestions: to report on the percent of, say, schools which fall under some list of conditions, is it necessary to have a school-level file?

 

I’m asking since I see the file I have is a food-level file, where isn't even one food item per record (instead, each food item can be listed more than 100 times). Additionally, the variable for unique school ID's reports frequencies of up to 300-400. Given the current interim file structure, I’m wondering whether the most desirable thing is to convert the food-level file to a school-level one or if there is an alternative. What approach could one take to report percent of schools which offer one food item (example)?

 

please let me know if i should clarify or if there s a better space for a question like this

Thank you in advance!

 

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
LinusH
Tourmaline | Level 20

Since this is some kind of data modelling issue, the Data management community might be the most suitable place.

 

Even if I try to picture your "have" data, it would be great to post some sample data that represents the data that you have. This will increase the chance to get a relevant answer.

Data never sleeps

View solution in original post

3 REPLIES 3
Norman21
Lapis Lazuli | Level 10

You could try using PROC FREQ to give you a "feel" for the data.

 

Have a look at http://www2.sas.com/proceedings/sugi25/25/btu/25p069.pdf

 

It shouldn't be necessary to create a separate file.

 

Norman.

Norman.
SAS 9.4 (TS1M6) X64_10PRO WIN 10.0.17763 Workstation

LinusH
Tourmaline | Level 20

Since this is some kind of data modelling issue, the Data management community might be the most suitable place.

 

Even if I try to picture your "have" data, it would be great to post some sample data that represents the data that you have. This will increase the chance to get a relevant answer.

Data never sleeps
Reeza
Super User

That depends on your question and scope of analysis. If you do aggregate your data, make sure your summaries make sense. You may also want to determine why there are multiple records per school food, is it actually at a student level perhaps?

 


@Maisha_Huq wrote:

 

 isn't even one food item per record (instead, each food item can be listed more than 100 times). Additionally, the variable for unique school ID's reports frequencies of up to 300-400. G

 

 

 


 

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

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
  • 834 views
  • 1 like
  • 4 in conversation