Importing CSV dataset in SAS

SAS Analytics Importing CSV file in SAS
3 minutes
Share the link to this page
Copied
  Completed
You need to have access to the item to view this lesson.
One-time Fee
$69.99
List Price:  $99.99
You save:  $30
€60.35
List Price:  €86.22
You save:  €25.86
£51.43
List Price:  £73.47
You save:  £22.04
CA$96.02
List Price:  CA$137.18
You save:  CA$41.16
A$107.53
List Price:  A$153.63
You save:  A$46.09
S$89.63
List Price:  S$128.06
You save:  S$38.42
HK$549.41
List Price:  HK$784.91
You save:  HK$235.49
CHF 56.70
List Price:  CHF 81.01
You save:  CHF 24.30
NOK kr706.52
List Price:  NOK kr1,009.36
You save:  NOK kr302.83
DKK kr450.21
List Price:  DKK kr643.18
You save:  DKK kr192.97
NZ$116.05
List Price:  NZ$165.80
You save:  NZ$49.74
د.إ257.03
List Price:  د.إ367.21
You save:  د.إ110.17
৳8,553.54
List Price:  ৳12,219.87
You save:  ৳3,666.32
₹6,022.49
List Price:  ₹8,603.93
You save:  ₹2,581.44
RM297.14
List Price:  RM424.50
You save:  RM127.36
₦108,505.49
List Price:  ₦155,014.49
You save:  ₦46,509
₨19,847.98
List Price:  ₨28,355.48
You save:  ₨8,507.49
฿2,286.28
List Price:  ฿3,266.25
You save:  ฿979.97
₺2,774.39
List Price:  ₺3,963.59
You save:  ₺1,189.19
B$384.88
List Price:  B$549.86
You save:  B$164.97
R1,240.32
List Price:  R1,771.97
You save:  R531.64
Лв118.07
List Price:  Лв168.68
You save:  Лв50.60
₩95,188.03
List Price:  ₩135,988.74
You save:  ₩40,800.70
₪238.29
List Price:  ₪340.43
You save:  ₪102.13
₱3,984.42
List Price:  ₱5,692.28
You save:  ₱1,707.85
¥10,155.45
List Price:  ¥14,508.41
You save:  ¥4,352.96
MX$1,331.56
List Price:  MX$1,902.31
You save:  MX$570.75
QR252.93
List Price:  QR361.35
You save:  QR108.41
P945.78
List Price:  P1,351.18
You save:  P405.39
KSh9,046.20
List Price:  KSh12,923.70
You save:  KSh3,877.50
E£3,502.23
List Price:  E£5,003.40
You save:  E£1,501.17
ብር9,315.10
List Price:  ብር13,307.86
You save:  ብር3,992.75
Kz63,827.73
List Price:  Kz91,186.38
You save:  Kz27,358.65
CLP$66,377.81
List Price:  CLP$94,829.51
You save:  CLP$28,451.70
CN¥502.09
List Price:  CN¥717.30
You save:  CN¥215.21
RD$4,157.87
List Price:  RD$5,940.07
You save:  RD$1,782.19
DA9,093.72
List Price:  DA12,991.59
You save:  DA3,897.86
FJ$157.28
List Price:  FJ$224.70
You save:  FJ$67.41
Q538.08
List Price:  Q768.72
You save:  Q230.63
GY$14,631.94
List Price:  GY$20,903.67
You save:  GY$6,271.73
ISK kr8,594.07
List Price:  ISK kr12,277.77
You save:  ISK kr3,683.70
DH633.61
List Price:  DH905.20
You save:  DH271.58
L1,194.06
List Price:  L1,705.88
You save:  L511.81
ден3,713.20
List Price:  ден5,304.81
You save:  ден1,591.60
MOP$565.51
List Price:  MOP$807.91
You save:  MOP$242.39
N$1,262.70
List Price:  N$1,803.94
You save:  N$541.23
C$2,573.56
List Price:  C$3,676.68
You save:  C$1,103.11
रु9,706.52
List Price:  रु13,867.06
You save:  रु4,160.53
S/249.07
List Price:  S/355.83
You save:  S/106.75
K284.99
List Price:  K407.15
You save:  K122.15
SAR262.55
List Price:  SAR375.09
You save:  SAR112.54
ZK1,607.09
List Price:  ZK2,295.94
You save:  ZK688.85
L304.69
List Price:  L435.29
You save:  L130.60
Kč1,496.59
List Price:  Kč2,138.08
You save:  Kč641.49
Ft24,257.05
List Price:  Ft34,654.42
You save:  Ft10,397.36
SEK kr668.07
List Price:  SEK kr954.43
You save:  SEK kr286.35
ARS$81,993.64
List Price:  ARS$117,138.79
You save:  ARS$35,145.15
Bs485
List Price:  Bs692.89
You save:  Bs207.88
COP$283,346.55
List Price:  COP$404,798.14
You save:  COP$121,451.58
₡35,333.59
List Price:  ₡50,478.72
You save:  ₡15,145.13
L1,826.57
List Price:  L2,609.50
You save:  L782.92
₲558,220.65
List Price:  ₲797,492.25
You save:  ₲239,271.60
$U2,838.05
List Price:  $U4,054.54
You save:  $U1,216.48
zł256.95
List Price:  zł367.08
You save:  zł110.13
Already have an account? Log In

Transcript

In this video we will be discussing about how to import a CSV file into SAS. For this we'll be using the procedure called proc import data file. So let's do it proc import data file. Equals first we have to give the path of our data file via var we'll do import the CSV file for linear regression. So this is my linear regression CSV file. I can take the path from the properties or even take it from the address bar.

Then we have to give the name of the data file that is the CSV file that is linear underscore record is predicted dot CSV and we are using the keyword for out equals to linear. So after we import the data file into SAS, the data set will be created inside work as we did not specify any library name over here and it will be the name of the data set will be linear. Then we are giving the key word called replace, replace transform. My Excel file is getting replaced with SAS data set and then Dra. Let's run this code So this is my work literally. Let's open the linear data set, proceed This is my data set, whichever imported.

Here I have got 200 observations. And I have variables like customer satisfaction, product quality, ecommerce, technical support content resolution advertising, product line, sales force image, competitive pricing, warranty claims packaging, or the billing, flat price, flexibility and delivery. So I have around 13 to 14 independent we're 13 to 14 variables or columns, where since this is a linear regression data, so you can understand very well my customers are searching the dependent variable and the rest of my independent variables. So basically I have converted my CSV file into a fast phi or those fast data set. If this file was an Excel file, say if it was if the CSV file was an Excel file means it is saved in dot XLS format or dot XLS x format. So if it is in dot XLS format we are going to just replace the CSV by XLS and then we are going to import it.

So, this is how you import an Excel file into SAS. Thank you. Goodbye. See you all for the next video.

Sign Up

Share

Share with friends, get 20% off
Invite your friends to LearnDesk learning marketplace. For each purchase they make, you get 20% off (upto $10) on your next purchase.