Below are data below contain unemployment rates across race and gender from 1948 to 1968 in the United States. The data are presented in two forms. The first is a form that can be read by R, and the second is a form that can be read by SAS. For the R version, simply copy and paste the code into Notepad (or other text editor), and then save the file in your R_Working_Directory as a txt file. Your R program for this assignment will ask you to select a data set, and you will then select this file when prompted. To use the SAS version, you will need to copy and paste the data directly into your program in the SAS editor.
# FIRST IS THE R VERSION
# DATA SET..... Race and gender from 1948 to 1968 in USA
YEAR WMALE WFEMALE BLKMALE
1948 3.4 3.8 5.8
1949 5.6 5.7 9.6
1950 4.7 5.3 9.4
1951 2.6 4.2 4.9
1952 2.5 3.3 5.2
1953 2.5 3.1 4.8
1954 4.8 5.6 10.3
1955 3.7 4.3 8.8
1956 3.4 4.2 7.9
1957 3.6 4.3 8.3
1958 6.1 6.2 13.8
1959 4.6 5.3 11.5
1960 4.8 5.3 10.7
1961 5.7 6.5 12.8
1962 4.6 5.5 10.9
1963 4.7 5.8 10.5
1964 4.1 5.5 8.9
1965 3.6 5.0 7.4
1966 2.8 4.3 6.3
1967 2.7 4.6 6.0
1968 2.6 4.3 5.6
* BELOW IS THE SAS VERSION;
DATA SASSIGN8;
INPUT YEAR 1-4 WMALE 6-8 WFEMALE 10-12 BLKMALE 14-17;
CARDS;
1948 3.4 3.8 5.8
1949 5.6 5.7 9.6
1950 4.7 5.3 9.4
1951 2.6 4.2 4.9
1952 2.5 3.3 5.2
1953 2.5 3.1 4.8
1954 4.8 5.6 10.3
1955 3.7 4.3 8.8
1956 3.4 4.2 7.9
1957 3.6 4.3 8.3
1958 6.1 6.2 13.8
1959 4.6 5.3 11.5
1960 4.8 5.3 10.7
1961 5.7 6.5 12.8
1962 4.6 5.5 10.9
1963 4.7 5.8 10.5
1964 4.1 5.5 8.9
1965 3.6 5.0 7.4
1966 2.8 4.3 6.3
1967 2.7 4.6 6.0
1968 2.6 4.3 5.6
;
DATA SASSIGN8;SET;
LBLKMALE=LAG(BLKMALE);
LABEL WMALE=UNEMPLOYMENT RATE FOR WHITE MALES;
LABEL WFEMALE=UNEMPLOYMENT RATE FOR WHITE FEMALES;
LABEL BLKMALE=UNEMPLOYMENT RATE FOR BLACK MALES;
LABEL LBLKMALE=LAGGED UNEMPLOYMENT RATE BLACK MALES;