Brand new installation of SAS 9.4 M8 and when writing code to make a plot appear in PROC POWER (the code is correct, per the reference I am using as the accompanying visualization is given), I receive the following error: ERROR: Java virtual machine exception. java.lang.NoClassDefFoundError: Could not initialize class com.sas.graphics.applets.statgraph.sgchart.data.DataModel Has anyone found a workaround for this?
... View more
Hello, I am getting the following error messages when trying to merge two datasets. One of the datasets I am getting from a csv file, so maybe the issue could be there? I was trying to specify the length of the PID variable for the redcap_sort dataset from the redcap one, which is the one we got from the csv file. However, I keep getting messages that the variable has multiple lengths and it keeps truncating the data. Any PID after 999 gets shortened. So 1000 and 1001 become 100, 1010 becomes 101, etc. Any help or a nudge in the right direction would be greatly appreciated, thank you so much. Edit: The programming with the csv file already has: data work.redcap; %let _EFIERR_ = 0;
infile &csv_file delimiter = ',' MISSOVER DSD lrecl=32767 firstobs=1 ;
informat pid $500. ;
informat pid_ini $500. ; and the code for format: format pid $500. ; It has this for all the variables. I thought the above code would make it so that the variables would have that limit of 500 characters?
... View more
Hi, I would like to apply two types of floors, respectively for lower and upper segments of a dataset. Assume the dataset has two columns: Col1 which is unique and asc sorted; Col2 is the actual data the floor applies to 1) Floor 1 on the lower band of Col1 : for any values in Col1 less than3, which is set to by the user - replace their values in Col2 with the Col2 value of Col1 =3 2)Floor 2 on the upper band of Col1: for any values in Col1 greater than 4, which is set to by the user - replace their values in Col2 with the Col2 value of previous Col1 to ensure they are not decreasing when Col1 values increase Below is an example of the dataset I have and what I want. Many thanks in advance. data have; input Col1 Col2; datalines; 1 1 2 2 3 3 4 4 5 3 6 6 7 1 8 3 ; data want; Col1 Col2 1 3 2 3 3 3 4 4 5 4 6 6 7 6 8 6 ;
... View more
I'm outputting the frequency counts and %s from a crosstab table to a data set (out=test_freq in example code below).
The conditional percentages by x values are correct in the SAS Results tab, however the %s in the test_freq output dataset are not correct.
Is my syntax incorrect?
data test;
input x $ y $;
cards;
Alice blue
Alice blue
Alice blue
Alice green
Alice green
Alice red
Bob blue
Bob green
Bob green
Bob green
Bob red
Bob red
Bob red
Bob red
;
run;
proc freq data=test;
table x*y / nopercent nocol out=test_freq;
run;
... View more
Hi,
I want to asses how some specific regulatory intervention (e.g. tax relief) affects time to firms' defaults using survival analysis. Since my covariate of interest is time-dependent (different firms receive tax reliefs in different moments of time, sometimes more than once), I want to use counting process syntax in the following way (I control also for the industry, in which firm operates, by including NACE code):
PROC PHREG DATA = my_data
CLASS industry_code
MODEL (tstart, tstop)*endpt(0) = treatment_variable industry_code/ TIES = EFRON RL;
RUN;
I've read the "Survival Analysis using SAS. A Practical Guide" book by Paul D. Allison. According to the book when using time-dependent covariates the model is no longer a proportional hazard anymore, but it "creates no real problem for the partial likelihood estimation method".
My questions are as follows:
1. Do I understand correctly that I don't have to verify the PH assumption prior to estimating the model?
2. If the answer to the previous question is "yes", are there any other assumptions that I have to verify to make sure that I can estimate the model as shown above?
3. Are the ways to asses goodness of fit the same for models with time-dependent covariates and "standard" PH models? Can use the statistics produced by the phreg or I need to adjust them somehow to account for using counting process syntax?
... View more