Peter and I corresponded off line about this and he sent me a sample of the
I, too, got the variable labeled VAR but the other names followed their
original form seen in the CSV. However, none of the other variables had a
Greek letter in their names. Their units were nanograms per milliliter and
the symbol for "nano" is an 'n'. It looks to me like SAS is choking on the
'mu' symbol which it can't convert it an English letter. After all, Greek
letters are not valid in SAS variable names.
I suggested to Peter that he simply change mu to a lower case 'u' in the
Excel file. That was how I wrote the symbol for micrograms when I was
reporting chemical results.
From: SAS(r) Discussion [mailto:SAS-L@LISTSERV.UGA.EDU] On Behalf Of Peter
Sent: Monday, August 22, 2011 3:03 PM
Subject: Reading in from csv files - when does SAS make VAR out of what is
I often (well, pretty much always) get data from clients in Excel. Usually,
I save it as .csv and then read it into SAS using the import wizard.
Clients do funny things. They name 20 variables with the same name. Really.
Sometimes this is the fault of the product they used to get the data, and
you get things like 10 variables named question1. When this happens, SAS
sometimes copes by creating variables named VAR XX. Nice. It alerts you
that there is a problem, doesn't overwrite data, and is a good solution.
Recently, a client sent an Excel file. One of the header rows was BAP mug/l
(where mu is the Greek letter). None of the other variables started with
BAP, and SAS coped fine with other variables that had Greek letters. But for
some reason, BAP was renamed with a VAR.
This caused me some embarrassment, with me telling the client there was no
variable called BAP and her saying = there it is! Look at the spreadsheet.
Has anyone else run into this?
Peter Flom Consulting