BookmarkSubscribeRSS Feed
tsetredst
Calcite | Level 5

Hi,

 

I am trying to create minute intervals using proc expand. I am using 'method=step' which works well for most of my variables, but I would like the value of one/or a number of the variables that are carried forward to be set to zero. 

 

I am aware of the convert/transform option but cannot seem to get this working as such.

 

My code looks something like this:

 

proc expand data = hk_floor.hk_a out=hk_floor.hk_aa to=minute method=step;
by _ric date_L_;
id time_l_;
run;

Thanks,

 

Ed

1 REPLY 1
ballardw
Super User

You may want to provide a brief example of some imput data and the desired result for the rules you need.

 

The phrase "like the value of one/or a number of the variables that are carried forward to be set to zero" really should reflect which variables have the need based on the syntax you show. Otherwise we are completely guessing as to what syntax change may be needed.

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

Register now!

How to connect to databases in SAS Viya

Need to connect to databases in SAS Viya? SAS’ David Ghan shows you two methods – via SAS/ACCESS LIBNAME and SAS Data Connector SASLIBS – in this video.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 1 reply
  • 723 views
  • 0 likes
  • 2 in conversation