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
- /
- SAS Programming
- /
- Base SAS Programming
- /
- newbie stuck at square 1

Topic Options

- 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
- RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content

04-28-2017 03:58 PM

I need help with the following question, please. I have no idea where to start

The number of hours of the college students aged 18 to 24 years spending online in a typical week was interested in to a researcher. Suppose that the number of hours spending online is normal distributed with mean of 28 and standard deviation of 5.6.

Use appropriate Functions in SAS to answer the following questions.

Find the probability that a college student aged 18 to 24 years, selected at random, spends between 20 and 35 hours online each week. Determine the proportion of college students aged 18 to 24 years who spend more than 40 hours online per week.

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

Posted in reply to pacruz

04-28-2017 04:06 PM

This is a relatively basic statistics question, the kind you would be asked in statistics 101.

If you know how to do this using pencil and paper and a table of the normal distribution, then the method in SAS simply replaces the table of the normal distribution with a function in SAS. The SAS function you would want to use is the PROBNORM function.

And if you don't know how to do this using pencil and paper, then you need to first learn the basics of the normal distribution, any introductory textbook will do.

--

Paige Miller

Paige Miller

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

Posted in reply to pacruz

04-28-2017 04:28 PM

Just to get you started, you are looking for the shaded area under the curve plotted like this

```
data PDF;
do hours = 8 to 48 by 0.05;
Y = pdf("Normal", hours, 28, 5.6);
if hours <= 35 then upper = Y;else upper = 0;
if hours <= 20 then lower = Y; else lower = 0;
output;
end;
run;
/* First Question */
title 'Density of Hours Spent online';
title2 '18 to 24 year olds';
proc sgplot data = PDF noautolegend;
series x = hours y = Y;
band x = hours lower = lower upper = upper;
xaxis label = 'Hours Spent';
yaxis label = 'Density';
run;
title;
```