Type : SASHELP
Los datos provienen de la tabla `sashelp.cars`, que es una biblioteca de datos estándar proporcionada con SAS.
| 1 | ods listing gpath="/home/nicolasdupont0/resources_github/Graph/Distribution/img" image_dpi=200; |
| 2 | |
| 3 | *---------------------------------------------------; |
| 4 | ods graphics / |
| 5 | reset = all attrpriority=color border = no width = 600px height = 400px |
| 6 | imagename = "density1" imagefmt = png outputfmt = png antialiasmax = 10000; |
| 7 | |
| 8 | title '1# Distribution of the numerical variable horsepower in the cars dataset'; |
| 9 | PROC SGPLOT DATA=sashelp.cars; |
| 10 | title "1# horsepower Density"; |
| 11 | density horsepower / type=normal scale=percent legendlabel="Normal"; |
| 12 | density horsepower / type=kernel scale=percent legendlabel="kernel"; |
| 13 | xaxis min=0; |
| 14 | yaxis min=0; |
| 15 | RUN; |
| 1 | *---------------------------------------------------; |
| 2 | ods graphics / |
| 3 | reset = all attrpriority=color border = no width = 600px height = 400px |
| 4 | imagename = "density2" imagefmt = png outputfmt = png antialiasmax = 10000; |
| 5 | |
| 6 | title '2# Distribution of two numerical variables MSRP and Invoice from the cars dataset'; |
| 7 | PROC SGPLOT DATA=sashelp.cars; |
| 8 | title "2# MSRP and Invoice Density"; |
| 9 | density MSRP / scale=percent name="MSRP" legendlabel="MSRP"; |
| 10 | density Invoice / scale=percent name="Invoice" legendlabel="Invoice"; |
| 11 | xaxis label="Distribution" min=0; |
| 12 | yaxis label="%" min=0; |
| 13 | keylegend "MSRP" "Invoice" / across=1 position=Topleft location=Inside; |
| 14 | RUN; |