Help using Base SAS procedures

How to calculate Modal Number?

Reply
N/A
Posts: 0

How to calculate Modal Number?

I want to calculate the Modal Number or the highest frequency, but my data is in lines, for example

Cod | Month01 | Month02 | Month03 | Month04 | MODAL
01 | 1 | 3 | 3 | 4 | 3
02 | 1 | 2 | 3 | 4 | .
03 | 1 | 1 | 1 | 2 | 1

The value (variable) that I want to find is the MODAL, but compare the fields are not a good way to solve this problem, because my data is very large.
Someone have done something like this, or have an idea to solve this!

Thanks a lot
N/A
Posts: 0

Re: How to calculate Modal Number?

are there any number greater than 10, since if not , you can set 10 dummy (0 to 9)variable to indicated the count for each number.
another way , transpose first , then use proc freq
N/A
Posts: 0

Re: How to calculate Modal Number?

My scores are 420 to 550...
How can I use this dummy? Because my data is very large and the transpose, is a few inviable.
Super Contributor
Posts: 260

Re: How to calculate Modal Number?

This thread http://support.sas.com/forums/thread.jspa?messageID=10645⦕ discusses mode computation. There should be some valid ideas in it.

Olivier
Ask a Question
Discussion stats
  • 3 replies
  • 105 views
  • 0 likes
  • 2 in conversation