BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
Linlin
Lapis Lazuli | Level 10

Good morning Art!

I am using a Lenovo laptop with Windows 7.

rtritz
Calcite | Level 5

Hi Art and Linlin,  I have Sony laptop with Windows Vista.

Afterwards, I was wondering about something like this or a system option that may have a different value.

Rich

art297
Opal | Level 21

Rich,

What do you get if you run:

proc options option= caps;

run;

I ran your code on 9.2 and got the same result as Linlin did.

rtritz
Calcite | Level 5

Art,

Proc options option=caps;

run;

gives NOCAPS in the log.

I was looking at VALIDVARNAME could that have any effect?

Rich

rtritz
Calcite | Level 5

Hi Art and Linlin,

The VALIDVARNAME option may be the key.

The setting for this on my system is UPCASE.

From the documentation validvarname=V7 is the default and UPCASE and V7 essentially do the same things as far

as having variable names be all uppercase in SAS datasets. I changed the value to validvarname=any(from 9.3 documentation) and two things happened.

I got a Warning in the log saying this setting was experimental in 9.1.3 but when I did this then the variable names in the dataset

I tested were the same case as written in the code and no longer all uppercase.

Could ANY now be the default for 9.2 and later or is it still V7? Could you check this setting on your systems?

Rich

art297
Opal | Level 21

9.2: validvarname=v7

Linlin
Lapis Lazuli | Level 10

Hi Rich,

from my log file:

2806  Proc options option=VALIDVARNAME;

2807  run;

    SAS (r) Proprietary Software Release 9.3  TS1M0

VALIDVARNAME=V7   Control the type of SAS variable names that can be created

                   during a SAS session

NOTE: PROCEDURE OPTIONS used (Total process time):

      real time           0.00 seconds

      cpu time            0.00 seconds

rtritz
Calcite | Level 5

Alright, that appears to explain it. When I change my VALIDVARNAME option to V7 then the variable names in the dataset

I tested were the same case as in the code and not uppercase anymore. So, when and if I ever post to the forum

again, I will have to think about changiing that option especially if I quote any variable strings.

Rich

dan999
Fluorite | Level 6

This worked. Thanks a lot.

MikeZdeb
Rhodochrosite | Level 12

hi ... another idea ...

data x;

input program  col1-col3 @@;

datalines;

10 3  5  1 15 1  2  7  24 6  8  5 21 2  8  1 35 9  4  3 33 3  1  1

;

proc format;

value p

10,15 = 'A'

24,21 = 'B'

35,33 = 'C'

;

run;

proc summary data=x nway;

class program;

var col: ;

output out=stats sum=;

format program p.;

run;

proc transpose data=stats out=want (drop=_name_) prefix=prg;

var col1-col3;

id program;

run;

Obs    prgA    prgB    prgC

1       4       8      12

2       7      16       5

3       8       6       4

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

Register now!

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 24 replies
  • 15142 views
  • 1 like
  • 6 in conversation