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

Hello I'm a beginner with SAS University Edition and I'm sorry my english is not very good and I need your help.

 

I have a database with 50000 data.

 

I have 8 variables (Sexe_assure / age / Profession_assure / ancien / Categorie_vehicule / Usage_vehicule / annee / bonus)

And 2 variables quantitative (Nb_sinistres / Cout_sinsitres)

 

For your information,

Nb_sinistres = Number of car accident

Cout_sinistres = cost of accident

 

I have to analyse the population first then estimate the "cost".

 

I have already done the correlations off the varaibles with the fonction PROC CORR PEARSON.

 

This is my code :

79 /*Population sinsitrée = popuplation with accident*/
80 PROC CORR PEARSON DATA=WORK.SAS_GLOBAL;
81 VAR Age Ancien Categorie_vehicule Profession_assure Sexe_assure Usage_vehicule bonus annee;
82 WHERE nb_sinistres between 1 and 10;
83 RUN

 

I have done the same operation for nb_sinistres = 0 and an other one without the condition "WHERE".

My objectif is to observe the variables for all population, the population without accident and the population with accident.

 

I have done my analysis of the different populations.

 

Now I have to estimate the cost. In this instruction I understand that I have to predict/presage the cost for the next years.

 

I suppose I have to do a linaire regression. But i don't know how to get, can you help me write the program ?

 

I need to have a graph and the result

 

 

Please find attached the database

 

Thank you in advance for your help.

1 ACCEPTED SOLUTION

Accepted Solutions
DarthPathos
Lapis Lazuli | Level 10

Hello and welcome to the community!

 

You can use the Linear Regression Task in SAS University Edition to help you.  If you go to TASKS AND UTILITIES -> Statistics -> scroll down you'll see it there.

 

Screen Shot 2016-06-12 at 9.15.33 AM.png

 

All you have to do is fill in the screens with the information and run the Task, you will get results.  You can specify different criteria without having to worry about wrtiing any code.  

Screen Shot 2016-06-12 at 9.19.54 AM.png

 

Screen Shot 2016-06-12 at 9.20.03 AM.png

 

If you want to see the code, you can click on the CODE tab

Screen Shot 2016-06-12 at 9.22.30 AM.png

 

And you'll get something like this:

Screen Shot 2016-06-12 at 9.22.37 AM.png

 

I hope this helps.  If you need more information about linear regression, I recommend Greg Lee's book Business statistics made easy.  You can also post back here, plenty of people have lots of experience and can help you.

 

Good luck!

Chris 

Has my article or post helped? Please mark as Solution or Like the article!

View solution in original post

2 REPLIES 2
DarthPathos
Lapis Lazuli | Level 10

Hello and welcome to the community!

 

You can use the Linear Regression Task in SAS University Edition to help you.  If you go to TASKS AND UTILITIES -> Statistics -> scroll down you'll see it there.

 

Screen Shot 2016-06-12 at 9.15.33 AM.png

 

All you have to do is fill in the screens with the information and run the Task, you will get results.  You can specify different criteria without having to worry about wrtiing any code.  

Screen Shot 2016-06-12 at 9.19.54 AM.png

 

Screen Shot 2016-06-12 at 9.20.03 AM.png

 

If you want to see the code, you can click on the CODE tab

Screen Shot 2016-06-12 at 9.22.30 AM.png

 

And you'll get something like this:

Screen Shot 2016-06-12 at 9.22.37 AM.png

 

I hope this helps.  If you need more information about linear regression, I recommend Greg Lee's book Business statistics made easy.  You can also post back here, plenty of people have lots of experience and can help you.

 

Good luck!

Chris 

Has my article or post helped? Please mark as Solution or Like the article!
Pjag_1975
Calcite | Level 5

Thanks for your help

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!

What is ANOVA?

ANOVA, or Analysis Of Variance, is used to compare the averages or means of two or more populations to better understand how they differ. Watch this tutorial for more.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 2 replies
  • 1425 views
  • 1 like
  • 2 in conversation